summaryrefslogtreecommitdiff
path: root/drivers/platform/wmi/tests/git@git.tavy.me:linux.git
diff options
context:
space:
mode:
authorZide Chen <zide.chen@intel.com>2026-06-02 07:49:04 -0700
committerPeter Zijlstra <peterz@infradead.org>2026-06-04 11:38:37 +0200
commit81ec618f59415bdcf3e8989e2691c1f240be27fb (patch)
tree72ad695d6470cffc8f07f1ad3b42e3ba164b7e39 /drivers/platform/wmi/tests/git@git.tavy.me:linux.git
parent3c19ea24f02658c4b8ad364458fae4d77fdb3fae (diff)
perf/x86/intel/uncore: Fix PCI device refcount leak in UPI discovery
pci_get_domain_bus_and_slot() increments the reference count of the returned PCI device and therefore requires a matching pci_dev_put(). In skx_upi_topology_cb() and discover_upi_topology(), the lookup is performed inside a loop, but pci_dev_put() is only called once after the loop. As a result, references from all previous iterations are leaked. Move pci_dev_put(dev) into the if (dev) block immediately after upi_fill_topology() returns. Opportunistically, fix uninitialized variable in skx_upi_topology_cb(). Fixes: 4cfce57fa42d ("perf/x86/intel/uncore: Enable UPI topology discovery for Skylake Server") Fixes: f680b6e6062e ("perf/x86/intel/uncore: Enable UPI topology discovery for Icelake Server") Signed-off-by: Zide Chen <zide.chen@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Dapeng Mi <dapeng1.mi@linux.intel.com> Link: https://patch.msgid.link/20260602144908.263680-4-zide.chen@intel.com
Diffstat (limited to 'drivers/platform/wmi/tests/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions