summaryrefslogtreecommitdiff
path: root/drivers/usb/musb/mediatek.c
diff options
context:
space:
mode:
authorRob Herring <robh@kernel.org>2021-12-16 02:07:57 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-12-17 19:00:45 +0300
commitcf081d009c447647c6b36aced535ca427dbebe72 (patch)
treead0fcdad298f2d09c206316a733b31ad05fa649c /drivers/usb/musb/mediatek.c
parent9879c81b680795b45a11894e48dfa9e4be2f4426 (diff)
downloadlinux-cf081d009c447647c6b36aced535ca427dbebe72.tar.xz
usb: musb: Set the DT node on the child device
The musb glue drivers just copy the glue resources to the musb child device. Instead, set the musb child device's DT node pointer to the parent device's node so that platform_get_irq_byname() can find the resources in the DT. This removes the need for statically populating the IRQ resources from the DT which has been deprecated for some time. Signed-off-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20211215230756.2009115-3-robh@kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/musb/mediatek.c')
-rw-r--r--drivers/usb/musb/mediatek.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/musb/mediatek.c b/drivers/usb/musb/mediatek.c
index f5d97eb84cb5..1aeb34dbe24f 100644
--- a/drivers/usb/musb/mediatek.c
+++ b/drivers/usb/musb/mediatek.c
@@ -538,6 +538,8 @@ static int mtk_musb_probe(struct platform_device *pdev)
pinfo.num_res = pdev->num_resources;
pinfo.data = pdata;
pinfo.size_data = sizeof(*pdata);
+ pinfo.fwnode = of_fwnode_handle(np);
+ pinfo.of_node_reused = true;
glue->musb_pdev = platform_device_register_full(&pinfo);
if (IS_ERR(glue->musb_pdev)) {