[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <dd7663d11e02923240f28f1e6f71fb878750ee70.camel@hpe.com>
Date: Tue, 13 Aug 2019 15:07:24 +0000
From: "Kani, Toshi" <toshi.kani@....com>
To: "isaku.yamahata@...il.com" <isaku.yamahata@...il.com>
CC: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"fei1.li@...el.com" <fei1.li@...el.com>,
"bp@...en8.de" <bp@...en8.de>, "x86@...nel.org" <x86@...nel.org>
Subject: Re: [PATCH 0/3] x86/mtrr, pat: make PAT independent from MTRR
On Tue, 2019-08-13 at 00:49 -0700, Isaku Yamahata wrote:
> On Fri, Aug 09, 2019 at 07:51:17PM +0000,
> "Kani, Toshi" <toshi.kani@....com> wrote:
>
> > On Fri, 2019-08-09 at 09:06 +0200, Borislav Petkov wrote:
> > > On Thu, Aug 08, 2019 at 08:54:17PM -0700, Isaku Yamahata wrote:
> > > > Make PAT(Page Attribute Table) independent from
> > > > MTRR(Memory Type Range Register).
> > > > Some environments (mainly virtual ones) support only PAT, but not MTRR
> > > > because PAT replaces MTRR.
> > > > It's tricky and no gain to support both MTRR and PAT except compatibility.
> > > > So some VM technologies don't support MTRR, but only PAT.
> >
> > I do not think it is technically correct on bare metal. AFAIK, MTRR is
> > still the only way to setup cache attribute in real-mode, which BIOS SMI
> > handler relies on in SMM.
>
> Then you're claiming if it's baremetal, both MTRR and PAT should be
> enabled/disabled at the same time?
No, I did not say that. My point:
- Your statement of MTTR being useless is not correct. It's still used.
The OS should leave the MTTR hand-off state.
I agree with you in general that PAT and MTTR init should be
independent. However, as Boris said, please verify the impact of your
change. As I mentioned in the Xen's example, hypervisor may have non-
default PAT hand-off setting.
Thanks,
-Toshi
Powered by blists - more mailing lists