linux/drivers/usb/musb
Guangshuo Li c947360ae6 usb: musb: omap2430: Do not put borrowed of_node in probe
omap2430_probe() stores pdev->dev.of_node in a local np variable. This is
a borrowed pointer and the probe function does not take a reference to
it.

The success and error paths nevertheless call of_node_put(np). This drops
a reference that is owned by the platform device, and can leave
pdev->dev.of_node with an unbalanced reference count.

Do not put the borrowed platform device node from omap2430_probe().
References taken for the child MUSB device are handled by the device core,
and the ctrl-module phandle reference is still released separately.

Fixes: ffbe2feac5 ("usb: musb: omap2430: Fix probe regression for missing resources")
Cc: stable <stable@kernel.org>
Reviewed-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Guangshuo Li <lgs201920130244@gmail.com>
Link: https://patch.msgid.link/20260713114711.955253-1-lgs201920130244@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2026-07-16 17:11:35 +02:00
..
cppi_dma.h usb: musb: Remove unused function declarations 2023-08-08 10:36:43 +02:00
da8xx.c treewide, timers: Rename from_timer() to timer_container_of() 2025-06-08 09:07:37 +02:00
jz4740.c usb: musb: Constify struct musb_fifo_cfg 2025-02-03 16:29:53 +01:00
Kconfig usb: musb: omap2430: enable compile testing 2025-07-25 10:50:39 +02:00
Makefile usb: musb: Drop old unused am35x glue layer 2022-11-29 08:56:09 +01:00
mediatek.c usb: musb: Constify struct musb_fifo_cfg 2025-02-03 16:29:53 +01:00
mpfs.c treewide, timers: Rename from_timer() to timer_container_of() 2025-06-08 09:07:37 +02:00
musb_core.c usb: musb: Use safer strscpy() instead of strcpy() 2026-03-11 15:39:04 +01:00
musb_core.h ARM/musb: omap2: Remove global GPIO numbers from TUSB6010 2023-05-24 15:01:59 +02:00
musb_cppi41.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
musb_debug.h USB: musb: Use the correct style for SPDX License Identifier 2020-04-16 14:32:47 +02:00
musb_debugfs.c usb: Remove redundant pm_runtime_mark_last_busy() calls 2025-11-21 15:11:53 +01:00
musb_dma.h usb: musb: Remove unused function declarations 2023-08-08 10:36:43 +02:00
musb_dsps.c usb: Remove redundant pm_runtime_mark_last_busy() calls 2025-11-21 15:11:53 +01:00
musb_gadget_ep0.c drivers/usb/musb: refactor min/max with min_t/max_t 2024-11-13 15:09:51 +01:00
musb_gadget.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
musb_gadget.h USB: musb: Use the correct style for SPDX License Identifier 2020-04-16 14:32:47 +02:00
musb_host.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
musb_host.h usb: musb: Remove duplicate declaration of functions 2021-05-10 16:20:41 +02:00
musb_io.h USB: musb: Use the correct style for SPDX License Identifier 2020-04-16 14:32:47 +02:00
musb_regs.h USB: musb: Use the correct style for SPDX License Identifier 2020-04-16 14:32:47 +02:00
musb_trace.c USB: musb: Remove redundant license text 2017-11-07 15:45:01 +01:00
musb_trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00
musb_virthub.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
musbhsdma.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
omap2430.c usb: musb: omap2430: Do not put borrowed of_node in probe 2026-07-16 17:11:35 +02:00
omap2430.h USB: musb: Use the correct style for SPDX License Identifier 2020-04-16 14:32:47 +02:00
sunxi.c usb: musb: Constify struct musb_fifo_cfg 2025-02-03 16:29:53 +01:00
tusb6010_omap.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
tusb6010.c treewide, timers: Rename from_timer() to timer_container_of() 2025-06-08 09:07:37 +02:00
tusb6010.h USB: musb: Use the correct style for SPDX License Identifier 2020-04-16 14:32:47 +02:00
ux500_dma.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
ux500.c usb: Switch back to struct platform_driver::remove() 2024-10-04 15:13:03 +02:00