On Tue, May 24, 2016 at 3:18 PM, Laxman Dewangan <ldewan...@nvidia.com> wrote:
> When adding the gpiochip, the GPIO HW drivers' callback get_direction() > get called in atomic context. Some of the GPIO HW drivers can sleep when > accessing the register and hence it can create the sleeping call in > atomic context. > > Call get_direction() in non-atomic context from gpiochip_add() if GPIO > HW driver is having sleepable callback i.e. chip->can_sleep = 1. > > Signed-off-by: Laxman Dewangan <ldewan...@nvidia.com> > > --- > This is found when implementing the get_direction() of max77620 on 20160520 > linux-next. I chose to send a new patch just moving the lock release before the direction check. I just sent it with you as Reported-by. Yours, Linus Walleij