[PATCH v3 0/2] usb: musb: da8xx: pair OF child population
From: Pengpeng Hou
Date: Thu Aug 13 2026 - 11:37:29 EST
da8xx_probe() publishes CPPI child devices with of_platform_populate().
Those children are owned by the DA8xx parent and are not removed by
unregistering the separately created MUSB platform device.
The two patches intentionally cover separate lifetime exits. Patch 1
unwinds partially or fully populated children when probe later fails.
Patch 2 pairs a successful population during normal driver removal. In
both paths, resources are unpublished in the reverse order in which the
driver made them visible.
Changes since v2:
https://lore.kernel.org/all/20260715135916.24417-4-pengpeng@xxxxxxxxxxx/
- split probe-failure cleanup from normal remove cleanup
- document ownership of OF-created children versus the MUSB device
- cover partial failure from of_platform_populate()
- preserve reverse publication order on every exit
The series was reviewed statically against the current tree. I do not
have DA8xx hardware for bind/unbind testing.
Pengpeng Hou (2):
usb: musb: da8xx: depopulate OF children on probe failure
usb: musb: da8xx: depopulate OF children on remove
drivers/usb/musb/da8xx.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
base-commit: f5bbbfec59b4e2fb7520a91de3df8a6174325d6a
--
2.50.1 (Apple Git-155)