]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Mar 2019 10:48:15 +0000 (11:48 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Mar 2019 10:48:15 +0000 (11:48 +0100)
added patches:
x86-cpu-amd-set-the-cpb-bit-unconditionally-on-f17h.patch

queue-4.14/series
queue-4.14/x86-cpu-amd-set-the-cpb-bit-unconditionally-on-f17h.patch [new file with mode: 0644]

index 8d59bd0413050e34ec14e9b0e3a57d43eda0523f..8c6c481edbc6ef816413826e55b65bfed8b76186 100644 (file)
@@ -32,3 +32,4 @@ tun-fix-blocking-read.patch
 tun-remove-unnecessary-memory-barrier.patch
 net-phy-micrel-ksz8061-link-failure-after-cable-connect.patch
 net-dsa-mv88e6xxx-fix-statistics-on-mv88e6161.patch
+x86-cpu-amd-set-the-cpb-bit-unconditionally-on-f17h.patch
diff --git a/queue-4.14/x86-cpu-amd-set-the-cpb-bit-unconditionally-on-f17h.patch b/queue-4.14/x86-cpu-amd-set-the-cpb-bit-unconditionally-on-f17h.patch
new file mode 100644 (file)
index 0000000..4d2b25e
--- /dev/null
@@ -0,0 +1,47 @@
+From 0237199186e7a4aa5310741f0a6498a20c820fd7 Mon Sep 17 00:00:00 2001
+From: Jiaxun Yang <jiaxun.yang@flygoat.com>
+Date: Tue, 20 Nov 2018 11:00:18 +0800
+Subject: x86/CPU/AMD: Set the CPB bit unconditionally on F17h
+
+From: Jiaxun Yang <jiaxun.yang@flygoat.com>
+
+commit 0237199186e7a4aa5310741f0a6498a20c820fd7 upstream.
+
+Some F17h models do not have CPB set in CPUID even though the CPU
+supports it. Set the feature bit unconditionally on all F17h.
+
+ [ bp: Rewrite commit message and patch. ]
+
+Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
+Signed-off-by: Borislav Petkov <bp@suse.de>
+Acked-by: Tom Lendacky <thomas.lendacky@amd.com>
+Cc: "H. Peter Anvin" <hpa@zytor.com>
+Cc: Ingo Molnar <mingo@redhat.com>
+Cc: Sherry Hurwitz <sherry.hurwitz@amd.com>
+Cc: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
+Cc: Thomas Gleixner <tglx@linutronix.de>
+Cc: x86-ml <x86@kernel.org>
+Link: https://lkml.kernel.org/r/20181120030018.5185-1-jiaxun.yang@flygoat.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/x86/kernel/cpu/amd.c |    8 +++-----
+ 1 file changed, 3 insertions(+), 5 deletions(-)
+
+--- a/arch/x86/kernel/cpu/amd.c
++++ b/arch/x86/kernel/cpu/amd.c
+@@ -791,11 +791,9 @@ static void init_amd_bd(struct cpuinfo_x
+ 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);
+ }