• Thomas Gleixner's avatar
    x86/tlb: Drop the _GPL from the cpu_tlbstate export · 8832f29d
    Thomas Gleixner authored
    commit 1e547681 upstream.
    
    CVE-2017-5754
    
    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
    sauce graphics corp.
    
    Fixes: 1e02ce4c ("x86: Store a per-cpu shadow copy of CR4")
    Fixes: 6fd166aa ("x86/mm: Use/Fix PCID to optimize user/kernel switches")
    Reported-by: default avatarKees Cook <keescook@google.com>
    Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
    Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Andy Lutomirski <luto@kernel.org>
    Cc: Thomas Backlund <tmb@mageia.org>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    
    (cherry picked from commit a4c1c753)
    Signed-off-by: default avatarAndy Whitcroft <apw@canonical.com>
    8832f29d
init.c 22 KB