All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleg Nesterov <oleg@redhat.com>
To: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Cc: Ingo Molnar <mingo@elte.hu>,
	Peter Zijlstra <peterz@infradead.org>,
	Ananth N Mavinakayanahalli <ananth@in.ibm.com>,
	Anton Arapov <anton@redhat.com>, Hugh Dickins <hughd@google.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/4] uprobes: __replace_page() needs munlock_vma_page()
Date: Thu, 26 Jul 2012 12:16:08 +0200	[thread overview]
Message-ID: <20120726101608.GA7197@redhat.com> (raw)
In-Reply-To: <20120726051839.GE3810@linux.vnet.ibm.com>

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.


      reply	other threads:[~2012-07-26 10:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-12 17:09 [PATCH 0/4] uprobes: vma_address() fixlets Oleg Nesterov
2012-07-12 17:10 ` [PATCH 1/4] uprobes: introduce vaddr_to_offset(vma, vaddr) Oleg Nesterov
2012-07-26  4:58   ` Srikar Dronamraju
2012-07-12 17:10 ` [PATCH 2/4] uprobes: fix register_for_each_vma()->vma_address() check Oleg Nesterov
2012-07-26  4:59   ` Srikar Dronamraju
2012-07-12 17:10 ` [PATCH 3/4] uprobes: rename vma_address() and make it return "unsigned long" Oleg Nesterov
2012-07-26  5:00   ` Srikar Dronamraju
2012-07-26 10:28     ` Oleg Nesterov
2012-07-27  6:22       ` Srikar Dronamraju
2012-07-12 17:10 ` [PATCH 4/4] uprobes: __replace_page() needs munlock_vma_page() Oleg Nesterov
2012-07-26  5:18   ` Srikar Dronamraju
2012-07-26 10:16     ` Oleg Nesterov [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120726101608.GA7197@redhat.com \
    --to=oleg@redhat.com \
    --cc=ananth@in.ibm.com \
    --cc=anton@redhat.com \
    --cc=hughd@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.org \
    --cc=srikar@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.