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: <DU0PR04MB9417EDBB2ACDC761D6D6C31488AC9@DU0PR04MB9417.eurprd04.prod.outlook.com>
Date:   Tue, 28 Feb 2023 05:55:40 +0000
From:   Peng Fan <peng.fan@....com>
To:     Rob Herring <robh@...nel.org>,
        "Peng Fan (OSS)" <peng.fan@....nxp.com>
CC:     "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
        "krzysztof.kozlowski+dt@...aro.org" 
        <krzysztof.kozlowski+dt@...aro.org>,
        "shawnguo@...nel.org" <shawnguo@...nel.org>,
        "s.hauer@...gutronix.de" <s.hauer@...gutronix.de>,
        Xu Yang <xu.yang_2@....com>,
        "kernel@...gutronix.de" <kernel@...gutronix.de>,
        "festevam@...il.com" <festevam@...il.com>,
        dl-linux-imx <linux-imx@....com>,
        "linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>, Jun Li <jun.li@....com>
Subject: RE: [PATCH V3 1/7] dt-bindings: usb: usbmisc-imx: convert to DT
 schema

> Subject: Re: [PATCH V3 1/7] dt-bindings: usb: usbmisc-imx: convert to DT
> schema
> 
> On Sun, Feb 26, 2023 at 09:05:33PM +0800, Peng Fan (OSS) wrote:
> > From: Peng Fan <peng.fan@....com>
> >
> > Convert usbmisc-imx to DT schema format.
> >
> > Signed-off-by: Peng Fan <peng.fan@....com>
> > ---
> >  .../devicetree/bindings/usb/fsl,usbmisc.yaml  | 54 +++++++++++++++++++
> >  .../devicetree/bindings/usb/usbmisc-imx.txt   | 19 -------
> >  2 files changed, 54 insertions(+), 19 deletions(-)  create mode
> > 100644 Documentation/devicetree/bindings/usb/fsl,usbmisc.yaml
> >  delete mode 100644
> > Documentation/devicetree/bindings/usb/usbmisc-imx.txt
> >
> > diff --git a/Documentation/devicetree/bindings/usb/fsl,usbmisc.yaml
> > b/Documentation/devicetree/bindings/usb/fsl,usbmisc.yaml
> > new file mode 100644
> > index 000000000000..517390b9d2c6
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/usb/fsl,usbmisc.yaml
> > @@ -0,0 +1,54 @@
> > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) %YAML 1.2
> > +---
> > +$id:
> >
> +https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fdevi
> >
> +cetree.org%2Fschemas%2Fusb%2Ffsl%2Cusbmisc.yaml%23&data=05%7C0
> 1%7Cpen
> >
> +g.fan%40nxp.com%7C688a52ac42294bd0a9e208db19048b8c%7C686ea1d3
> bc2b4c6f
> >
> +a92cd99c5c301635%7C0%7C0%7C638131279545141829%7CUnknown%7CT
> WFpbGZsb3d
> >
> +8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0
> %3D%7
> >
> +C3000%7C%7C%7C&sdata=4V5Lpsj6g0mJqJyGZTVoFeas%2B1IvTEW0ERe3y
> 9vjsxE%3D
> > +&reserved=0
> > +$schema:
> >
> +https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fdevi
> > +cetree.org%2Fmeta-
> schemas%2Fcore.yaml%23&data=05%7C01%7Cpeng.fan%40nx
> >
> +p.com%7C688a52ac42294bd0a9e208db19048b8c%7C686ea1d3bc2b4c6fa9
> 2cd99c5c
> >
> +301635%7C0%7C0%7C638131279545141829%7CUnknown%7CTWFpbGZsb
> 3d8eyJWIjoiM
> >
> +C4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C300
> 0%7C%7
> >
> +C%7C&sdata=PVGWk1%2B9YP1vixM%2BiB4XDH0UKWTTM%2FOiA5aZiPcn
> 6Qk%3D&reser
> > +ved=0
> > +
> > +title: Freescale i.MX wrapper module for Chipidea USB2 controller
> > +
> > +maintainers:
> > +  - Xu Yang <xu.yang_2@....com>
> > +  - Peng Fan <peng.fan@....com>
> > +
> > +properties:
> > +  compatible:
> > +    oneOf:
> > +      - enum:
> > +          - fsl,imx6q-usbmisc
> > +          - fsl,imx7ulp-usbmisc
> > +          - fsl,vf610-usbmisc
> > +      - items:
> > +          - enum:
> > +              - fsl,imx6ul-usbmisc
> > +              - fsl,imx6sx-usbmisc
> > +              - fsl,imx7d-usbmisc
> > +          - const: fsl,imx6q-usbmisc
> > +      - items:
> > +          - enum:
> > +              - fsl,imx7ulp-usbmisc
> > +              - fsl,imx8mm-usbmisc
> > +          - const: fsl,imx7d-usbmisc
> 
> So imx8mm is compatible with imx7d, and imx7d is compatible with imx6q,
> but imx8mm is not compatible with imx6q? That doesn't really make sense.
> Maybe all 3 compatibles makes sense, but only if s/w understanding only
> one of the fallback compatibles would function without knowledge of the
> newer h/w.

I added the list according the current device tree in use. If using
three compatibles,  that would involve device tree upate, and firmware
update for SR-IR.

My understanding is imx8mm is compatible with imx7d, imx7d is compatible
with imx6q, then imx8mm is compatible with imx6q. it is just not put
them under one item. Please correct if my understanding is wrong.
> 
> > +
> > +  reg:
> > +    maxItems: 1
> > +
> > +  '#index-cells':
> > +    const: 1
> > +    description: Cells used to describe usb controller index.
> 
> Please mark this as deprecated. If it is always 1 cell, then there's no point.

Fix in v4.
> 
> > +
> > +required:
> > +  - compatible
> > +  - reg
> > +  - '#index-cells'
> 
> And drop as required. That all can be a follow-up patch if you prefer or in
> this patch is fine. Primarily, I don't want this pattern copied.
> 

Fix in v4.

Thanks,
Peng.
> > +
> > +additionalProperties: false
> > +
> > +examples:
> > +  - |
> > +    usbmisc@...4800 {
> > +        #index-cells = <1>;
> > +        compatible = "fsl,imx6q-usbmisc";
> > +        reg = <0x02184800 0x200>;
> > +    };
> > +
> > +...
> > diff --git a/Documentation/devicetree/bindings/usb/usbmisc-imx.txt
> > b/Documentation/devicetree/bindings/usb/usbmisc-imx.txt
> > deleted file mode 100644
> > index 29b8f65ff849..000000000000
> > --- a/Documentation/devicetree/bindings/usb/usbmisc-imx.txt
> > +++ /dev/null
> > @@ -1,19 +0,0 @@
> > -* Freescale i.MX non-core registers
> > -
> > -Required properties:
> > -- #index-cells: Cells used to describe usb controller index. Should
> > be <1>
> > -- compatible: Should be one of below:
> > -	"fsl,imx6q-usbmisc" for imx6q
> > -	"fsl,vf610-usbmisc" for Vybrid vf610
> > -	"fsl,imx6sx-usbmisc" for imx6sx
> > -	"fsl,imx7d-usbmisc" for imx7d
> > -	"fsl,imx7ulp-usbmisc" for imx7ulp
> > -	"fsl,imx8mm-usbmisc" for imx8mm
> > -- reg: Should contain registers location and length
> > -
> > -Examples:
> > -usbmisc@...4800 {
> > -	#index-cells = <1>;
> > -	compatible = "fsl,imx6q-usbmisc";
> > -	reg = <0x02184800 0x200>;
> > -};
> > --
> > 2.37.1
> >

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ