patch "usb: typec: intel_pmc_mux: Put fwnode in error case during ->probe()" added to usb-linus
Subsystems (4)
This is a note to let you know that I've just added the patch titled
usb: typec: intel_pmc_mux: Put fwnode in error case during ->probe()
to my usb git tree which can be found at
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git
in the usb-linus branch.
The patch will show up in the next release of the linux-next tree (usually sometime within the next 24 hours during the week.)
The patch will hopefully also be merged in Linus's tree for the next -rc kernel release.
If you have any questions about this process, please let me know.
From 1a85b350a7741776a406005b943e3dec02c424ed Mon Sep 17 00:00:00 2001
From: Andy Shevchenko <[email protected]>
Date: Mon, 7 Jun 2021 23:50:05 +0300
Subject: usb: typec: intel_pmc_mux: Put fwnode in error case during ->probe()
device_get_next_child_node() bumps a reference counting of a returned variable. We have to balance it whenever we return to the caller.
--- drivers/usb/typec/mux/intel_pmc_mux.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/usb/typec/mux/intel_pmc_mux.c +3 -1
@@ -636,8 +636,10 @@ static int pmc_usb_probe(struct platform_device *pdev)break ; ret =pmc_usb_register_port (pmc, i, fwnode); -if (ret) +if (ret) { +fwnode_handle_put (fwnode); goto err_remove_ports; + } }platform_set_drvdata (pdev, pmc);
Signature · 1 line
2.32.0