On Thu, Aug 9, 2018 at 3:03 PM Florian Eckert <fe@xxxxxxxxxx> wrote: > +config GPIO_APU > + tristate "PC Engines APU2/APU3 GPIO support" > + depends on X86 > + select GPIO_GENERIC So > +static int gpio_apu_dir_out(struct gpio_chip *chip, unsigned offset, > +static int gpio_apu_get_data(struct gpio_chip *chip, unsigned offset) > +static void gpio_apu_set_data(struct gpio_chip *chip, unsigned offset, int value) (...) > + .get_direction = gpio_apu_get_dir, > + .direction_input = gpio_apu_dir_in, > + .direction_output = gpio_apu_dir_out, > + .get = gpio_apu_get_data, > + .set = gpio_apu_set_data, Please make use of GPIO_GENERIC (bgpio_init()) as detailed in my first answer. Use the spinlock in the gpio_chip when doing this. Yours, Linus Walleij