On Tue, Jan 27, 2015 at 5:46 AM, Rob Herring <[email protected]> wrote:

> Add support for PXA1928 GPIOs. The PXA1928 adds a 6th bank from previous
> generations.
>
> Signed-off-by: Jing Xiang <[email protected]>
> Signed-off-by: Xiangzhan Meng <[email protected]>
> [robh: ported to 3.19 from vendor kernel]
> Signed-off-by: Rob Herring <[email protected]>
> Cc: Linus Walleij <[email protected]>
> Cc: Alexandre Courbot <[email protected]>

Patch applied...

> -#define BANK_OFF(n)    (((n) < 3) ? (n) << 2 : 0x100 + (((n) - 3) << 2))
> +#define BANK_OFF(n)    (((n) < 3) ? (n) << 2 : ((n) > 5 ? 0x200 : 0x100)     
>   \
> +                       + (((n) % 3) << 2))

While this is a bit convoluted.

Someone care to send a patch converting it to something like a
parseable static inline?

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

Reply via email to