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: <Z6OE0IRgaovHMf34@google.com>
Date: Wed, 5 Feb 2025 07:33:36 -0800
From: Dmitry Torokhov <dmitry.torokhov@...il.com>
To: Hugo Villeneuve <hugo@...ovil.com>
Cc: Linus Walleij <linus.walleij@...aro.org>,
	Alistair Francis <alistair@...stair23.me>,
	Maxime Ripard <mripard@...nel.org>,
	Mylène Josserand <mylene.josserand@...tlin.com>,
	Hugo Villeneuve <hvilleneuve@...onoff.com>, stable@...r.kernel.org,
	linux-input@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Input: cyttsp5 - ensure minimum reset pulse width

On Tue, Feb 04, 2025 at 02:01:00PM -0500, Hugo Villeneuve wrote:
> From: Hugo Villeneuve <hvilleneuve@...onoff.com>
> 
> The current reset pulse width is measured to be 5us on a
> Renesas RZ/G2L SOM. The manufacturer's minimum reset pulse width is
> specified as 10us.
> 
> Extend reset pulse width to make sure it is long enough on all platforms.
> 
> Also reword confusing comments about reset pin assertion.
> 
> Fixes: 5b0c03e24a06 ("Input: Add driver for Cypress Generation 5 touchscreen")
> Cc: <stable@...r.kernel.org>
> Signed-off-by: Hugo Villeneuve <hvilleneuve@...onoff.com>
> ---
>  drivers/input/touchscreen/cyttsp5.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/input/touchscreen/cyttsp5.c b/drivers/input/touchscreen/cyttsp5.c
> index eafe5a9b8964..bb09e84d0e92 100644
> --- a/drivers/input/touchscreen/cyttsp5.c
> +++ b/drivers/input/touchscreen/cyttsp5.c
> @@ -870,13 +870,16 @@ static int cyttsp5_probe(struct device *dev, struct regmap *regmap, int irq,
>  	ts->input->phys = ts->phys;
>  	input_set_drvdata(ts->input, ts);
>  
> -	/* Reset the gpio to be in a reset state */
> +	/* Assert gpio to be in a reset state */
>  	ts->reset_gpio = devm_gpiod_get_optional(dev, "reset", GPIOD_OUT_HIGH);
>  	if (IS_ERR(ts->reset_gpio)) {
>  		error = PTR_ERR(ts->reset_gpio);
>  		dev_err(dev, "Failed to request reset gpio, error %d\n", error);
>  		return error;
>  	}
> +
> +	fsleep(1000); /* Ensure long-enough reset pulse (minimum 10us). */
> +

If the manufacturer specified that 10us is enough why do we want to wait
100 times longer?

Thanks.

-- 
Dmitry

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ