]> git.baikalelectronics.ru Git - kernel.git/commit
perf/x86/intel/uncore: Fix SBOX support for Broadwell CPUs
authorOskar Senft <osk@google.com>
Fri, 23 Mar 2018 13:11:30 +0000 (09:11 -0400)
committerThomas Gleixner <tglx@linutronix.de>
Fri, 20 Apr 2018 11:17:50 +0000 (13:17 +0200)
commita07fbec375f85412b9c3e5c9852f805cda5c6d2f
treee06952a1062144a3a26001e74f4a347216499485
parent2719a5d5bde01d71f84a09d63b3fe0b6e92868f2
perf/x86/intel/uncore: Fix SBOX support for Broadwell CPUs

SBOX on some Broadwell CPUs is broken because it's enabled unconditionally
despite the fact that there are no SBOXes available.

Check the Power Control Unit CAPID4 register to determine the number of
available SBOXes on the particular CPU before trying to enable them. If
there are none, nullify the SBOX descriptor so it isn't tried to be
initialized.

Signed-off-by: Oskar Senft <osk@google.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Mark van Dijk <mark@voidzero.net>
Reviewed-by: Kan Liang <kan.liang@intel.com>
Acked-by: Peter Zijlstra <peterz@infradead.org>
Cc: ak@linux.intel.com
Cc: peterz@infradead.org
Cc: eranian@google.com
Link: https://lkml.kernel.org/r/1521810690-2576-2-git-send-email-kan.liang@linux.intel.com
arch/x86/events/intel/uncore_snbep.c