Commit edeb69e5 authored by Jason J. Herne's avatar Jason J. Herne Committed by Christian Borntraeger

KVM: s390: Cleanup usage of current->mm in set_guest_storage_key

In set_guest_storage_key, we really want to reference the mm struct given as
a parameter to the function. So replace the current->mm reference with the
mm struct passed in by the caller.
Signed-off-by: default avatarJason J. Herne <jjherne@us.ibm.com>
Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
parent a6b7e459
...@@ -936,7 +936,7 @@ int set_guest_storage_key(struct mm_struct *mm, unsigned long addr, ...@@ -936,7 +936,7 @@ int set_guest_storage_key(struct mm_struct *mm, unsigned long addr,
down_read(&mm->mmap_sem); down_read(&mm->mmap_sem);
retry: retry:
ptep = get_locked_pte(current->mm, addr, &ptl); ptep = get_locked_pte(mm, addr, &ptl);
if (unlikely(!ptep)) { if (unlikely(!ptep)) {
up_read(&mm->mmap_sem); up_read(&mm->mmap_sem);
return -EFAULT; return -EFAULT;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment