aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorFeilong Lin <[email protected]>2021-03-25 15:26:00 +0800
committerBjorn Helgaas <[email protected]>2021-04-08 11:04:18 -0500
commit3bbfd319034ddce59e023837a4aa11439460509b (patch)
tree03af689dc7b579d5c2b234e5ff88e5faccbea4f7 /tools/perf/scripts/python/export-to-postgresql.py
parenta38fd8748464831584a19438cbb3082b5a2dab15 (diff)
ACPI / hotplug / PCI: Fix reference count leak in enable_slot()
In enable_slot(), if pci_get_slot() returns NULL, we clear the SLOT_ENABLED flag. When pci_get_slot() finds a device, it increments the device's reference count. In this case, we did not call pci_dev_put() to decrement the reference count, so the memory of the device (struct pci_dev type) will eventually leak. Call pci_dev_put() to decrement its reference count when pci_get_slot() returns a PCI device. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Feilong Lin <[email protected]> Signed-off-by: Zhiqiang Liu <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Reviewed-by: Rafael J. Wysocki <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions