On Mon, Aug 13, 2018 at 07:00:27PM +0300, Andy Shevchenko wrote: > The commit ca876c7483b6 > > ("gpiolib-acpi: make sure we trigger edge events at least once on boot") > > added a initial value check for pin which is about to be locked as IRQ. > Unfortunately, not all GPIO drivers can do that atomically. Thus, > switch to cansleep version of the call. Otherwise we have a warning: > > ... > WARNING: CPU: 2 PID: 1408 at drivers/gpio/gpiolib.c:2883 gpiod_get_value+0x46/0x50 > ... > RIP: 0010:gpiod_get_value+0x46/0x50 > ... > > The change tested on Intel Broxton with Whiskey Cove PMIC GPIO controller. > > Fixes: ca876c7483b6 ("gpiolib-acpi: make sure we trigger edge events at least once on boot") > Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> > Cc: Hans de Goede <hdegoede@xxxxxxxxxx> > Cc: Benjamin Tissoires <benjamin.tissoires@xxxxxxxxxx> > Cc: Mika Westerberg <mika.westerberg@xxxxxxxxxxxxxxx> Acked-by: Mika Westerberg <mika.westerberg@xxxxxxxxxxxxxxx>