linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Martin Schwidefsky <schwidefsky@de.ibm.com>
To: Hillf Danton <hillf.zj@alibaba-inc.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>, linux-mm@kvack.org
Subject: Re: [PATCH 2/2] s390/mm: use ipte range to invalidate multiple page table entries
Date: Wed, 6 Jul 2016 08:23:50 +0200	[thread overview]
Message-ID: <20160706082350.5c56ca40@mschwide> (raw)
In-Reply-To: <014601d1d73b$5a3c0420$0eb40c60$@alibaba-inc.com>

On Wed, 06 Jul 2016 12:03:28 +0800
"Hillf Danton" <hillf.zj@alibaba-inc.com> wrote:

> > 
> > +void ptep_invalidate_range(struct mm_struct *mm, unsigned long start,
> > +			   unsigned long end, pte_t *ptep)
> > +{
> > +	unsigned long nr;
> > +
> > +	if (!MACHINE_HAS_IPTE_RANGE || mm_has_pgste(mm))
> > +		return;
> > +	preempt_disable();
> > +	nr = (end - start) >> PAGE_SHIFT;
> > +	/* If the flush is likely to be local skip the ipte range */
> > +	if (nr && !cpumask_equal(mm_cpumask(mm),
> > +				 cpumask_of(smp_processor_id())))
> 
> s/smp/raw_smp/ to avoid adding schedule entry with page table
> lock held?

There can not be a schedule entry with either the page table lock held
or the preempt_disable() a few lines above.
 
> > +		__ptep_ipte_range(start, nr - 1, ptep);
> > +	preempt_enable();
> > +}
> > +EXPORT_SYMBOL(ptep_invalidate_range);
> > +
> 
> thanks
> Hillf
> 


-- 
blue skies,
   Martin.

"Reality continues to ruin my life." - Calvin.

--
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:[~2016-07-06  6:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <014201d1d738$744c8f90$5ce5aeb0$@alibaba-inc.com>
2016-07-06  4:03 ` [PATCH 2/2] s390/mm: use ipte range to invalidate multiple page table entries Hillf Danton
2016-07-06  6:23   ` Martin Schwidefsky [this message]
2016-07-06  6:42     ` Hillf Danton
2016-07-06  8:47       ` Martin Schwidefsky
2016-07-06  9:26         ` Hillf Danton
2016-07-06 10:51           ` Martin Schwidefsky
2016-07-05 12:00 [PATCH 0/2][RFC] mm callback for batched pte updates Martin Schwidefsky
2016-07-05 12:00 ` [PATCH 2/2] s390/mm: use ipte range to invalidate multiple page table entries Martin Schwidefsky

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=20160706082350.5c56ca40@mschwide \
    --to=schwidefsky@de.ibm.com \
    --cc=hillf.zj@alibaba-inc.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /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).