From dfb8fca69dc654b5c21ff03397b481d27de03cc6 Mon Sep 17 00:00:00 2001 From: Suren Baghdasaryan Date: Sat, 4 Mar 2023 15:24:15 -0800 Subject: [PATCH] txt-mm-khugepaged-write-lock-vma-while-collapsing-a-huge-page-fix-fix I missed vma_try_start_write() definition for CONFIG_PER_VMA_LOCK=n configuration. Link: https://lkml.kernel.org/r/CAJuCfpFjWhtzRE1X=J+_JjgJzNKhq-=JT8yTBSTHthwp0pqWZw@mail.gmail.com Signed-off-by: Suren Baghdasaryan Signed-off-by: Andrew Morton --- include/linux/mm.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/mm.h b/include/linux/mm.h index 8a981f0085f2..d7ed0a36d750 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -717,6 +717,8 @@ static inline bool vma_start_read(struct vm_area_struct *vma) { return false; } static inline void vma_end_read(struct vm_area_struct *vma) {} static inline void vma_start_write(struct vm_area_struct *vma) {} +static inline bool vma_try_start_write(struct vm_area_struct *vma) + { return true; } static inline void vma_assert_write_locked(struct vm_area_struct *vma) {} #endif /* CONFIG_PER_VMA_LOCK */ -- 2.50.1