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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAGZ6i=1FPUaN4Ji4T3t3-_g2KHEngCcZ0rLR9AyG5RBpv5OCeA@mail.gmail.com>
Date:   Mon, 11 Dec 2023 10:49:35 +0800
From:   Kyle Tso <kyletso@...gle.com>
To:     Rob Herring <robh@...nel.org>
Cc:     krzysztof.kozlowski+dt@...aro.org, conor+dt@...nel.org,
        linux@...ck-us.net, heikki.krogerus@...ux.intel.com,
        gregkh@...uxfoundation.org, badhri@...gle.com,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-usb@...r.kernel.org
Subject: Re: [PATCH v5 1/2] dt-bindings: connector: Add child nodes for
 multiple PD capabilities

On Sat, Dec 9, 2023 at 12:50 AM Rob Herring <robh@...nel.org> wrote:
>
> On Tue, Dec 05, 2023 at 11:01:13AM +0800, Kyle Tso wrote:
> > Commit 662a60102c12 ("usb: typec: Separate USB Power Delivery from USB
> > Type-C") allows userspace to configure the PD of a port by selecting
> > different set of predefined PD capabilities. Define the PD capability
> > sets in DT for better configurability in device modules.
> >
> > Define an optional child node "capabilities" to contain multiple USB
> > Power Delivery capabilities.
> >
> > Define child nodes with pattern (e.g. caps-0, caps-1) under
> > "capabilities". Each node contains PDO data of a selectable Power
> > Delivery capability.
> >
> > Also define common properties for source-pdos, sink-pdos, and
> > op-sink-microwatt that can be referenced.
> >
> > Signed-off-by: Kyle Tso <kyletso@...gle.com>
> > ---
> > v4 -> v5:
> > - Fixed DT_CHECK errors
> >
> >  .../bindings/connector/usb-connector.yaml     | 88 +++++++++++++------
> >  1 file changed, 59 insertions(+), 29 deletions(-)
> >
> > diff --git a/Documentation/devicetree/bindings/connector/usb-connector.yaml b/Documentation/devicetree/bindings/connector/usb-connector.yaml
> > index 7c8a3e8430d3..7945d09d1f59 100644
> > --- a/Documentation/devicetree/bindings/connector/usb-connector.yaml
> > +++ b/Documentation/devicetree/bindings/connector/usb-connector.yaml
> > @@ -14,6 +14,8 @@ description:
> >    of a USB interface controller or a separate node when it is attached to both
> >    MUX and USB interface controller.
> >
> > +$ref: "#/$defs/capabilities"
> > +
> >  properties:
> >    compatible:
> >      oneOf:
> > @@ -67,6 +69,15 @@ properties:
> >        model it as a regulator. See bindings/regulator/fixed-regulator.yaml
> >
> >    # The following are optional properties for "usb-c-connector".
> > +  source-pdos:
> > +    $ref: "#/$defs/capabilities/properties/source-pdos"
> > +
> > +  sink-pdos:
> > +    $ref: "#/$defs/capabilities/properties/sink-pdos"
> > +
> > +  op-sink-microwatt:
> > +    $ref: "#/$defs/capabilities/properties/op-sink-microwatt"
>
> With the $ref above, these aren't needed. But you have to use
> unevaluatedProperties instead of additionalProperties.
>
> I fixed this up and applied.
>
> Rob

Thank you, Rob!

--
Kyle

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ