Re: [PATCH 1/2] gpio: Add driver for PC Engines APU2/APU3 GPIOs

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

 



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



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux