[linux] 02/02: x86/tlb: Drop the _GPL from the cpu_tlbstate export

debian-kernel at lists.debian.org debian-kernel at lists.debian.org
Fri Jan 5 20:20:07 UTC 2018


This is an automated email from the git hooks/post-receive script.

carnil pushed a commit to branch sid
in repository linux.

commit 9a96b9c27a63eef5d93577aac9d3d66dd2806069
Author: Salvatore Bonaccorso <carnil at debian.org>
Date:   Fri Jan 5 21:16:41 2018 +0100

    x86/tlb: Drop the _GPL from the cpu_tlbstate export
---
 debian/changelog                                   |  1 +
 ...rop-the-_GPL-from-the-cpu_tlbstate-export.patch | 44 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 46 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index a849553..777f989 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -62,6 +62,7 @@ linux (4.14.12-1) UNRELEASED; urgency=medium
   * Revert "scsi: libsas: allow async aborts"
     Fixes "Oops: NULL pointer dereference - RIP:
     isci_task_abort_task+0x30/0x3e0 [isci]" (Closes: #882414)
+  * x86/tlb: Drop the _GPL from the cpu_tlbstate export
 
  -- Ben Hutchings <ben at decadent.org.uk>  Thu, 28 Dec 2017 01:18:05 +0000
 
diff --git a/debian/patches/bugfix/all/x86-tlb-Drop-the-_GPL-from-the-cpu_tlbstate-export.patch b/debian/patches/bugfix/all/x86-tlb-Drop-the-_GPL-from-the-cpu_tlbstate-export.patch
new file mode 100644
index 0000000..aca954b
--- /dev/null
+++ b/debian/patches/bugfix/all/x86-tlb-Drop-the-_GPL-from-the-cpu_tlbstate-export.patch
@@ -0,0 +1,44 @@
+From: Thomas Gleixner <tglx at linutronix.de>
+Date: Thu, 4 Jan 2018 22:19:04 +0100
+Subject: x86/tlb: Drop the _GPL from the cpu_tlbstate export
+Origin: https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=1e5476815fd7f98b888e01a0f9522b63085f96c9
+
+The recent changes for PTI touch cpu_tlbstate from various tlb_flush
+inlines. cpu_tlbstate is exported as GPL symbol, so this causes a
+regression when building out of tree drivers for certain graphics cards.
+
+Aside of that the export was wrong since it was introduced as it should
+have been EXPORT_PER_CPU_SYMBOL_GPL().
+
+Use the correct PER_CPU export and drop the _GPL to restore the previous
+state which allows users to utilize the cards they payed for.
+
+As always I'm really thrilled to make this kind of change to support the
+#friends (or however the hot hashtag of today is spelled) from that closet
+sauce graphics corp.
+
+Fixes: 1e02ce4cccdc ("x86: Store a per-cpu shadow copy of CR4")
+Fixes: 6fd166aae78c ("x86/mm: Use/Fix PCID to optimize user/kernel switches")
+Reported-by: Kees Cook <keescook at google.com>
+Signed-off-by: Thomas Gleixner <tglx at linutronix.de>
+Cc: Greg Kroah-Hartman <gregkh at linuxfoundation.org>
+Cc: Peter Zijlstra <peterz at infradead.org>
+Cc: Andy Lutomirski <luto at kernel.org>
+Cc: stable at vger.kernel.org
+---
+ arch/x86/mm/init.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/arch/x86/mm/init.c b/arch/x86/mm/init.c
+index 80259ad..6b462a4 100644
+--- a/arch/x86/mm/init.c
++++ b/arch/x86/mm/init.c
+@@ -870,7 +870,7 @@ __visible DEFINE_PER_CPU_SHARED_ALIGNED(struct tlb_state, cpu_tlbstate) = {
+ 	.next_asid = 1,
+ 	.cr4 = ~0UL,	/* fail hard if we screw up cr4 shadow initialization */
+ };
+-EXPORT_SYMBOL_GPL(cpu_tlbstate);
++EXPORT_PER_CPU_SYMBOL(cpu_tlbstate);
+ 
+ void update_cache_mode_entry(unsigned entry, enum page_cache_mode cache)
+ {
diff --git a/debian/patches/series b/debian/patches/series
index d2d154e..ff0fee0 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -83,6 +83,7 @@ bugfix/all/i40e-fix-flags-declaration.patch
 bugfix/all/xen-time-do-not-decrease-steal-time-after-live-migra.patch
 bugfix/all/e1000e-fix-e1000_check_for_copper_link_ich8lan-return-value.patch
 debian/revert-scsi-libsas-allow-async-aborts.patch
+bugfix/all/x86-tlb-Drop-the-_GPL-from-the-cpu_tlbstate-export.patch
 
 # Miscellaneous features
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/kernel/linux.git



More information about the Kernel-svn-changes mailing list