linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: John Stultz <john.stultz@linaro.org>
To: Krzysztof Kozlowski <krzk@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Serge Semin <Sergey.Semin@baikalelectronics.ru>,
	Felipe Balbi <balbi@kernel.org>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Rob Herring <robh+dt@kernel.org>, Wei Xu <xuwei5@hisilicon.com>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
	<devicetree@vger.kernel.org>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	Serge Semin <fancer.lancer@gmail.com>,
	lkml <linux-kernel@vger.kernel.org>,
	YongQin Liu <yongqin.liu@linaro.org>,
	Amit Pundir <amit.pundir@linaro.org>,
	Todd Kjos <tkjos@google.com>
Subject: Re: [PATCH v2 16/18] arm64: dts: hi3660: Harmonize DWC USB3 DT nodes name
Date: Mon, 21 Dec 2020 12:24:11 -0800	[thread overview]
Message-ID: <CALAqxLWAFs+8VKKuMMg2gyfGXgQSjaWv9H5ayuohEK9m6OS3TA@mail.gmail.com> (raw)
In-Reply-To: <20201219110603.GA8061@kozik-lap>

On Sat, Dec 19, 2020 at 3:06 AM Krzysztof Kozlowski <krzk@kernel.org> wrote:
> On Fri, Dec 18, 2020 at 09:11:42PM -0800, John Stultz wrote:
> > On Wed, Nov 11, 2020 at 1:22 AM Serge Semin
> > <Sergey.Semin@baikalelectronics.ru> wrote:
> > >
> > > In accordance with the DWC USB3 bindings the corresponding node
> > > name is suppose to comply with the Generic USB HCD DT schema, which
> > > requires the USB nodes to have the name acceptable by the regexp:
> > > "^usb(@.*)?" . Make sure the "snps,dwc3"-compatible nodes are correctly
> > > named.
> > >
> > > Signed-off-by: Serge Semin <Sergey.Semin@baikalelectronics.ru>
> > > Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
> > > ---
> > >  arch/arm64/boot/dts/hisilicon/hi3660.dtsi | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi
> > > index d25aac5e0bf8..aea3800029b5 100644
> > > --- a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi
> > > +++ b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi
> > > @@ -1166,7 +1166,7 @@ usb_phy: usb-phy {
> > >                         };
> > >                 };
> > >
> > > -               dwc3: dwc3@ff100000 {
> > > +               dwc3: usb@ff100000 {
> > >                         compatible = "snps,dwc3";
> > >                         reg = <0x0 0xff100000 0x0 0x100000>;
> >
> >
> > Oof. So this patch is breaking the usb gadget functionality on HiKey960 w/ AOSP.
> >
> > In order to choose the right controller for gadget mode with AOSP, one
> > sets the "sys.usb.controller" property, which until now for HiKey960
> > has been "ff100000.dwc3".
> > After this patch, the controller isn't found and we would have to
> > change userland to use "ff100000.usb", which would then break booting
> > on older kernels (testing various LTS releases on AOSP is one of the
> > key uses of the HiKey960).
> >
> > So while I understand the desire to unify the schema, as HiKey960
> > really isn't likely to be used outside of AOSP, I wonder if reverting
> > this one change is in the best interest of not breaking existing
> > userland?
>
> The node names are not part of an ABI, are they? I expect only
> compatibles and properties to be stable. If user-space looks for
> something by name, it's a user-space's mistake.  Not mentioning that you
> also look for specific address... Imagine remapping of addresses with
> ranges (for whatever reason) - AOSP also would be broken? Addresses are
> definitely not an ABI.

Though that is how it's exported through sysfs.

In AOSP it is then used to setup the configfs gadget by writing that
value into /config/usb_gadget/g1/UDC.

Given there may be multiple controllers on a device, or even if its
just one and the dummy hcd driver is enabled, I'm not sure how folks
reference the "right" one without the node name?

I understand the fuzziness with sysfs ABI, and I get that having
consistent naming is important, but like the eth0 -> enp3s0 changes,
it seems like this is going to break things.

Greg? Is there some better way AOSP should be doing this?

thanks
-john

  reply	other threads:[~2020-12-21 20:25 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-11  9:15 [PATCH v2 00/18] dt-bindings: usb: Harmonize xHCI/EHCI/OHCI/DWC3 nodes name Serge Semin
2020-11-11  9:15 ` [PATCH v2 01/18] arm: dts: keystone: Correct DWC USB3 compatible string Serge Semin
2020-11-11  9:15 ` [PATCH v2 02/18] arm64: dts: amlogic: meson-g12: Set FL-adj property value Serge Semin
2020-11-11  9:15 ` [PATCH v2 03/18] arc: dts: Harmonize EHCI/OHCI DT nodes name Serge Semin
2020-11-11  9:15 ` [PATCH v2 04/18] arm: dts: hisi-x5hd2: " Serge Semin
2020-11-25  2:27   ` Wei Xu
2020-11-11  9:15 ` [PATCH v2 05/18] arm: dts: lpc18xx: " Serge Semin
2020-11-11  9:15 ` [PATCH v2 06/18] arm64: dts: hisi: " Serge Semin
2020-11-25  2:27   ` Wei Xu
2020-11-11  9:15 ` [PATCH v2 07/18] mips: dts: jz47x: " Serge Semin
2020-11-12 22:41   ` Thomas Bogendoerfer
2020-11-11  9:15 ` [PATCH v2 08/18] mips: dts: sead3: " Serge Semin
2020-11-12 22:41   ` Thomas Bogendoerfer
2020-11-11  9:15 ` [PATCH v2 09/18] mips: dts: ralink: mt7628a: " Serge Semin
2020-11-12 22:41   ` Thomas Bogendoerfer
2020-11-11  9:15 ` [PATCH v2 10/18] powerpc: dts: akebono: " Serge Semin
2020-11-11  9:15 ` [PATCH v2 11/18] arm64: dts: marvell: cp11x: Harmonize xHCI " Serge Semin
2020-11-30 14:23   ` Gregory CLEMENT
2020-11-11  9:15 ` [PATCH v2 12/18] arm: dts: marvell: armada-375: Harmonize DWC USB3 " Serge Semin
2020-11-30 14:22   ` Gregory CLEMENT
2020-11-11  9:15 ` [PATCH v2 13/18] arm: dts: keystone: " Serge Semin
2020-11-11  9:15 ` [PATCH v2 14/18] arm: dts: stih407-family: " Serge Semin
2020-11-11  9:15 ` [PATCH v2 15/18] arm64: dts: apm: " Serge Semin
2020-11-11  9:15 ` [PATCH v2 16/18] arm64: dts: hi3660: " Serge Semin
2020-11-25  2:23   ` Wei Xu
2020-12-19  5:11   ` John Stultz
2020-12-19 11:06     ` Krzysztof Kozlowski
2020-12-21 20:24       ` John Stultz [this message]
2020-12-21 21:04         ` Krzysztof Kozlowski
2020-11-11  9:15 ` [PATCH v2 17/18] usb: dwc3: qcom: Detect DWC3 DT-nodes with "usb"-prefixed names Serge Semin
2020-11-11 16:05   ` Bjorn Andersson
2020-11-11  9:15 ` [PATCH v2 18/18] arm64: dts: qcom: Harmonize DWC USB3 DT nodes name Serge Semin
2020-11-11 16:08   ` Bjorn Andersson
2020-11-12 18:43     ` Serge Semin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CALAqxLWAFs+8VKKuMMg2gyfGXgQSjaWv9H5ayuohEK9m6OS3TA@mail.gmail.com \
    --to=john.stultz@linaro.org \
    --cc=Sergey.Semin@baikalelectronics.ru \
    --cc=amit.pundir@linaro.org \
    --cc=balbi@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=f.fainelli@gmail.com \
    --cc=fancer.lancer@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=krzk@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=tkjos@google.com \
    --cc=xuwei5@hisilicon.com \
    --cc=yongqin.liu@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).