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: <20241219163802.01a6a7b4@booty>
Date: Thu, 19 Dec 2024 16:38:02 +0100
From: Luca Ceresoli <luca.ceresoli@...tlin.com>
To: Bartosz Golaszewski <brgl@...ev.pl>
Cc: Linus Walleij <linus.walleij@...aro.org>, Thomas Petazzoni
 <thomas.petazzoni@...tlin.com>, linux-gpio@...r.kernel.org,
 linux-kernel@...r.kernel.org, Steve Longerbeam <slongerbeam@...il.com>
Subject: Re: [PATCH] gpio: pca953x: log an error when failing to get the
 reset GPIO

Hi Bartosz,

+Cc: Steve (original author of the changed lines)

On Thu, 19 Dec 2024 15:41:45 +0100
Bartosz Golaszewski <brgl@...ev.pl> wrote:

> On Thu, Dec 19, 2024 at 10:39 AM Luca Ceresoli
> <luca.ceresoli@...tlin.com> wrote:
> >
> > When the dirver fails getting this GPIO, it fails silently. Log an error
> > message to make debugging a lot easier by just reading dmesg.
> >
> > Signed-off-by: Luca Ceresoli <luca.ceresoli@...tlin.com>
> > ---
> >  drivers/gpio/gpio-pca953x.c | 3 ++-
> >  1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpio/gpio-pca953x.c b/drivers/gpio/gpio-pca953x.c
> > index 272febc3230e90baf370811f498383b9fb12cc6f..be4c9981ebc404ad5c1e1b0ba9f9f948122de462 100644
> > --- a/drivers/gpio/gpio-pca953x.c
> > +++ b/drivers/gpio/gpio-pca953x.c
> > @@ -1088,7 +1088,8 @@ static int pca953x_probe(struct i2c_client *client)
> >                  */
> >                 reset_gpio = devm_gpiod_get_optional(dev, "reset", GPIOD_OUT_LOW);
> >                 if (IS_ERR(reset_gpio))
> > -                       return PTR_ERR(reset_gpio);
> > +                       return dev_err_probe(dev, PTR_ERR(reset_gpio),
> > +                                            "Failed to get reset gpio\n");
> >         }
> >
> >         chip->client = client;
> >
> > ---  
> 
> Fixes: and Cc: stable tags?

I haven't been considering my patch a fix but rather an improvement.
However in case if you think it should be considered a bugfix, then
this should be the fixes line:

Fixes: 054ccdef8b28 ("gpio: pca953x: Add optional reset gpio control")

Luca

-- 
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ