[PATCH v2 3/6] usb: musb-new: Update phandle handling
Simon Glass
sjg at chromium.org
Sat Jun 6 00:07:09 CEST 2026
On 2026-06-02T11:21:39, Peng Fan (OSS) <peng.fan at oss.nxp.com> wrote:
> usb: musb-new: Update phandle handling
>
> Replace ofnode_get_by_phandle(dev_read_u32_default()) with
> ofnode_parse_phandle() for resolving the 'phys' and 'ti,ctrl_mod'
> phandle references in ti_musb_of_to_plat().
>
> ofnode_parse_phandle() handles the phandle lookup in a single call and
> works with both live and flat device trees. Add ofnode_valid() checks
> after each resolution so the driver returns -EINVAL early instead of
> operating on invalid nodes.
>
> Signed-off-by: Peng Fan <peng.fan at nxp.com>
>
> drivers/usb/musb-new/ti-musb.c | 10 ++++++++--
> 1 file changed, 8 insertions(+), 2 deletions(-)
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list