summaryrefslogtreecommitdiff
path: root/mm/memory.c
diff options
context:
space:
mode:
authorMiklos Szeredi <miklos@szeredi.hu>2019-07-11 20:54:37 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2019-07-12 11:05:42 -0700
commit465fc3a9b3129722b0df395529b3894b0b90d2de (patch)
tree70eb2a731758e5ba97f548a0cb926fa7c107322f /mm/memory.c
parenta7030aea20d9191c271607aa1478f72a41948b0a (diff)
mm/memory.c: trivial clean up in insert_page()
Make the success case use the same cleanup path as the failure case. Link: http://lkml.kernel.org/r/20190523134024.GC24093@localhost.localdomain Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> Reviewed-by: Andrew Morton <akpm@linux-foundation.org> Reviewed-by: Anshuman Khandual <anshuman.khandual@arm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/memory.c')
-rw-r--r--mm/memory.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/mm/memory.c b/mm/memory.c
index ddf20bd0c317..ced4bedc660d 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -1475,8 +1475,6 @@ static int insert_page(struct vm_area_struct *vma, unsigned long addr,
set_pte_at(mm, addr, pte, mk_pte(page, prot));
retval = 0;
- pte_unmap_unlock(pte, ptl);
- return retval;
out_unlock:
pte_unmap_unlock(pte, ptl);
out: