projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3b9dbd5
)
mmap: convert vma_link() vma iterator
author
Liam R. Howlett
<Liam.Howlett@Oracle.com>
Fri, 20 Jan 2023 16:26:11 +0000
(11:26 -0500)
committer
Andrew Morton
<akpm@linux-foundation.org>
Fri, 10 Feb 2023 00:51:32 +0000
(16:51 -0800)
Avoid using the maple tree interface directly.
Link:
https://lkml.kernel.org/r/20230120162650.984577-11-Liam.Howlett@oracle.com
Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/mmap.c
patch
|
blob
|
history
diff --git
a/mm/mmap.c
b/mm/mmap.c
index 94a477a551094d21ad39e2ce7b36f17c430a9068..17de99f31ff50af324990f4599f4bcc42f528ea2 100644
(file)
--- a/
mm/mmap.c
+++ b/
mm/mmap.c
@@
-487,10
+487,10
@@
static inline void vma_mas_szero(struct ma_state *mas, unsigned long start,
static int vma_link(struct mm_struct *mm, struct vm_area_struct *vma)
{
-
MA_STATE(mas, &mm->mm_mt, 0
, 0);
+
VMA_ITERATOR(vmi, mm
, 0);
struct address_space *mapping = NULL;
- if (
mas_preallocate(&mas, GFP_KERNEL
))
+ if (
vma_iter_prealloc(&vmi
))
return -ENOMEM;
if (vma->vm_file) {
@@
-498,7
+498,7
@@
static int vma_link(struct mm_struct *mm, struct vm_area_struct *vma)
i_mmap_lock_write(mapping);
}
- vma_
mas_store(vma, &mas
);
+ vma_
iter_store(&vmi, vma
);
if (mapping) {
__vma_link_file(vma, mapping);