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: <CAD++jLmBegkZyKoo2cgtgJt0-8Pn-H2XaAoqipgPp0hTmro+sQ@mail.gmail.com>
Date: Mon, 19 Jan 2026 00:12:05 +0100
From: Linus Walleij <linusw@...nel.org>
To: Jean-Michel Hautbois <jeanmichel.hautbois@...eli.org>
Cc: Rob Herring <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>, 
	Conor Dooley <conor+dt@...nel.org>, Himanshu Bhavani <himanshu.bhavani@...iconsignals.io>, 
	linux-gpio@...r.kernel.org, linux-kernel@...r.kernel.org, 
	devicetree@...r.kernel.org
Subject: Re: [PATCH 2/2] dt-bindings: pinctrl: mcp23s08: Add multi-chip example

On Wed, Jan 14, 2026 at 6:29 PM Jean-Michel Hautbois
<jeanmichel.hautbois@...eli.org> wrote:

> > Make some fancy - if: clauses to decide the maxItems from the compatible.
> > Don't hesitate to ask for help if this gets complicated, I get a panic
> > every time I have to deal with it because of the whitespacing business.
>
> Indeed, I was probably a bit optimistic :-).
> What about this:
>  allOf:
>    - $ref: /schemas/spi/spi-peripheral-props.yaml#
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - microchip,mcp23s08
> +              - microchip,mcp23008
> +    then:
> +      properties:
> +        gpio-line-names:
> +          maxItems: 32
> +        pinmux:
> +          properties:
> +            pins:
> +              maxItems: 32
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - microchip,mcp23s17
> +              - microchip,mcp23s18
> +              - microchip,mcp23017
> +              - microchip,mcp23018
> +    then:
> +      properties:
> +        gpio-line-names:
> +          maxItems: 128
> +        pinmux:
> +          properties:
> +            pins:
> +              maxItems: 128
> +
>
> This would allow up to 4 chips to be on the same CS.

Hm I don't get it why everything is multiplied by 4 here?

Doesn't each chip have its own instance? And the instance is
limited to 8 or 16 lines/pins?

> But in the
> microchip,mcp23s17 datasheet, it says:
> "Three Hardware Address Pins to Allow Up to Eight Devices On the Bus"

Doesn't each device have its own entry?

Yours,
Linus Walleij

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ