From: Jiri Olsa Date: Wed, 18 May 2016 06:16:10 +0000 (+0200) Subject: perf/x86/intel/uncore: Remove WARN_ON_ONCE in uncore_pci_probe X-Git-Tag: v4.6.1~93 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c990e883da06630020b597f60521e528f6d0fbd;p=thirdparty%2Fkernel%2Fstable.git perf/x86/intel/uncore: Remove WARN_ON_ONCE in uncore_pci_probe commit ef3f00a4d38e01ec0e7ad1b1c8edc2f5667aaa32 upstream. 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 Cc: stable@vger.kernel.org Cc: Peter Zijlstra Signed-off-by: Thomas Gleixner Signed-off-by: Greg Kroah-Hartman --- diff --git a/arch/x86/events/intel/uncore.c b/arch/x86/events/intel/uncore.c index 7012d18bb2930..f921a1ed43f72 100644 --- a/arch/x86/events/intel/uncore.c +++ b/arch/x86/events/intel/uncore.c @@ -888,7 +888,7 @@ static int uncore_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id return -ENODEV; pkg = topology_phys_to_logical_pkg(phys_id); - if (WARN_ON_ONCE(pkg < 0)) + if (pkg < 0) return -EINVAL; if (UNCORE_PCI_DEV_TYPE(id->driver_data) == UNCORE_EXTRA_PCI_DEV) {