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]
Date:   Tue, 28 Feb 2023 12:34:31 +0100
From:   Krzysztof Kozlowski <krzk@...nel.org>
To:     Paul Geurts <paul.geurts@...drive-technologies.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 4/4] net: dsa: b53: mdio: Add optional reset gpio

On 27/02/2023 20:44, Paul Geurts wrote:
> Some Broadcom Ethernet switch devices feature a reset pin driven by GPIO.
> Provide the option to specify a reset gpio.
> 
> Signed-off-by: Paul Geurts <paul.geurts@...drive-technologies.com>
> ---
>  drivers/net/dsa/b53/b53_mdio.c | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/drivers/net/dsa/b53/b53_mdio.c b/drivers/net/dsa/b53/b53_mdio.c index 8b422b298cd5..32af5881834c 100644
> --- a/drivers/net/dsa/b53/b53_mdio.c
> +++ b/drivers/net/dsa/b53/b53_mdio.c
> @@ -22,6 +22,7 @@
>  #include <linux/delay.h>
>  #include <linux/brcmphy.h>
>  #include <linux/rtnetlink.h>
> +#include <linux/gpio/consumer.h>
>  #include <net/dsa.h>
>  
>  #include "b53_priv.h"
> @@ -303,6 +304,14 @@ static int b53_mdio_probe(struct mdio_device *mdiodev)
>  		return -ENODEV;
>  	}
>  
> +	/* Try to get a reset GPIO and get the switch out of reset when its there */
> +	mdiodev->reset_gpio = devm_gpiod_get_optional(&mdiodev->dev, "reset", GPIOD_OUT_HIGH);

Aren't you adding now undocumented property? Does your DTS passes
dtbs_check?

Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ