[PATCH 1/2] gpio: dwapb: Use human understandable gpio numbering.

Linus Walleij linus.walleij at linaro.org
Thu Jul 16 00:50:44 PDT 2015

On Wed, Jul 1, 2015 at 9:34 PM, Richard Cochran
<richardcochran at gmail.com> wrote:

> The system-on-chips using this IP core have well defined gpio numbers.
> Instead of using random numbers, this patch lets the device tree specify
> the correct gpio numbering.
> Signed-off-by: Richard Cochran <rcochran at linutronix.de>
> +- snps,base : The base gpio number.

NACK. And it has been NACKed before again and again, search
the mailinglist for repetitive answers.

The GPIO numbers inside the Linux kernel are Linux specific and
have nothing to do with the hardware numbers. If they sometimes
match it is a lucky coincidence. The same goes for IRQ numbers
in the kernel FWIW.

So this "binding" has nothing to do with describing the hardware,
which device tree is for. If it ever comes to exist it needs to be
a "linux-*" property. But I doubt it will.

We are working to remove dependency on them by introducing GPIO
descriptors and thinking heavily about how to handle the userspace
sysfs ABI moving forward. But for the ABI the numbers just need to
be stable, not intuitive.

Linus Walleij

More information about the linux-arm-kernel mailing list