summaryrefslogtreecommitdiff
path: root/arch/x86/kernel/cpu/amd.c
diff options
context:
space:
mode:
authorStefan Agner <stefan.agner@toradex.com>2019-04-25 18:17:44 +0200
committerStefan Agner <stefan.agner@toradex.com>2019-04-25 18:17:44 +0200
commit9d9ea7dde2646ba8e36037e2679f2d98080df36b (patch)
treefdcbb9a89f3b97e14242524449bf98faba4d4e34 /arch/x86/kernel/cpu/amd.c
parent6b8816d9e21df6b1d543c49428eba01b00e4ea1c (diff)
parentc0ad257a19f48c56f2ee2e623a78251aa8664279 (diff)
Merge tag 'v4.20.17' into toradex_4.20.y
This is the 4.20.17 stable release
Diffstat (limited to 'arch/x86/kernel/cpu/amd.c')
-rw-r--r--arch/x86/kernel/cpu/amd.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/arch/x86/kernel/cpu/amd.c b/arch/x86/kernel/cpu/amd.c
index eeea634bee0a..6a25278e0092 100644
--- a/arch/x86/kernel/cpu/amd.c
+++ b/arch/x86/kernel/cpu/amd.c
@@ -818,11 +818,9 @@ static void init_amd_bd(struct cpuinfo_x86 *c)
static void init_amd_zn(struct cpuinfo_x86 *c)
{
set_cpu_cap(c, X86_FEATURE_ZEN);
- /*
- * Fix erratum 1076: CPB feature bit not being set in CPUID. It affects
- * all up to and including B1.
- */
- if (c->x86_model <= 1 && c->x86_stepping <= 1)
+
+ /* Fix erratum 1076: CPB feature bit not being set in CPUID. */
+ if (!cpu_has(c, X86_FEATURE_CPB))
set_cpu_cap(c, X86_FEATURE_CPB);
}