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: <20240611202311.GB3003237-robh@kernel.org>
Date: Tue, 11 Jun 2024 14:23:11 -0600
From: Rob Herring <robh@...nel.org>
To: Frank Li <Frank.Li@....com>
Cc: Ulf Hansson <ulf.hansson@...aro.org>,
	Krzysztof Kozlowski <krzk+dt@...nel.org>,
	Conor Dooley <conor+dt@...nel.org>, Shawn Guo <shawnguo@...nel.org>,
	linux-mmc@...r.kernel.org, devicetree@...r.kernel.org,
	linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
	imx@...ts.linux.dev
Subject: Re: [PATCH v4 2/8] dt-bindings: mmc: mmc-spi-slot: Change
 voltage-ranges to uint32-matrix

On Tue, Jun 11, 2024 at 12:01:47PM -0400, Frank Li wrote:
> According to common mmc core, voltages-ranges should be matrix.
> 
> Signed-off-by: Frank Li <Frank.Li@....com>
> 
> ---
> Not sure why it impact other mmc yaml's voltage-ranges.

It's a quirk of the tools. When decoding properties, the tools only know 
all possible types. Types are global, not per binding. Sometimes it can 
be figured out, but cases like this cannot be.

> ---
>  Documentation/devicetree/bindings/mmc/mmc-spi-slot.yaml | 17 ++++++++++-------
>  1 file changed, 10 insertions(+), 7 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/mmc/mmc-spi-slot.yaml b/Documentation/devicetree/bindings/mmc/mmc-spi-slot.yaml
> index 36acc40c7d181..05815b837219d 100644
> --- a/Documentation/devicetree/bindings/mmc/mmc-spi-slot.yaml
> +++ b/Documentation/devicetree/bindings/mmc/mmc-spi-slot.yaml
> @@ -27,17 +27,20 @@ properties:
>      maxItems: 1
>  
>    voltage-ranges:
> -    $ref: /schemas/types.yaml#/definitions/uint32-array
> +    $ref: /schemas/types.yaml#/definitions/uint32-matrix
>      description: |
>        Two cells are required, first cell specifies minimum slot voltage (mV),
>        second cell specifies maximum slot voltage (mV).
>      items:
> -      - description: |
> -          value for minimum slot voltage in mV
> -        default: 3200
> -      - description: |
> -          value for maximum slot voltage in mV
> -        default: 3400
> +      items:
> +        - description: |
> +            value for minimum slot voltage in mV
> +          default: 3200
> +        - description: |
> +            value for maximum slot voltage in mV
> +          default: 3400
> +    minItems: 1
> +    maxItems: 8

>From what I remember, SPI mode doesn't support voltage changes. 
Switching to 1.8V came much later in the spec. So it should be 
'maxItems: 1'. Or better yet, make the outer 'items' a list (of 1 
entry).

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ