Commit def435c0 authored by Liang He's avatar Liang He Committed by Michael Ellerman

powerpc/sysdev/fsl_msi: Add missing of_node_put()

In fsl_setup_msi_irqs(), use of_node_put() to drop the reference
returned by of_parse_phandle().

Fixes: 895d603f ("powerpc/fsl_msi: add support for the fsl, msi property in PCI nodes")
Co-authored-by: default avatarMiaoqian Lin <linmq006@gmail.com>
Signed-off-by: default avatarLiang He <windhl@126.com>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220704145233.278539-1-windhl@126.com
parent 3d31adc4
...@@ -209,8 +209,10 @@ static int fsl_setup_msi_irqs(struct pci_dev *pdev, int nvec, int type) ...@@ -209,8 +209,10 @@ static int fsl_setup_msi_irqs(struct pci_dev *pdev, int nvec, int type)
dev_err(&pdev->dev, dev_err(&pdev->dev,
"node %pOF has an invalid fsl,msi phandle %u\n", "node %pOF has an invalid fsl,msi phandle %u\n",
hose->dn, np->phandle); hose->dn, np->phandle);
of_node_put(np);
return -EINVAL; return -EINVAL;
} }
of_node_put(np);
} }
msi_for_each_desc(entry, &pdev->dev, MSI_DESC_NOTASSOCIATED) { msi_for_each_desc(entry, &pdev->dev, MSI_DESC_NOTASSOCIATED) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment