LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Andi Kleen <ak@suse.de>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: mingo@elte.hu, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] [1/1] CPA: Flush the caches when setting pages not present v2
Date: Mon, 11 Feb 2008 18:36:03 +0100	[thread overview]
Message-ID: <200802111836.03195.ak@suse.de> (raw)
In-Reply-To: <alpine.LFD.1.00.0802111803290.12988@apollo.tec.linutronix.de>


> This is suboptimal though, as it will trigger a wbinvd() everytime
> when we hit a non present pte in a range, whether we did set the entry
> in question to not present or not.

Do you think that's common? I considered this while writing the code,
but figured it was just a oddball case not worth caring about.

DEBUG_PAGEALLOC does not call this normally anyways and people
should not call this for unallocated mappings anyways. 

> The gart code unmapping is a special case. This only happens during
> boot, so adding a wbinvd() to the gart code is solving this issue
> without imposing it on other use cases.
> 
> Another solution for this would be to change the mapping to uncached
> before unmapping, so we could avoid the wbinvd() completely.

That will work for pci-gart, but not for some future users of set_memory_np()
I plan to submit (they run potentially with multiple CPUs online and doing callbacks
there would be quite ugly). So I would prefer  if you kept some variant of my original patch.

-Andi


      reply	other threads:[~2008-02-11 17:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-11 13:16 Andi Kleen
2008-02-11 17:21 ` Thomas Gleixner
2008-02-11 17:36   ` Andi Kleen [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=200802111836.03195.ak@suse.de \
    --to=ak@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=tglx@linutronix.de \
    --subject='Re: [PATCH] [1/1] CPA: Flush the caches when setting pages not present v2' \
    /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

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).