Hi Michal, On Fri, 21 Aug 2020 at 13:23, Michal Hocko <mhocko@xxxxxxxx> wrote: > > On Fri 21-08-20 09:24:02, Michal Hocko wrote: > > On Fri 21-08-20 08:51:57, Sumit Semwal wrote: > [...] > > > Indeed. so does it sound ok to add an access_remote_vma_mmap_lockheld() version? > > > > You will still need to take the lock if the pointer belongs to a remote > > address space. But how are you going to find out? > > Scratch that. I didn't realize prctl is always called with the current > context. So there will never be a pointer from a remote process. Going > with a variant which doesn't take mmap_sem would be safe. Thanks much for the review and confirmation. I will prepare the updated patchset and send it out with the review comments incorporated. > > Sorry about the confusion. Not at all! > -- > Michal Hocko > SUSE Labs Best, Sumit.