Re: [PATCH RFT 4/5] gpio: gpio-pl061: use the generic request/free implementations

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

 



On Sun, Sep 13, 2015 at 3:21 PM, Jonas Gorski <jogo@xxxxxxxxxxx> wrote:

>         spin_lock_init(&chip->lock);
> -       if (of_property_read_bool(dev->of_node, "gpio-ranges"))
> -               chip->uses_pinctrl = true;
> +       if (of_property_read_bool(dev->of_node, "gpio-ranges")) {
> +               chip->gc.request = gpiochip_generic_request;
> +               chip->gc.free = gpiochip_generic_free;
> +       }

This is way better.

But now this code is starting to multiply in drivers.

Can we think of a way to do this even more generic:
could gpiochip_generic_request() check if the range is
there instead?

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-gpio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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