Messages in this thread | ![/](/images/icornerl.gif) | | Date | Thu, 19 Jan 2023 10:31:10 +0100 | From | Michal Hocko <> | Subject | Re: [PATCH 17/41] mm/mmap: move VMA locking before anon_vma_lock_write call |
| |
On Wed 18-01-23 13:48:13, Suren Baghdasaryan wrote: > On Wed, Jan 18, 2023 at 1:33 PM Michal Hocko <mhocko@suse.com> wrote: [...] > > So it will become: > > Move VMA flag modification (which now implies VMA locking) before > > vma_adjust_trans_huge() to ensure the modifications are done after VMA > > has been locked. Because vma_adjust_trans_huge() modifies the VMA and such > > modifications should be done under VMA write-lock protection. > > > > which is effectivelly saying > > vma_adjust_trans_huge() modifies the VMA and such modifications should > > be done under VMA write-lock protection so move VMA flag modifications > > before so all of them are covered by the same write protection. > > > > right? > > Yes, and the wording in the latter version is simpler to understand > IMO, so I would like to adopt it. Do you agree?
of course. -- Michal Hocko SUSE Labs
| ![\](/images/icornerr.gif) |