diff options
author | Patrice Chotard <patrice.chotard@stericsson.com> | 2012-10-08 10:35:09 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2012-10-28 16:16:15 -0400 |
commit | f64228ee23975d3703121a3d27dac488c3c813e9 (patch) | |
tree | da422e440ad4ef069a86021894b62d3a9455a7f6 | |
parent | 748a2b72655334f01aff84a67747a78f8d1c8109 (diff) |
ARM: plat-nomadik: move NMK_GPIO_PER_CHIP into gpio-nomadik.h
Move NMK_GPIO_PER_CHIP to gpio-nomadik.h and define it with a
shift operator.
Signed-off-by: Patrice Chotard <patrice.chotard@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-rw-r--r-- | arch/arm/plat-nomadik/include/plat/gpio-nomadik.h | 3 | ||||
-rw-r--r-- | drivers/pinctrl/pinctrl-nomadik.c | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/arch/arm/plat-nomadik/include/plat/gpio-nomadik.h b/arch/arm/plat-nomadik/include/plat/gpio-nomadik.h index cf81111b79a6..a74999438de4 100644 --- a/arch/arm/plat-nomadik/include/plat/gpio-nomadik.h +++ b/arch/arm/plat-nomadik/include/plat/gpio-nomadik.h | |||
@@ -18,6 +18,9 @@ | |||
18 | * the "gpio" namespace for generic and cross-machine functions | 18 | * the "gpio" namespace for generic and cross-machine functions |
19 | */ | 19 | */ |
20 | 20 | ||
21 | #define GPIO_BLOCK_SHIFT 5 | ||
22 | #define NMK_GPIO_PER_CHIP (1 << GPIO_BLOCK_SHIFT) | ||
23 | |||
21 | /* Register in the logic block */ | 24 | /* Register in the logic block */ |
22 | #define NMK_GPIO_DAT 0x00 | 25 | #define NMK_GPIO_DAT 0x00 |
23 | #define NMK_GPIO_DATS 0x04 | 26 | #define NMK_GPIO_DATS 0x04 |
diff --git a/drivers/pinctrl/pinctrl-nomadik.c b/drivers/pinctrl/pinctrl-nomadik.c index cf82d9ce4dee..f5c0da1f3b30 100644 --- a/drivers/pinctrl/pinctrl-nomadik.c +++ b/drivers/pinctrl/pinctrl-nomadik.c | |||
@@ -60,8 +60,6 @@ static inline void prcmu_write_masked(unsigned int reg, u32 mask, u32 value) {} | |||
60 | * Symbols in this file are called "nmk_gpio" for "nomadik gpio" | 60 | * Symbols in this file are called "nmk_gpio" for "nomadik gpio" |
61 | */ | 61 | */ |
62 | 62 | ||
63 | #define NMK_GPIO_PER_CHIP 32 | ||
64 | |||
65 | struct nmk_gpio_chip { | 63 | struct nmk_gpio_chip { |
66 | struct gpio_chip chip; | 64 | struct gpio_chip chip; |
67 | struct irq_domain *domain; | 65 | struct irq_domain *domain; |