[kernel] r22253 - dists/wheezy-security/linux/debian/patches/bugfix/x86
Ben Hutchings
benh at moszumanska.debian.org
Mon Jan 12 05:49:17 UTC 2015
Author: benh
Date: Mon Jan 12 05:49:17 2015
New Revision: 22253
Log:
Change CVE-2013-6885 fix to (probably) work in KVM, thanks to Venkatesh Srinivas
Modified:
dists/wheezy-security/linux/debian/patches/bugfix/x86/x86-cpu-amd-add-workaround-for-family-16h-erratum-79.patch
Modified: dists/wheezy-security/linux/debian/patches/bugfix/x86/x86-cpu-amd-add-workaround-for-family-16h-erratum-79.patch
==============================================================================
--- dists/wheezy-security/linux/debian/patches/bugfix/x86/x86-cpu-amd-add-workaround-for-family-16h-erratum-79.patch Mon Jan 12 05:35:21 2015 (r22252)
+++ dists/wheezy-security/linux/debian/patches/bugfix/x86/x86-cpu-amd-add-workaround-for-family-16h-erratum-79.patch Mon Jan 12 05:49:17 2015 (r22253)
@@ -40,7 +40,12 @@
Link: http://lkml.kernel.org/r/20140114230711.GS29865@pd.tnic
Tested-by: Aravind Gopalakrishnan <aravind.gopalakrishnan at amd.com>
Signed-off-by: H. Peter Anvin <hpa at linux.intel.com>
-[bwh: Backported to 3.2: adjust filename]
+[bwh: Backported to 3.2:
+ - Adjust filename
+ - Venkatesh Srinivas pointed out we should use {rd,wr}msrl_safe() to
+ avoid crashing on KVM. This was fixed upstream by commit 8f86a7373a1c
+ ("x86, AMD: Convert to the new bit access MSR accessors") but that's too
+ much trouble to backport.]
---
arch/x86/include/asm/msr-index.h | 1 +
arch/x86/kernel/cpu/amd.c | 10 ++++++++++
@@ -67,9 +72,9 @@
+ if (c->x86 == 0x16 && c->x86_model <= 0xf) {
+ u64 val;
+
-+ rdmsrl(MSR_AMD64_LS_CFG, val);
-+ if (!(val & BIT(15)))
-+ wrmsrl(MSR_AMD64_LS_CFG, val | BIT(15));
++ if (!rdmsrl_safe(MSR_AMD64_LS_CFG, &val) &&
++ !(val & BIT(15)))
++ wrmsrl_safe(MSR_AMD64_LS_CFG, val | BIT(15));
+ }
+
}
More information about the Kernel-svn-changes
mailing list