Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

perf/x86/intel/uncore: Remove WARN_ON_ONCE in uncore_pci_probe

When booting with nr_cpus=1, uncore_pci_probe tries to init the PCI/uncore
also for the other packages and fails with warning when they are not found.

The warning is bogus because it's correct to fail here for packages which are
not initialized. Remove it and return silently.

Fixes: cf6d445f6897 "perf/x86/uncore: Track packages, not per CPU data"
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: stable@vger.kernel.org
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>

authored by

Jiri Olsa and committed by
Thomas Gleixner
ef3f00a4 bc231d9e

+1 -1
+1 -1
arch/x86/events/intel/uncore.c
··· 891 891 return -ENODEV; 892 892 893 893 pkg = topology_phys_to_logical_pkg(phys_id); 894 - if (WARN_ON_ONCE(pkg < 0)) 894 + if (pkg < 0) 895 895 return -EINVAL; 896 896 897 897 if (UNCORE_PCI_DEV_TYPE(id->driver_data) == UNCORE_EXTRA_PCI_DEV) {