diff options
| author | Haotian Zhang <vulab@iscas.ac.cn> | 2026-02-20 00:38:43 +0800 |
|---|---|---|
| committer | Vinod Koul <vkoul@kernel.org> | 2026-09-15 11:55:54 +0530 |
| commit | 1499f3d3407f5310731bcdf324387c321258fd75 (patch) | |
| tree | 457e9a6bbce8e0432a59a05b4ba426b246434c3d /tools/perf/scripts/python | |
| parent | 858635d217cde25ba3bc4e8addfe36ada7584a41 (diff) | |
| download | linux-next-1499f3d3407f5310731bcdf324387c321258fd75.tar.gz linux-next-1499f3d3407f5310731bcdf324387c321258fd75.zip | |
phy: hisilicon: hi3670: Fix OF node and device reference leaks
hi3670_pcie_get_resources_from_pcie() leaks two references:
1) The OF node returned by of_get_child_by_name() is never released.
2) The device returned by bus_find_device_by_of_node() is never put.
Fix both leaks by calling of_node_put() right after
bus_find_device_by_of_node(), and put_device() after dev_get_regmap()
when the temporary pcie_dev reference is no longer needed.
Fixes: 73075011ffff ("phy: HiSilicon: Add driver for Kirin 970 PCIe PHY")
Suggested-by: Vladimir Oltean <olteanv@gmail.com>
Signed-off-by: Haotian Zhang <vulab@iscas.ac.cn>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
Link: https://patch.msgid.link/20260219163843.1571-1-vulab@iscas.ac.cn
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
