From mboxrd@z Thu Jan 1 00:00:00 1970 From: hdegoede@redhat.com (Hans de Goede) Date: Mon, 14 Sep 2015 19:56:55 +0200 Subject: [linux-sunxi] [PATCH] musb: sunxi: Ignore VBus errors in host-only mode In-Reply-To: References: <1438723553-4136-1-git-send-email-hdegoede@redhat.com> <55C31963.2010701@schinagl.nl> <55C3709C.4080609@redhat.com> <55C47041.3000603@schinagl.nl> <55E93D8C.9020804@schinagl.nl> <55F1CA9B.3070204@redhat.com> <20150910183017.GN9885@lukather> <55F1CE2E.7010409@redhat.com> <55F6E0CA.2010004@redhat.com> <55F6FF28.80109@redhat.com> <55F702EE.5070903@redhat.com> Message-ID: <55F70A67.3020502@redhat.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi, On 14-09-15 19:53, Bin Liu wrote: >>> This is my first time looking at dts handling in drivers, so I might >>> be completely wrong, but I am thinking that since the controller node >>> links to the phy node, so the controller node is the parent of the phy >>> node, so if there is an of api can look it up? >> >> >> If the phy is a child of the controller, then yes this would work, >> but in the case of sunxi the phy is a built-in mmio mapped peripheral >> just like the controller, so they sit at the same level and have no >> parent child relation. > > musb_dsps dts is the same. > > sun8i-a33.dtsi: > > soc { > usb_otg: { > phys = <&usbphy 0>; > } > usbphy: { > } > } > > As in the example above, usb_otg node refers to usbphy node, so I am > wondering if there is an of api to look up the usb_otg properties in > the usbphy driver. That would boil down to hardcoding the node name / path compatible which is not acceptable from a devicetree pov. Really having to duplicate the dr_mode is not that bad / such big a deal. Regards, Hans