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] [day] [month] [year] [list]
Message-ID: <a5028d5a-cc93-4ece-bff5-16990a7de2e3@kernel.org>
Date: Mon, 2 Jun 2025 21:53:17 +0200
From: Krzysztof Kozlowski <krzk@...nel.org>
To: Corentin Guillevic <corentin.guillevic@...le.fr>,
 Woojung Huh <woojung.huh@...rochip.com>, UNGLinuxDriver@...rochip.com,
 Andrew Lunn <andrew@...n.ch>, Vladimir Oltean <olteanv@...il.com>,
 "David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
 Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
 Rob Herring <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>,
 Conor Dooley <conor+dt@...nel.org>, Marek Vasut <marex@...x.de>
Cc: netdev@...r.kernel.org, devicetree@...r.kernel.org,
 linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] dt-bindings: net: dsa: microchip: add bit-banged SMI
 example

On 02/06/2025 19:04, Corentin Guillevic wrote:
> KSZ8863 can be configured using I2C, SPI or Microchip SMI. The latter is
> similar to MDIO, but uses a different protocol. If the hardware doesn't
> support this, SMI bit banging can help. This commit adds an device tree
> example that uses the CONFIG_MDIO_GPIO driver for SMI bit banging.

So the difference is in one property? Or no difference at all...

> 
> Signed-off-by: Corentin Guillevic <corentin.guillevic@...le.fr>
> ---
> Changes in v2:
> - Fix dt_binding_check errors
> 
>  .../bindings/net/dsa/microchip,ksz.yaml       | 59 ++++++++++++++++++-
>  1 file changed, 58 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> index 62ca63e8a26f..33a067809ebe 100644
> --- a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> @@ -241,4 +241,61 @@ examples:
>              };
>          };
>      };
> -...
> +
> +  # KSZ8863 with bit-banged SMI
> +  - |
> +    #include <dt-bindings/gpio/gpio.h>
> +
> +    // Ethernet switch connected via SMI to the host, CPU port wired to eth0:
> +    ethernet0 {


Drop node, not really used.

> +        phy-mode = "rmii";
> +
> +        fixed-link {
> +            speed = <100>;
> +            full-duplex;
> +            pause;
> +        };
> +    };
> +
> +    mdio: mdio {
> +        #address-cells = <1>;
> +        #size-cells = <0>;

Order properties according to DTS coding style.

> +        compatible = "microchip,mdio-smi0";

Not relevant. This binding describes device, not bus.

> +        gpios = <&gpioc 1 GPIO_ACTIVE_HIGH>,
> +            <&gpioa 2 GPIO_ACTIVE_HIGH>;

Messed indentation

> +        status = "okay";

Drop status

but anyway all above is not really relevant, drop.

> +
> +        switch@0 {
> +            compatible = "microchip,ksz8863";
> +            reg = <0>;
> +            reset-gpios = <&gpioa 4 GPIO_ACTIVE_LOW>;
> +            status = "okay";

Drop.

After cleanup from redundant pieces there is basically no difference.
Don't add examples which differ by compatible (or even by one property).



Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ