PCI: xilinx-cpm: Fix reference count leak on error path
Subsystems (4)
PATCH 1/1 PCI: xilinx-cpm: Fix reference count leak on error path
Also drop the reference count of the node on error path.
Fixes 508f610648b9 ("PCI: xilinx-cpm: Add Versal CPM Root Port driver")
Signed-off-by Pan Bian <[email protected]>
--- drivers/pci/controller/pcie-xilinx-cpm.c | 1 + 1 file changed, 1 insertion(+)
drivers/pci/controller/pcie-xilinx-cpm.c +1 -0
@@ -404,6 +404,7 @@ static int xilinx_cpm_pcie_init_irq_domain(struct xilinx_cpm_pcie_port *port)return 0 ; out:xilinx_cpm_free_irq_domains (port); +of_node_put (pcie_intc_node);dev_err (dev,"Failed to allocate IRQ domains\n" );return -ENOMEM ;
Signature · 8 lines
2.17.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Lorenzo Pieralisi
AppliedQuoted 1 line · Pan Bian
Also drop the reference count of the node on error path.
Applied to pci/xilinx, thanks!
[1/1] PCI: xilinx-cpm: Fix reference count leak on error path
https://git.kernel.org/lpieralisi/pci/c/ae191d2e51
Thanks,
Lorenzo