On Wed, Aug 2, 2023 at 11:54 AM Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote: > > On Wed, 2 Aug 2023 at 11:09, Suren Baghdasaryan <surenb@xxxxxxxxxx> wrote: > > > > Ok, IOW the vma would be already locked before mmap() is called... > > Yup. > > > Just to confirm, you are suggesting to remove vma_start_write() call > > from hfi1_file_mmap() and let vm_flags_reset() generate an assertion > > if it's ever called with an unlocked vma, correct? > > Correct. Got it. Will update in the next version. Thanks! > > Linus >