Messages in this thread | | | Date | Thu, 26 Jul 2012 12:16:08 +0200 | From | Oleg Nesterov <> | Subject | Re: [PATCH 4/4] uprobes: __replace_page() needs munlock_vma_page() |
| |
On 07/26, Srikar Dronamraju wrote: > > * Oleg Nesterov <oleg@redhat.com> [2012-07-12 19:10:25]: > > > Like do_wp_page(), __replace_page() should do munlock_vma_page() > > for the case when the old page still has other !VM_LOCKED mappings. > > Unfortunately this needs mm/internal.h. > > > > Also, move put_page() outside of ptl lock. This doesn't really > > matter but looks a bit better. > > > > Signed-off-by: Oleg Nesterov <oleg@redhat.com> > > One thing I wanted to check is, should we mlock the new page, i.e the > replacing page.
Yes, currently page_add_new_anon_rmap() makes it Mlocked/Unevictable.
> It may not a good idea to mlock the new page > because then we can end up adding too many pages to the unevictable > list.
Perhaps.
But. I think this is not really important. What is more important, uprobe_register() should simply not add "too many pages", iow we should re-use the same page if possible. This was another reason for (buggy) http://marc.info/?l=linux-kernel&m=134013566617717 I sent before. I'll try to return to this later.
> Acked-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Thanks!
Oleg.
| |