[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080508131149.GB7718@cs181133002.pp.htv.fi>
Date: Thu, 8 May 2008 16:11:49 +0300
From: Adrian Bunk <bunk@...nel.org>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: "H. Peter Anvin" <hpa@...or.com>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Rene Herman <rene.herman@...access.nl>,
Yinghai Lu <yhlu.kernel@...il.com>,
Ingo Molnar <mingo@...e.hu>,
Linux Kernel <linux-kernel@...r.kernel.org>,
akpm@...ux-foundation.org, Pavel Machek <pavel@...e.cz>
Subject: Re: [PATCH] x86: introduce a new Linux defined feature flag for
PAT support
On Thu, May 08, 2008 at 02:49:19PM +0200, Thomas Gleixner wrote:
> On Wed, 7 May 2008, H. Peter Anvin wrote:
> > Linus Torvalds wrote:
> > >
> > > > *Certainly* I don't want anything like this crap:
> > > >
> > > > > - if (cpu_has_pat)
> > > > > + if (cpu_has_pat && cpu_has_pat_good)
> > >
> > > This in fact is likely the best part of it.
> > >
> > > Because that at least guarantees that we never say we have a good PAT when
> > > the hardware doesn't even report it.
> > >
> > > As it is, we seem to just blindly override hardware. It may be correct for
> > > all the models we override, but still..
> > >
> >
> > Yah, this is not good. We should mask out the bit, but never, ever, set it if
> > it was clear to begin with (unless we have it on really, *really*, good
> > authority.)
> >
> > I'm embarrassed to have let that slink by.
>
> /me too.
>
> Fix below.
>
> Thanks,
> tglx
>...
> The white list is kept for now to ensure that we can rely on known to
> work CPU types and concentrate on the software induced problems
> instead of fighthing CPU erratas and subtle wreckage caused by not yet
> verified CPUs. Once the PAT code has stabilized enough, we can remove
> the white list and open the can of worms.
>...
> +#ifdef CONFIG_X86_PAT
> +void __cpuinit validate_pat_support(struct cpuinfo_x86 *c)
> +{
> + switch (c->x86_vendor) {
> + case X86_VENDOR_AMD:
> + if (c->x86 >= 0xf && c->x86 <= 0x11)
> + return;
> + break;
> + case X86_VENDOR_INTEL:
> + if (c->x86 == 0xF || (c->x86 == 6 && c->x86_model >= 15))
> + return;
> + break;
> + }
>...
This still has the inconsistent handling of future CPUs between AMD
and Intel.
IMHO we should also assume for future AMD CPUs that PAT will work until
proven otherwise.
Besides this, I didn't spot any problem in the patch.
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists