LKML Archive on lore.kernel.org
 help / color / Atom feed
From: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
To: x86@kernel.org, Borislav Petkov <bp@suse.de>,
	Ingo Molnar <mingo@kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>
Cc: Len Brown <len.brown@intel.com>,
	"Ravi V. Shankar" <ravi.v.shankar@intel.com>,
	linux-kernel@vger.kernel.org, Andy Lutomirski <luto@kernel.org>,
	Tony Luck <tony.luck@intel.com>,
	"Peter Zijlstra (Intel)" <peterz@infradead.org>,
	Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
Subject: [PATCH 0/3] x86: Add initial support to discover Intel hybrid CPUs
Date: Fri,  2 Oct 2020 13:19:28 -0700
Message-ID: <20201002201931.2826-1-ricardo.neri-calderon@linux.intel.com> (raw)

Add support to discover and enumerate CPUs in Intel hybrid parts. A hybrid
part has CPUs with more than one type of micro-architecture. Thus, certain
features may only be present in a specific CPU type.

It is useful to know the type of CPUs present in a system. For instance,
perf may need to handle CPUs differently depending on the type of micro-
architecture. Decoding machine check error logs may need the additional
micro-architecture type information, so include that in the log.

A hybrid part can be identified by reading a new CPUID feature bit.
Likewise, CPUID contains information about the CPU type as well as a new
native model ID. Details can be found in the Intel manual (SDM, [1]).

This series adds support for Intel hybrid parts in two areas: a) adding
the hybrid feature bit as well as struct cpuinfo_x86; and b) decode machine
check errors on hybrid parts.

A later submission will use the proposed functionality to expose the CPU
topology to user space.

Thanks and BR,
Ricardo

[1].
https://software.intel.com/content/dam/develop/public/us/en/documents/325462-sdm-vol-1-2abcd-3abcd.pdf
Vol 2. Section 3.2.CPUID leaf 0x1a

Ricardo Neri (3):
  x86/cpufeatures: Enumerate hybrid CPU feature bit
  x86/cpu: Describe hybrid CPUs in cpuinfo_x86
  x86/mce: include type of core when reporting a machine check error

 arch/x86/include/asm/cpufeatures.h |  1 +
 arch/x86/include/asm/processor.h   | 13 +++++++++++++
 arch/x86/include/uapi/asm/mce.h    |  1 +
 arch/x86/kernel/cpu/common.c       |  5 +++++
 arch/x86/kernel/cpu/mce/core.c     |  7 +++++++
 5 files changed, 27 insertions(+)

-- 
2.17.1


             reply index

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-02 20:19 Ricardo Neri [this message]
2020-10-02 20:19 ` [PATCH 1/3] x86/cpufeatures: Enumerate hybrid CPU feature bit Ricardo Neri
2020-10-02 20:19 ` [PATCH 2/3] x86/cpu: Describe hybrid CPUs in cpuinfo_x86 Ricardo Neri
2020-10-02 20:34   ` Borislav Petkov
2020-10-02 21:02     ` Ricardo Neri
2020-10-02 21:03       ` Borislav Petkov
2020-10-02 23:41         ` Ricardo Neri
2020-10-02 20:19 ` [PATCH 3/3] x86/mce: include type of core when reporting a machine check error Ricardo Neri
2020-10-03  1:39 ` [PATCH 0/3] x86: Add initial support to discover Intel hybrid CPUs Thomas Gleixner
2020-10-03  2:17   ` Luck, Tony
2020-10-03  9:04     ` Borislav Petkov
2020-10-06  0:24       ` Ricardo Neri
2020-10-03 10:46     ` Thomas Gleixner
2020-10-03 14:39       ` Peter Zijlstra
2020-10-06  0:21       ` Ricardo Neri

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=20201002201931.2826-1-ricardo.neri-calderon@linux.intel.com \
    --to=ricardo.neri-calderon@linux.intel.com \
    --cc=bp@suse.de \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=ravi.v.shankar@intel.com \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.com \
    --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

LKML Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/lkml/0 lkml/git/0.git
	git clone --mirror https://lore.kernel.org/lkml/1 lkml/git/1.git
	git clone --mirror https://lore.kernel.org/lkml/2 lkml/git/2.git
	git clone --mirror https://lore.kernel.org/lkml/3 lkml/git/3.git
	git clone --mirror https://lore.kernel.org/lkml/4 lkml/git/4.git
	git clone --mirror https://lore.kernel.org/lkml/5 lkml/git/5.git
	git clone --mirror https://lore.kernel.org/lkml/6 lkml/git/6.git
	git clone --mirror https://lore.kernel.org/lkml/7 lkml/git/7.git
	git clone --mirror https://lore.kernel.org/lkml/8 lkml/git/8.git
	git clone --mirror https://lore.kernel.org/lkml/9 lkml/git/9.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ https://lore.kernel.org/lkml \
		linux-kernel@vger.kernel.org
	public-inbox-index lkml

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-kernel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git