From: Rene Herman <rene.herman@keyaccess.nl>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>,
Linus Torvalds <torvalds@linux-foundation.org>,
Adrian Bunk <bunk@kernel.org>, Yinghai Lu <yhlu.kernel@gmail.com>,
Ingo Molnar <mingo@elte.hu>,
Linux Kernel <linux-kernel@vger.kernel.org>,
akpm@linux-foundation.org, Pavel Machek <pavel@suse.cz>
Subject: Re: [PATCH] x86: introduce a new Linux defined feature flag for PAT support
Date: Thu, 08 May 2008 16:44:25 +0200 [thread overview]
Message-ID: <482311C9.2010603@keyaccess.nl> (raw)
In-Reply-To: <alpine.LFD.1.10.0805081307520.3318@apollo.tec.linutronix.de>
[-- Attachment #1: Type: text/plain, Size: 1195 bytes --]
On 08-05-08 14:49, Thomas Gleixner wrote:
> Subject: x86: cleanup PAT cpu validation
> From: Thomas Gleixner <tglx@linutronix.de>
> Date: Thu, 08 May 2008 09:18:43 +0200
Thanks much. Definite ACK, very much including on the much better disable
message:
> + pat_disable(cpu_has_pat ?
> + "PAT disabled. Not yet verified on this CPU type." :
> + "PAT not supported by CPU.");
> +}
However, I'm not sure, but:
> + /* Paranoia check. */
> + if (!cpu_has_pat) {
> + printk(KERN_ERR "PAT enabled, but CPU feature cleared\n");
> + /*
> + * Panic if this happens on the secondary CPU, and we
> + * switched to PAT on the boot CPU. We have no way to
> + * undo PAT.
> + */
> + BUG_ON(boot_pat_state);
> + }
The 'if this happens on the secondary CPU' sounds a bit like this is
directly checking the secondary CPU flag but cpu_has_pat translates into
boot_cpu_has(X86_FEATURE_PAT), refers always to the boot cpu. Yes, we
continued on on the boot CPU after the error message so this triggers,
but thought I'd make sure it was also intended this way. If so, never
mind...
I'm privately again placing this on top. If anyone has any explicit
testing suggestion, I'm all ears.
Rene.
[-- Attachment #2: pat_duron7.diff --]
[-- Type: text/plain, Size: 530 bytes --]
diff --git a/arch/x86/kernel/cpu/addon_cpuid_features.c b/arch/x86/kernel/cpu/addon_cpuid_features.c
index c2e1ce3..cfa1b6b 100644
--- a/arch/x86/kernel/cpu/addon_cpuid_features.c
+++ b/arch/x86/kernel/cpu/addon_cpuid_features.c
@@ -57,6 +57,8 @@ void __cpuinit validate_pat_support(struct cpuinfo_x86 *c)
case X86_VENDOR_AMD:
if (c->x86 >= 0xf && c->x86 <= 0x11)
return;
+ if (c->x86 == 6 && c->x86_model == 7)
+ return;
break;
case X86_VENDOR_INTEL:
if (c->x86 == 0xF || (c->x86 == 6 && c->x86_model >= 15))
next prev parent reply other threads:[~2008-05-08 14:43 UTC|newest]
Thread overview: 79+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-07 1:48 2.6.26, PAT and AMD family 6 Rene Herman
2008-05-07 2:39 ` Yinghai Lu
2008-05-07 12:46 ` Undocumented and duplicated code Adrian Bunk
2008-05-07 13:14 ` Rene Herman
2008-05-07 20:52 ` 2.6.26, PAT and AMD family 6 Thomas Gleixner
2008-05-07 20:59 ` Pavel Machek
2008-05-07 21:10 ` Rene Herman
2008-05-07 21:41 ` Thomas Gleixner
2008-05-07 21:46 ` Adrian Bunk
2008-05-07 22:08 ` Thomas Gleixner
2008-05-07 22:29 ` Pavel Machek
2008-05-07 22:04 ` Rene Herman
2008-05-07 22:23 ` Rene Herman
2008-05-07 22:31 ` Yinghai Lu
2008-05-07 22:57 ` H. Peter Anvin
2008-05-08 0:02 ` Rene Herman
2008-05-08 0:03 ` H. Peter Anvin
2008-05-08 0:10 ` Rene Herman
2008-05-08 0:19 ` Linus Torvalds
2008-05-08 0:28 ` Rene Herman
2008-05-08 1:57 ` [PATCH] x86: introduce a new Linux defined feature flag for PAT support Rene Herman
2008-05-08 1:58 ` Linus Torvalds
2008-05-08 2:11 ` H. Peter Anvin
2008-05-08 2:17 ` Rene Herman
2008-05-08 2:24 ` Linus Torvalds
2008-05-08 2:28 ` H. Peter Anvin
2008-05-08 12:49 ` Thomas Gleixner
2008-05-08 13:08 ` Ingo Molnar
2008-05-08 16:44 ` H. Peter Anvin
2008-05-08 13:11 ` Adrian Bunk
2008-05-08 13:33 ` Thomas Gleixner
2008-05-08 14:44 ` Rene Herman [this message]
2008-05-08 14:53 ` Thomas Gleixner
2008-05-08 16:48 ` H. Peter Anvin
2008-05-08 16:53 ` Rene Herman
2008-05-08 2:04 ` [PATCH] x86: enable PAT support on AMD Duron model 7 Rene Herman
2008-05-08 2:08 ` Arjan van de Ven
2008-05-08 2:12 ` Rene Herman
2008-05-08 10:19 ` [PATCH] x86: introduce a new Linux defined feature flag for PAT support Andi Kleen
2008-05-08 12:40 ` Rene Herman
2008-05-08 13:39 ` Andi Kleen
2008-05-08 15:32 ` Alan Cox
2008-05-08 16:51 ` H. Peter Anvin
2008-05-08 0:21 ` 2.6.26, PAT and AMD family 6 Thomas Gleixner
2008-05-08 0:30 ` Rene Herman
2008-05-08 0:15 ` Linus Torvalds
2008-05-08 0:31 ` H. Peter Anvin
2008-05-08 10:14 ` Andi Kleen
2008-05-08 16:43 ` H. Peter Anvin
2008-05-07 21:23 ` Adrian Bunk
2008-05-07 21:54 ` Thomas Gleixner
2008-05-07 22:09 ` Adrian Bunk
2008-05-07 22:14 ` Pavel Machek
2008-05-07 22:22 ` Yinghai Lu
2008-05-07 22:37 ` Pavel Machek
2008-05-07 22:40 ` Yinghai Lu
2008-05-07 23:02 ` Pavel Machek
2008-05-07 23:02 ` Thomas Gleixner
2008-05-07 23:10 ` Pavel Machek
2008-05-07 23:46 ` Thomas Gleixner
2008-05-07 22:23 ` Yinghai Lu
2008-05-07 22:39 ` Pavel Machek
2008-05-07 22:45 ` Yinghai Lu
2008-05-07 23:06 ` Pavel Machek
2008-05-07 23:01 ` H. Peter Anvin
2008-05-07 22:26 ` Yinghai Lu
2008-05-07 22:30 ` Rene Herman
2008-05-07 22:58 ` Thomas Gleixner
2008-05-07 13:00 ` Rene Herman
2008-05-07 13:42 ` Arjan van de Ven
2008-05-07 14:09 ` Rene Herman
2008-05-07 14:24 ` Arjan van de Ven
2008-05-07 19:08 ` Rene Herman
2008-05-07 22:17 ` Arjan van de Ven
2008-05-07 19:39 ` Daniel Hazelton
2008-05-07 20:06 ` Rene Herman
2008-05-07 20:16 ` Yinghai Lu
2008-05-07 20:18 ` Yinghai Lu
2008-05-08 4:06 ` H. Peter Anvin
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=482311C9.2010603@keyaccess.nl \
--to=rene.herman@keyaccess.nl \
--cc=akpm@linux-foundation.org \
--cc=bunk@kernel.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=pavel@suse.cz \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
--cc=yhlu.kernel@gmail.com \
/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