Commit 9e27aff9 authored by Yazen Ghannam's avatar Yazen Ghannam Committed by Pu Wen
Browse files

x86/cpu/amd: Set __max_die_per_package on AMD

mainline inclusion
from mainline-v5.11-rc5
commit 76e2fc63
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7DX6V
CVE: NA

Reference: https://git.kernel.org/torvalds/c/76e2fc63ca40977af893b724b00cc2f8e9ce47a4



---------------------------

commit 76e2fc63 upstream.

Set the maximum DIE per package variable on AMD using the
NodesPerProcessor topology value. This will be used by RAPL, among
others, to determine the maximum number of DIEs on the system in order
to do per-DIE manipulations.

 [ bp: Productize into a proper patch. ]

Fixes: 028c221e ("x86/CPU/AMD: Save AMD NodeId as cpu_die_id")
Reported-by: default avatarJohnathan Smithinovic <johnathan.smithinovic@gmx.at>
Reported-by: default avatarRafael Kitover <rkitover@gmail.com>
Signed-off-by: default avatarYazen Ghannam <Yazen.Ghannam@amd.com>
Signed-off-by: default avatarBorislav Petkov <bp@suse.de>
Tested-by: default avatarJohnathan Smithinovic <johnathan.smithinovic@gmx.at>
Tested-by: default avatarRafael Kitover <rkitover@gmail.com>
Link: https://bugzilla.kernel.org/show_bug.cgi?id=210939
Link: https://lkml.kernel.org/r/20210106112106.GE5729@zn.tnic
Link: https://lkml.kernel.org/r/20210111101455.1194-1-bp@alien8.de


Signed-off-by: default avatarPu Wen <puwen@hygon.cn>
parent b09ecdad
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment