From mboxrd@z Thu Jan 1 00:00:00 1970 From: "John B. Wyatt IV" Date: Sun, 29 Mar 2020 09:22:04 +0000 Subject: [PATCH] staging: fbtft: Replace udelay with preferred usleep_range Message-Id: <20200329092204.770405-1-jbwyatt4@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: outreachy-kernel@googlegroups.com, Greg Kroah-Hartman , Payal Kshirsagar , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Cc: "John B. Wyatt IV" Fix style issue with usleep_range being reported as preferred over udelay. Issue reported by checkpatch. Please review. As written in Documentation/timers/timers-howto.rst udelay is the generally preferred API. hrtimers, as noted in the docs, may be too expensive for this short timer. Are the docs out of date, or, is this a checkpatch issue? Signed-off-by: John B. Wyatt IV --- 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..019c8cce6bab 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, 20); gpiod_set_value(par->gpio.reset, 1); mdelay(120); } -- 2.25.1