alistair23-linux/arch/x86
Kan Liang 156c8b58ef perf/x86/intel/uncore: Fix hardcoded index of Broadwell extra PCI devices
Masayoshi Mizuma reported that a warning message is shown while a CPU is
hot-removed on Broadwell servers:

  WARNING: CPU: 126 PID: 6 at arch/x86/events/intel/uncore.c:988
  uncore_pci_remove+0x10b/0x150
  Call Trace:
   pci_device_remove+0x42/0xd0
   device_release_driver_internal+0x148/0x220
   pci_stop_bus_device+0x76/0xa0
   pci_stop_root_bus+0x44/0x60
   acpi_pci_root_remove+0x1f/0x80
   acpi_bus_trim+0x57/0x90
   acpi_bus_trim+0x2e/0x90
   acpi_device_hotplug+0x2bc/0x4b0
   acpi_hotplug_work_fn+0x1a/0x30
   process_one_work+0x174/0x3a0
   worker_thread+0x4c/0x3d0
   kthread+0xf8/0x130

This bug was introduced by:

  commit 15a3e845b0 ("perf/x86/intel/uncore: Fix SBOX support for Broadwell CPUs")

The index of "QPI Port 2 filter" was hardcode to 2, but this conflicts with the
index of "PCU.3" which is "HSWEP_PCI_PCU_3", which equals to 2 as well.

To fix the conflict, the hardcoded index needs to be cleaned up:

 - introduce a new enumerator "BDX_PCI_QPI_PORT2_FILTER" for "QPI Port 2
   filter" on Broadwell,
 - increase UNCORE_EXTRA_PCI_DEV_MAX by one,
 - clean up the hardcoded index.

Debugged-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Suggested-by: Ingo Molnar <mingo@kernel.org>
Reported-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Signed-off-by: Kan Liang <kan.liang@linux.intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vince Weaver <vincent.weaver@maine.edu>
Cc: msys.mizuma@gmail.com
Cc: stable@vger.kernel.org
Fixes: 15a3e845b0 ("perf/x86/intel/uncore: Fix SBOX support for Broadwell CPUs")
Link: http://lkml.kernel.org/r/1532953688-15008-1-git-send-email-kan.liang@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2018-07-31 07:43:37 +02:00
..
boot x86/boot: Fix if_changed build flip/flop bug 2018-07-25 12:00:08 +02:00
configs
crypto crypto: x86 - Add missing RETs 2018-07-01 23:33:20 +08:00
entry x86/entry/64: Remove %ebx handling from error_entry/exit 2018-07-24 10:07:36 +02:00
events perf/x86/intel/uncore: Fix hardcoded index of Broadwell extra PCI devices 2018-07-31 07:43:37 +02:00
hyperv x86/hyper-v: Fix the circular dependency in IPI enlightenment 2018-07-06 12:32:59 +02:00
ia32
include locking/pvqspinlock/x86: Use LOCK_PREFIX in __pv_queued_spin_unlock() assembly code 2018-07-25 11:22:20 +02:00
kernel x86/apic: Future-proof the TSC_DEADLINE quirk for SKX 2018-07-24 10:05:13 +02:00
kvm kvm, mm: account shadow page tables to kmemcg 2018-07-26 19:38:03 -07:00
lib libnvdimm for 4.18 2018-06-08 17:21:52 -07:00
math-emu
mm x86/mm: Clean up the printk()s in show_fault_oops() 2018-06-27 14:08:11 +02:00
net treewide: kmalloc() -> kmalloc_array() 2018-06-12 16:19:22 -07:00
oprofile
pci treewide: kzalloc() -> kcalloc() 2018-06-12 16:19:22 -07:00
platform x86/efi: Access EFI MMIO data as unencrypted when SEV is active 2018-07-22 14:10:38 +02:00
power
purgatory x86/purgatory: add missing FORCE to Makefile target 2018-07-14 11:11:09 -07:00
ras
realmode
tools
um mm: use vma_init() to initialize VMAs on stack and data segments 2018-07-26 19:38:03 -07:00
video
xen xen: fixes for 4.18-rc5 2018-07-14 12:30:13 -07:00
.gitignore
Kbuild
Kconfig x86/asm/memcpy_mcsafe: Fix copy_to_user_mcsafe() exception handling 2018-07-16 00:05:05 +02:00
Kconfig.cpu
Kconfig.debug
Makefile Merge branch 'linus' into x86/urgent 2018-06-22 21:20:35 +02:00
Makefile.um
Makefile_32.cpu