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: <20190811094924.42d49ce2@archlinux>
Date:   Sun, 11 Aug 2019 09:50:10 +0100
From:   Jonathan Cameron <jic23@...nel.org>
To:     Andrey Smirnov <andrew.smirnov@...il.com>
Cc:     linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org,
        Chris Healy <cphealy@...il.com>,
        Nikita Yushchenko <nikita.yoush@...entembedded.com>,
        Vladimir Barinov <vladimir.barinov@...entembedded.com>
Subject: Re: [PATCH] iio: hi8435: Use gpiod_set_value_cansleep()

+CC Nikita, Valdimir.

On Sat, 10 Aug 2019 22:45:11 -0700
Andrey Smirnov <andrew.smirnov@...il.com> wrote:

> Use gpiod_set_value_cansleep() instead of gpiod_set_value() to support
> the case when reset pin is connected to a GPIO expander. See ZII VF610
> SCU4 AIB for one such example.
> 
> Signed-off-by: Andrey Smirnov <andrew.smirnov@...il.com>
> Cc: linux-kernel@...r.kernel.org
> Cc: linux-iio@...r.kernel.org
> Cc: Jonathan Cameron <jic23@...nel.org>
> Cc: Chris Healy <cphealy@...il.com>

Seems sensible to me so I've applied it to the togreg branch of iio.git and
pushed out as testing for the autobuilder to play with it.

Still time for last minute comments if anyone has them though.

Thanks,

Jonathan

> ---
>  drivers/iio/adc/hi8435.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/adc/hi8435.c b/drivers/iio/adc/hi8435.c
> index 35951c47004e..c15f0e154e4d 100644
> --- a/drivers/iio/adc/hi8435.c
> +++ b/drivers/iio/adc/hi8435.c
> @@ -477,7 +477,7 @@ static int hi8435_probe(struct spi_device *spi)
>  		hi8435_writeb(priv, HI8435_CTRL_REG, 0);
>  	} else {
>  		udelay(5);
> -		gpiod_set_value(reset_gpio, 1);
> +		gpiod_set_value_cansleep(reset_gpio, 1);
>  	}
>  
>  	spi_set_drvdata(spi, idev);

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ