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: <YbjFuQxL+Wp8tU6r@robh.at.kernel.org>
Date:   Tue, 14 Dec 2021 10:26:33 -0600
From:   Rob Herring <robh@...nel.org>
To:     Mark Brown <broonie@...nel.org>,
        Tinghan Shen <tinghan.shen@...iatek.com>
Cc:     linus.walleij@...aro.org, matthias.bgg@...il.com,
        bgolaszewski@...libre.com, sean.wang@...iatek.com,
        bayi.cheng@...iatek.com, gch981213@...il.com,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-gpio@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        linux-mediatek@...ts.infradead.org, linux-spi@...r.kernel.org,
        Project_Global_Chrome_Upstream_Group@...iatek.com
Subject: Re: [PATCH v6 2/4] dt-bindings: spi: add new clock name 'axi' for
 spi nor

On Mon, Dec 13, 2021 at 04:04:48PM +0000, Mark Brown wrote:
> On Sun, Dec 12, 2021 at 04:40:12AM +0800, Tinghan Shen wrote:
> 
> > Some mtk spi nor has dedicated dma(s) inside. Add a new clock name, axi,
> > for spi nor dma bus clock.
> 
> >    clock-names:
> > +    minItems: 2
> >      items:
> >        - const: spi
> >        - const: sf
> > +      - const: axi
> 
> This will cause any existing DTs that don't have both spi and sf clocks
> defined to fail to validate which doesn't seem great.

That was true before this. The default for 'minItems' is the number of 
entries in 'items' (this is not the default for json-schema, but default 
for DT bindings as that's the common case).

> Given that your
> commit message says this is only required for some SoCs shouldn't the
> minimum clocks requirement depend on which particular SoC/IP version is
> being used?  Not exactly sure how one specifies that in the YAML format.

With an if/then schema adding maxItems/minItems constraints (e.g. 
'maxItems: 2' for existing compatibles). There are many examples in the 
tree.

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ