linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Robin Holt <holt@sgi.com>
To: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Cc: Robin Holt <holt@sgi.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Marcelo Tosatti <mtosatti@redhat.com>,
	Gleb Natapov <gleb@redhat.com>, Avi Kivity <avi.kivity@gmail.com>,
	Andrea Arcangeli <aarcange@redhat.com>,
	LKML <linux-kernel@vger.kernel.org>, KVM <kvm@vger.kernel.org>,
	Linux Memory Management List <linux-mm@kvack.org>
Subject: Re: [PATCH] mm: mmu_notifier: re-fix freed page still mapped in secondary MMU
Date: Wed, 1 May 2013 04:03:38 -0500	[thread overview]
Message-ID: <20130501090338.GP3658@sgi.com> (raw)
In-Reply-To: <516EEF6F.8060905@linux.vnet.ibm.com>

On Thu, Apr 18, 2013 at 02:52:31AM +0800, Xiao Guangrong wrote:
> On 04/18/2013 02:45 AM, Robin Holt wrote:
> 
> >>>>>>> For the v3.10 release, we should work on making this more
> >>>>>>> correct and completely documented.
> >>>>>>
> >>>>>> Better document is always welcomed.
> >>>>>>
> >>>>>> Double call ->release is not bad, like i mentioned it in the changelog:
> >>>>>>
> >>>>>> it is really rare (e.g, can not happen on kvm since mmu-notify is unregistered
> >>>>>> after exit_mmap()) and the later call of multiple ->release should be
> >>>>>> fast since all the pages have already been released by the first call.
> >>>>>>
> >>>>>> But, of course, it's great if you have a _light_ way to avoid this.
> >>>>>
> >>>>> Getting my test environment set back up took longer than I would have liked.
> >>>>>
> >>>>> Your patch passed.  I got no NULL-pointer derefs.
> >>>>
> >>>> Thanks for your test again.
> >>>>
> >>>>>
> >>>>> How would you feel about adding the following to your patch?
> >>>>
> >>>> I prefer to make these changes as a separate patch, this change is the
> >>>> improvement, please do not mix it with bugfix.
> >>>
> >>> I think your "improvement" classification is a bit deceiving.  My previous
> >>> patch fixed the bug in calling release multiple times.  Your patch without
> >>> this will reintroduce that buggy behavior.  Just because the bug is already
> >>> worked around by KVM does not mean it is not a bug.
> >>
> >> As your tested, calling ->release() multiple times can work, but just make your
> >> testcase more _slower_. So your changes is trying to speed it up - it is a
> >> improvement.
> >>
> >> Well, _if_ it is really a bug, could you please do not fix two bugs in one patch?
> > 
> > The code, as is, does not call ->release() multiple times.  Your code
> > changes the behavior to call it multiple times.  You are introducing the
> > bug by your code changes.  Why not fix the bug you create in the patch
> > which creates it?
> 
> Andrew, your thought?
> 

What ever happened with this?

Robin

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2013-05-01  9:03 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-16  6:39 [PATCH] mm: mmu_notifier: re-fix freed page still mapped in secondary MMU Xiao Guangrong
2013-04-16  9:31 ` Robin Holt
2013-04-16 10:26   ` Xiao Guangrong
2013-04-16 11:25     ` Robin Holt
2013-04-16 11:43       ` Robin Holt
2013-04-16 13:07         ` Xiao Guangrong
2013-04-16 18:08           ` Robin Holt
2013-04-17  2:55             ` Xiao Guangrong
2013-04-17 14:10               ` Robin Holt
2013-04-17 18:41                 ` Xiao Guangrong
2013-04-17 18:45                   ` Robin Holt
2013-04-17 18:52                     ` Xiao Guangrong
2013-05-01  9:03                       ` Robin Holt [this message]
2013-04-17 23:38   ` Simon Jeons

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=20130501090338.GP3658@sgi.com \
    --to=holt@sgi.com \
    --cc=aarcange@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=avi.kivity@gmail.com \
    --cc=gleb@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mtosatti@redhat.com \
    --cc=xiaoguangrong@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).