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]
Date: Wed, 26 Jun 2024 11:04:26 -0400
From: Frank Li <Frank.li@....com>
To: Krzysztof Kozlowski <krzk@...nel.org>
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Rob Herring <robh@...nel.org>,
	Krzysztof Kozlowski <krzk+dt@...nel.org>,
	Conor Dooley <conor+dt@...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>, imx@...ts.linux.dev
Subject: Re: [PATCH 1/1] dt-bindings: usb: Convert fsl-usb to yaml

On Wed, Jun 26, 2024 at 11:26:18AM +0200, Krzysztof Kozlowski wrote:
> On 25/06/2024 04:25, Frank Li wrote:
> > Convert fsl-usb binding doc to yaml format.
> > 
> > Additional change:
> 
> 
> > -	usb@...0 {
> > -		compatible = "fsl,mpc5121-usb2-dr";
> > -		reg = <0x4000 0x1000>;
> > -		#address-cells = <1>;
> > -		#size-cells = <0>;
> > -		interrupt-parent = < &ipic >;
> > -		interrupts = <44 0x8>;
> > -		dr_mode = "otg";
> > -		phy_type = "utmi_wide";
> > -		fsl,invert-drvvbus;
> > -		fsl,invert-pwr-fault;
> > -	};
> > diff --git a/Documentation/devicetree/bindings/usb/fsl-usb.yaml b/Documentation/devicetree/bindings/usb/fsl-usb.yaml
> > new file mode 100644
> > index 0000000000000..8b5724e213f09
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/usb/fsl-usb.yaml
> 
> fsl,usb.yaml
> or: fsl,usb2.yaml
> 
> > +
> > +maintainers:
> > +  - Frank Li <Frank.Li@....com>
> > +
> > +description: |
> 
> Do not need '|' unless you need to preserve formatting.

dt_binding_check report error without '|'
fsl,usb2.yaml:15:11: [error] syntax error: mapping values are not allowed here (syntax)

"Practice:" impact yaml parse.

> 
> > +  The device node for a USB controller that is part of a Freescale
> > +  SOC is as described in the document "Open Firmware Recommended
> > +  Practice: Universal Serial Bus" with the following modifications
> > +  and additions.
> > +
> > +properties:
> > +  compatible:
> > +    oneOf:
> > +      - enum:
> > +          - fsl-usb2-mph
> > +          - fsl-usb2-dr
> > +          - fsl-usb2-dr-v2.2
> 
> It cannot be standalone and not-standalone. Cannot be both. Choose one.
> 
> > +      - items:
> > +          - enum:
> > +              - fsl-usb2-dr-v2.2
> > +              - fsl-usb2-dr-v2.5
> > +          - const: fsl-usb2-dr
> > +
> > +  phy_type:
> > +    $ref: /schemas/types.yaml#/definitions/string
> > +    enum: [ulpi, serial, utmi, utmi_wide]
> > +
> > +  reg:
> > +    maxItems: 1
> > +
> > +  interrupts:
> > +    maxItems: 1
> > +
> > +  port0:
> > +    $ref: /schemas/types.yaml#/definitions/flag
> > +    description:
> > +      Indicates port0 is connected for fsl-usb2-mph compatible controllers.
> > +
> > +  port1:
> > +    $ref: /schemas/types.yaml#/definitions/flag
> > +    description:
> > +      Indicates port1 is connected for "fsl-usb2-mph" compatible controllers.
> > +
> > +  fsl,invert-drvvbus:
> > +    $ref: /schemas/types.yaml#/definitions/flag
> > +    description:
> > +      for MPC5121 USB0 only. Indicates the
> > +      port power polarity of internal PHY signal DRVVBUS is inverted.
> > +
> > +  fsl,invert-pwr-fault:
> > +    $ref: /schemas/types.yaml#/definitions/flag
> > +    description:
> > +      for MPC5121 USB0 only. Indicates
> > +      the PWR_FAULT signal polarity is inverted.
> > +
> > +required:
> > +  - compatible
> > +  - reg
> > +  - interrupts
> > +  - phy_type
> 
> Keep the same order as in "properties:". Preferably this order, so
> adjust "properties:" to match "required:".
> 
> > +
> > +allOf:
> > +  - $ref: usb-drd.yaml#
> > +
> 
> 
> Best regards,
> Krzysztof
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ