[LEDE-DEV] [PATCH 3/3] lantiq: add device tree binding for dwc2 on danube

Martin Blumenstingl martin.blumenstingl at googlemail.com
Sun Oct 30 04:03:02 PDT 2016


On Sun, Oct 30, 2016 at 11:46 AM, Antti Seppälä <a.seppala at gmail.com> wrote:
> On 29 October 2016 at 00:22, Ben Mulvihill <ben.mulvihill at gmail.com> wrote:
>> On Fri, 2016-10-28 at 18:28 +0200, Christian Lamparter wrote:
>>> Hello,
>>>
>>> On Friday, October 28, 2016 4:30:56 PM CEST Ben Mulvihill wrote:
>>> > Add device tree binding for dwc2 usb driver on lantiq danube
>>> >
>>> > Signed-off-by: Ben Mulvihill <ben.mulvihill at gmail.com>
>>> > ---
>>> > diff -uprN a/target/linux/lantiq/dts/danube.dtsi b/target/linux/lantiq/dts/danube.dtsi
>>> > --- a/target/linux/lantiq/dts/danube.dtsi   2016-10-27 19:56:07.090392399 +0200
>>> > +++ b/target/linux/lantiq/dts/danube.dtsi   2016-10-27 20:47:34.387511522 +0200
>>> > @@ -140,7 +140,7 @@
>>> >             };
>>> >
>>> >             ifxhcd at E101000 {
>>> > -                   compatible = "lantiq,ifxhcd-danube";
>>> > +                   compatible = "lantiq,ifxhcd-danube", "lantiq,ifxhcd-danube-dwc2";
>>> Usually for device tree, the first compatible string is reserved for the
>>> "exact device" that the node represents [0]. So wouldn't switching around
>>> the strings (i.e.: "lantiq,ifxhcd-danube-dwc2", "lantiq,ifxhcd-danube")
>>> make more sense? After all, the dwc2 is the "more exact device" in this case?
>>>
>>
>> Thanks for reviewing.
>>
>> Are they not equally "exact"? They are two alternative, and completely
>> separate, drivers. (The names chosen for the bindings are perhaps a
>> little misleading in that regard.) I Left "lantiq,ifxhcd-danube" in
>> first position simply because it has been the default driver until
>> now, and I didn't want to change the default at this stage. Not that
>> it will make any difference to which driver is actually used unless
>> for some strange reason someone decides to include both drivers in
>> the same build.
>>
>> Once we're sure that dwc2 works properly on danube, the old
>> ifxhcd-danube driver can be ditched from the source tree completely.
>> But I thought it was better to get an ack from John on
>> these first.
>>
>
> What do you guys think, should we switch the naming to follow what is
> currently in upstream kernel before adding new names? Or rather do
> that when we switch to a newer kernel where the device support is
> included?
this probably depends on "when" you want to do this.
The dwc2 maintainers are trying to get rid of these platform specific code:
"The long-term goal is to remove all static and legacy parameters in
favor of devicetree properties." - see [0]


[0] https://www.spinics.net/lists/linux-usb/msg147969.html



More information about the Lede-dev mailing list