Re: [PATCH] staging: fbtft: Replace mdelay() with msleep() and usleep_range()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jul 27, 2018 at 12:21 PM, Jia-Ju Bai <baijiaju1990@xxxxxxxxx> wrote:
> reset() and init_display() are never called in atomic context.
> They call mdelay() to busily wait, which is not necessary.
> mdelay() can be replaced with msleep().

>         gpio_set_value(par->gpio.reset, 0);
>         udelay(20);
>         gpio_set_value(par->gpio.reset, 1);
> -       mdelay(120);
> +       msleep(120);

I didn't look to the rest, but this one will be inconsistent after your patch.

The question here is why udelay() is needed, while mdelay() changed?

-- 
With Best Regards,
Andy Shevchenko
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux