[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAPcyv4i1YYExVtXXdkCMgRvjqoeTkZdjwDVjf=sJN-qPF1LEtg@mail.gmail.com>
Date: Thu, 20 Jun 2019 16:13:04 -0700
From: Dan Williams <dan.j.williams@...el.com>
To: Andi Kleen <andi@...stfloor.org>
Cc: Bjorn Helgaas <bhelgaas@...gle.com>, Nadav Amit <namit@...are.com>,
Andrew Morton <akpm@...ux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>,
Linux-MM <linux-mm@...ck.org>, Borislav Petkov <bp@...e.de>,
Toshi Kani <toshi.kani@....com>,
Peter Zijlstra <peterz@...radead.org>,
Dave Hansen <dave.hansen@...ux.intel.com>,
Ingo Molnar <mingo@...nel.org>,
"Kleen, Andi" <andi.kleen@...el.com>
Subject: Re: [PATCH 3/3] resource: Introduce resource cache
On Thu, Jun 20, 2019 at 2:31 PM Andi Kleen <andi@...stfloor.org> wrote:
>
> Dan Williams <dan.j.williams@...el.com> writes:
> >
> > The underlying issue is that the x86-PAT implementation wants to
> > ensure that conflicting mappings are not set up for the same physical
> > address. This is mentioned in the developer manuals as problematic on
> > some cpus. Andi, is lookup_memtype() and track_pfn_insert() still
> > relevant?
>
> There have been discussions about it in the past, and the right answer
> will likely differ for different CPUs: But so far the official answer
> for Intel CPUs is that these caching conflicts should be avoided.
>
Ok.
> So I guess the cache in the original email makes sense for now.
I wouldn't go that far, but it does mean that if we go ahead with
caching the value as a dax_device property there should at least be a
debug option to assert that the device value conforms to all the other
mappings.
Another failing of the track_pfn_insert() and lookup_memtype()
implementation is that it makes it awkward to handle marking mappings
UC to prevent speculative consumption of poison. That is something
that is better handled, in my opinion, by asking the device for the
pgprot and coordinating shooting down any WB mappings of the same
physical page.
Powered by blists - more mailing lists