lkml.org 
[lkml]   [2019]   [Sep]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] FBTFT: fb_agm1264k: usleep_range is preferred over udelay
On Sun, Sep 08, 2019 at 08:26:05PM -0500, Sreeram Veluthakkal wrote:
> This patch fixes the issue:
> FILE: drivers/staging/fbtft/fb_agm1264k-fl.c:88:
> CHECK: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
> + udelay(20);
>
> Signed-off-by: Sreeram Veluthakkal <srrmvlt@gmail.com>
> ---
> drivers/staging/fbtft/fb_agm1264k-fl.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/fbtft/fb_agm1264k-fl.c b/drivers/staging/fbtft/fb_agm1264k-fl.c
> index eeeeec97ad27..2dece71fd3b5 100644
> --- a/drivers/staging/fbtft/fb_agm1264k-fl.c
> +++ b/drivers/staging/fbtft/fb_agm1264k-fl.c
> @@ -85,7 +85,7 @@ static void reset(struct fbtft_par *par)
> dev_dbg(par->info->device, "%s()\n", __func__);
>
> gpiod_set_value(par->gpio.reset, 0);
> - udelay(20);
> + usleep_range(20, 40);

Is it "safe" to wait 40? This kind of change you can only do if you
know this is correct. Have you tested this with hardware?

thanks,

greg k-h

\
 
 \ /
  Last update: 2019-09-09 11:56    [W:0.099 / U:19.968 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site