aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/cdns3/cdns3-pci-wrap.c
diff options
context:
space:
mode:
authorNishka Dasgupta <[email protected]>2019-08-19 07:24:36 +0000
committerFelipe Balbi <[email protected]>2019-08-28 10:04:58 +0000
commitbceb418b65b917af6d36a92ea1eaca54cafc1c2e (patch)
treecfc494b845255f516b5b01ebc7a9e29658090ae5 /drivers/usb/cdns3/cdns3-pci-wrap.c
parentusb: dwc3: st: Add of_node_put() before return in probe function (diff)
downloadkernel-bceb418b65b917af6d36a92ea1eaca54cafc1c2e.tar.gz
kernel-bceb418b65b917af6d36a92ea1eaca54cafc1c2e.zip
usb: dwc3: st: Add of_dev_put() in probe function
In function st_dwc3_probe, variable child_pdev takes the value returned by of_find_device_by_node, which gets a device pointer but does not put it. If child_pdev is not put before the probe function returns, it may cause a reference leak. Hence put child_pdev after its last usage. Issue found with Coccinelle. Reviewed-by: Patrice Chotard <[email protected]> Signed-off-by: Nishka Dasgupta <[email protected]> Signed-off-by: Felipe Balbi <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-pci-wrap.c')
0 files changed, 0 insertions, 0 deletions