lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20230103185201.GA3650723-robh@kernel.org>
Date:   Tue, 3 Jan 2023 12:52:01 -0600
From:   Rob Herring <robh@...nel.org>
To:     Jung Daehwan <dh10.jung@...sung.com>
Cc:     Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Thinh Nguyen <Thinh.Nguyen@...opsys.com>,
        Mathias Nyman <mathias.nyman@...el.com>,
        Felipe Balbi <balbi@...nel.org>,
        "open list:USB SUBSYSTEM" <linux-usb@...r.kernel.org>,
        "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
        <devicetree@...r.kernel.org>,
        open list <linux-kernel@...r.kernel.org>, sc.suh@...sung.com,
        taehyun.cho@...sung.com, jh0801.jung@...sung.com,
        eomji.oh@...sung.com
Subject: Re: [RFC PATCH v2 3/3] dt-bindings: usb: snps,dwc3: add generic-xhci
 as child

On Mon, Jan 02, 2023 at 02:45:17PM +0900, Jung Daehwan wrote:
> On Thu, Dec 29, 2022 at 11:23:02AM +0100, Krzysztof Kozlowski wrote:
> > On 29/12/2022 10:57, Daehwan Jung wrote:
> > > Currently, dwc3 invokes just xhci platform driver(generic-xhci) without
> > > DT schema even though xhci works as child of dwc3. It makes sense to add
> > > xhci as child of dwc3 with DT schema. It also supports to use another
> > > compatible in xhci platform driver.
> > 
> > You use some driver as an argument for hardware description, which is
> > not what we need. Describe the hardware.
> > 
> 
> OK. I will it on next submission.
> 
> > > 
> > > Signed-off-by: Daehwan Jung <dh10.jung@...sung.com>
> > > ---
> > >  .../devicetree/bindings/usb/snps,dwc3.yaml    | 29 +++++++++++++++++++
> > >  1 file changed, 29 insertions(+)
> > > 
> > > diff --git a/Documentation/devicetree/bindings/usb/snps,dwc3.yaml b/Documentation/devicetree/bindings/usb/snps,dwc3.yaml
> > > index 6d78048c4613..83ed7c526dba 100644
> > > --- a/Documentation/devicetree/bindings/usb/snps,dwc3.yaml
> > > +++ b/Documentation/devicetree/bindings/usb/snps,dwc3.yaml
> > > @@ -360,8 +360,22 @@ properties:
> > >      description:
> > >        Enable USB remote wakeup.
> > >  
> > > +  "#address-cells":
> > > +    enum: [ 1, 2 ]
> > > +
> > > +  "#size-cells":
> > > +    enum: [ 1, 2 ]
> > > +
> > > +  ranges: true
> > > +
> > >  unevaluatedProperties: false
> > >  
> > > +# Required child node:
> > > +patternProperties:
> > > +  "^usb@[0-9a-f]+$":
> > > +    $ref: generic-xhci.yaml#
> > > +    description: Required child node
> > 
> > DWC does not have another piece of controller as child... DWC is the
> > controller. Not mentioning that you now affect several other devices
> > without describing the total hardware picture (just some drivers which
> > is not that relevant).
> > 
> 
> DWC controller supports USB Host mode and it uses same resource and
> really works as a child. I guess it's same on many SOCs, especially
> mobile..

Yes, and we already support all those platforms just fine without this 
child node. Adding it means we have to then support *both* ways in the 
driver.


> I just want to modify it to work with DT schema (dwc3 -> xhci-plat).
> I think it needs to dicuss more..

Why doesn't it work with the schema?

It's convenient when DT nodes == device drivers, but hardware is messy 
sometimes. Linux (and other OSs) have to deal with that. We can't write 
the DT to reflect the current (and evolving) needs of a particular OS. 

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ