mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Ahmed S. Darwish" <darwi@linutronix.de>
To: Andrew Cooper <andrew.cooper3@citrix.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	John Ogness <john.ogness@linutronix.de>,
	x86@kernel.org, x86-cpuid@lists.linux.dev,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [x86/cpuid] Question regarding historic leaf 0x80000000 code
Date: Thu, 20 Mar 2025 20:56:03 +0100	[thread overview]
Message-ID: <Z9xy04RL3Uww9DYy@lx-t490> (raw)
In-Reply-To: <d4fcfd91-cc92-4b3c-9dd2-56ecd754cecc@citrix.com>

On Thu, 20 Mar 2025, Andrew Cooper wrote:
>
> The problem is that for an out-of-range leaf, Intel returns the data
> from the maximum in-range leaf, rather than zeroes.
>
> On pre-AMD64-capable Intel CPUs, you'll get what amounts to junk in a
> query for leaf 0x80000000, where it's probably leaf 5 or so.
>
> Checking for the upper half of the output matching the input is a way of
> distinguishing Intel behaviour from all the other vendors.
>

Thanks a lot Andrew for all your help!

Then I'll mention that, in a comment, on top of the new CPUID scanner's
leaf 0x8000000 code.

Kind regards,

--
Ahmed S. Darwish
Linutronix GmbH

      reply	other threads:[~2025-03-20 19:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-20 19:33 Ahmed S. Darwish
2025-03-20 19:42 ` Andrew Cooper
2025-03-20 19:56   ` Ahmed S. Darwish [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=Z9xy04RL3Uww9DYy@lx-t490 \
    --to=darwi@linutronix.de \
    --cc=andrew.cooper3@citrix.com \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=john.ogness@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=x86-cpuid@lists.linux.dev \
    --cc=x86@kernel.org \
    /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

all inboxes | Powered by JetHome®