summaryrefslogtreecommitdiff
path: root/mm/mprotect.c
diff options
context:
space:
mode:
authorAndrew Morton <akpm@linux-foundation.org>2023-04-16 12:31:58 -0700
committerAndrew Morton <akpm@linux-foundation.org>2023-04-16 12:31:58 -0700
commite492cd61b986590a45c674ede7dd1c4dbf94cf24 (patch)
tree37dc59ea66842b5b7e57f32aba6cbce5143c1282 /mm/mprotect.c
parentd46031f40e0f7f7bf63914bb3f2e404ad3886ecd (diff)
parent2ff559f31a5d50c31a3f9d849f8af90dc36c7105 (diff)
downloadlwn-e492cd61b986590a45c674ede7dd1c4dbf94cf24.tar.gz
lwn-e492cd61b986590a45c674ede7dd1c4dbf94cf24.zip
sync mm-stable with mm-hotfixes-stable to pick up depended-upon upstream changes
Diffstat (limited to 'mm/mprotect.c')
-rw-r--r--mm/mprotect.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/mprotect.c b/mm/mprotect.c
index b9da9a5f87fe..204194155863 100644
--- a/mm/mprotect.c
+++ b/mm/mprotect.c
@@ -869,7 +869,7 @@ static int do_mprotect_pkey(unsigned long start, size_t len,
}
tlb_finish_mmu(&tlb);
- if (vma_iter_end(&vmi) < end)
+ if (!error && vma_iter_end(&vmi) < end)
error = -ENOMEM;
out: