[Deepin-Kernel-SIG] [linux 6.6-y] [Intel] [Backport] DMR new CPU model support#1483
[Deepin-Kernel-SIG] [linux 6.6-y] [Intel] [Backport] DMR new CPU model support#1483Avenger-285714 wants to merge 2 commits intodeepin-community:linux-6.6.yfrom
Conversation
commit d1fb034 upstream. Pantherlake is a mobile CPU. Diamond Rapids next generation Xeon. Intel-SIG: commit d1fb034 x86/cpu: Add two Intel CPU model numbers. Support DMR new CPU models Signed-off-by: Tony Luck <tony.luck@intel.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Link: https://lore.kernel.org/all/20240923173750.16874-1-tony.luck%40intel.com [ Quanxian Wang: amend commit log ] Signed-off-by: Quanxian Wang <quanxian.wang@intel.com> Signed-off-by: WangYuli <wangyuli@aosc.io>
commit 70d1d98 upstream. This model was added as INTEL_PANTHERCOVE_X (based on the name of the core) with a comment that the platform name is Diamond Rapids. It was also placed at the end of the file in a new section for family 19 processors. This is different from previous naming as Andrew Cooper noted. PeterZ agreed and posted a patch[1] to fix the name and move it in sequence with other Xeon servers. But without a commit description or sign-off the patch wasn't ever applied. Patch updated to cover one additional use of the #define by turbostat and to change the "Family 6" comment to also list 18 and 19 since new models in these families are mixed in with family 6. Originally-by: Peter Zijlstra <peterz@infradead.org> Intel-SIG: commit 70d1d98 x86/cpu: Rename and move CPU model entry for Diamond Rapids. Support DMR new CPU models Signed-off-by: Tony Luck <tony.luck@intel.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de> Signed-off-by: Ingo Molnar <mingo@kernel.org> Reviewed-by: Sohil Mehta <sohil.mehta@intel.com> Link: https://lore.kernel.org/all/20250214130205.GK14028@noisy.programming.kicks-ass.net/ # [1] [ Quanxian Wang: amend commit log ] Signed-off-by: Quanxian Wang <quanxian.wang@intel.com> Signed-off-by: WangYuli <wangyuli@aosc.io>
Reviewer's guide (collapsed on small PRs)Reviewer's GuideBackports Intel x86 CPU identification updates to support the Diamond Rapids (family 19) and Panther Lake models and switches relevant platform drivers from legacy family/model matching to VFM-based matching, wiring the new Diamond Rapids ID into Intel Speed Select (ISST) and TPMI power domain support while omitting upstream turbostat changes. Class diagram for updated Intel CPU model identifiers and match tablesclassDiagram
class x86_cpu_id {
+u32 vendor
+u32 family
+u32 model
+unsigned long driver_data
}
class intel_family_macros {
<<macro_definitions>>
+INTEL_ATOM_CRESTMONT
+INTEL_ATOM_CRESTMONT_X
+INTEL_ATOM_DARKMONT_X
+INTEL_EMERALDRAPIDS_X
+INTEL_GRANITERAPIDS_D
+INTEL_GRANITERAPIDS_X
+INTEL_ICELAKE_D
+INTEL_ICELAKE_X
+INTEL_SAPPHIRERAPIDS_X
+INTEL_SKYLAKE_X
+INTEL_DIAMONDRAPIDS_X
+INTEL_PANTHERLAKE_L
}
class isst_if_common {
+x86_cpu_id isst_cpu_ids[]
}
class tpmi_power_domains {
+x86_cpu_id tpmi_cpu_ids[]
}
intel_family_macros <.. x86_cpu_id : uses_for_matching
isst_if_common --> x86_cpu_id : uses
tpmi_power_domains --> x86_cpu_id : uses
class match_macros {
<<macros>>
+X86_MATCH_VFM(vfm, data)
}
match_macros <.. isst_if_common : used_in_isst_cpu_ids
match_macros <.. tpmi_power_domains : used_in_tpmi_cpu_ids
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- The new INTEL_PANTHERLAKE_L macro is introduced but not used in this backport; consider dropping it here unless there is an immediate in-tree consumer to keep the backport minimal and focused on DMR support.
- In isst_if_common.c, the added INTEL_DIAMONDRAPIDS_X entry is appended near the end; if feasible, align the ordering of X86_MATCH_VFM entries with the upstream commit to simplify future syncs and reduce diff noise.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The new INTEL_PANTHERLAKE_L macro is introduced but not used in this backport; consider dropping it here unless there is an immediate in-tree consumer to keep the backport minimal and focused on DMR support.
- In isst_if_common.c, the added INTEL_DIAMONDRAPIDS_X entry is appended near the end; if feasible, align the ordering of X86_MATCH_VFM entries with the upstream commit to simplify future syncs and reduce diff noise.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
There was a problem hiding this comment.
Pull request overview
This PR backports Diamond Rapids (DMR) CPU model support from upstream kernel commits to the 6.6-y kernel branch. The changes add support for Intel's Diamond Rapids (Family 19) and Panther Lake processors by defining new CPU model identifiers and registering them with relevant platform drivers.
Changes:
- Added CPU model definitions for INTEL_DIAMONDRAPIDS_X (Family 19, model 0x01) and INTEL_PANTHERLAKE_L (Family 6, model 0xCC)
- Updated TPMI power domains driver to recognize Diamond Rapids processors
- Modernized speed_select_if driver by converting from X86_MATCH_INTEL_FAM6_MODEL to X86_MATCH_VFM macros and added Diamond Rapids support
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| arch/x86/include/asm/intel-family.h | Adds CPU model definitions for Diamond Rapids (Family 19) and Panther Lake processors |
| drivers/platform/x86/intel/tpmi_power_domains.c | Registers Diamond Rapids in the TPMI power domains CPU ID table |
| drivers/platform/x86/intel/speed_select_if/isst_if_common.c | Converts macro usage to X86_MATCH_VFM and adds Diamond Rapids with HPM support |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| #define INTEL_GRANITERAPIDS_D IFM(6, 0xAE) | ||
|
|
||
| /* Family 19 */ | ||
| #define INTEL_DIAMONDRAPIDS_X IFM(19, 0x01) /* Panther Cove */ |
There was a problem hiding this comment.
Missing the INTEL_FAM19_DIAMONDRAPIDS_X definition. Following the codebase convention (see INTEL_FAM5_QUARK_X1000 at line 264), CPU model definitions for non-Family-6 processors should include both a INTEL_FAM{N}_ variant with the model number and an INTEL_ variant using IFM. Add: #define INTEL_FAM19_DIAMONDRAPIDS_X 0x01 before this line.
| #define INTEL_FAM6_LUNARLAKE_M 0xBD | ||
| #define INTEL_LUNARLAKE_M IFM(6, 0xBD) | ||
|
|
||
| #define INTEL_PANTHERLAKE_L IFM(6, 0xCC) |
There was a problem hiding this comment.
Missing the INTEL_FAM6_PANTHERLAKE_L definition. Following the codebase convention (see INTEL_FAM6_LUNARLAKE_M at line 196), Family 6 CPU model definitions should include both a INTEL_FAM6_ variant with the model number and an INTEL_ variant using IFM. Add: #define INTEL_FAM6_PANTHERLAKE_L 0xCC before this line.
backporting two commits which is related with DMR CPU module support
70d1d98,x86/cpu: Rename and move CPU model entry for Diamond Rapids,2025-09-17 11:22:11,Tony Luck tony.luck@intel.com,v6.18-rc1
d1fb034,x86/cpu: Add two Intel CPU model numbers,2024-09-26 10:47:49,Tony Luck tony.luck@intel.com,v6.12-rc1
for 70d1d98,
1.we remove turbostat updates(tools/power/x86/turbostat/turbostat.c) updates which is not supported by Intel.
2.also we add new CPU model family support for module speed_select_if/isst_if_common.c
Summary by Sourcery
Backport Intel Diamond Rapids and related CPU model support to the 6.6-y kernel platform drivers.
New Features:
Enhancements: