]> git.openfabrics.org - ~emulex/infiniband.git/commit
s390/kvm,tprot: use new gmap_translate() function
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Tue, 5 Mar 2013 12:14:42 +0000 (13:14 +0100)
committerMarcelo Tosatti <mtosatti@redhat.com>
Thu, 7 Mar 2013 19:21:20 +0000 (16:21 -0300)
commit59a1fa2d80c0d351755cb29273b2b256dc4b3a11
tree45c45e881ca3806a5d4c859519e471348c0d4a2d
parent9e0fdb4145205bea95c2888a195c3ead2652f120
s390/kvm,tprot: use new gmap_translate() function

When out-of-memory the tprot code incorrectly injected a program check
for the guest which reported an addressing exception even if the guest
address was valid.
Let's use the new gmap_translate() which translates a guest address to
a user space address whithout the chance of running into an out-of-memory
situation.
Also make it more explicit that for -EFAULT we won't find a vma.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/s390/kvm/priv.c