summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorGraf Yang <graf.yang@analog.com>2009-02-04 16:49:45 +0800
committerBryan Wu <cooloney@kernel.org>2009-02-04 16:49:45 +0800
commit0ce5eaf8ec156926a29313de877d9d5e0a692054 (patch)
tree01e728442c05e580e17c10b4b2caba3d03ea1a81 /arch
parent047481f348668340fab7164b12be130ca2ad2522 (diff)
downloadop-kernel-dev-0ce5eaf8ec156926a29313de877d9d5e0a692054.zip
op-kernel-dev-0ce5eaf8ec156926a29313de877d9d5e0a692054.tar.gz
Blackfin arch: Fix bug - BF518 port F, G, and H have different mux offset compare to BF527
[Mike Frysinger <vapier.adi@gmail.com>: keep the ifdef nest down] Signed-off-by: Graf Yang <graf.yang@analog.com> Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/blackfin/kernel/bfin_gpio.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/arch/blackfin/kernel/bfin_gpio.c b/arch/blackfin/kernel/bfin_gpio.c
index 44b6c9d..51dac55 100644
--- a/arch/blackfin/kernel/bfin_gpio.c
+++ b/arch/blackfin/kernel/bfin_gpio.c
@@ -108,12 +108,19 @@ static unsigned short * const port_mux[] = {
};
static const
-u8 pmux_offset[][16] =
- {{ 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 4, 6, 8, 8, 10, 10 }, /* PORTF */
- { 0, 0, 0, 0, 0, 2, 2, 4, 4, 6, 8, 10, 10, 10, 12, 12 }, /* PORTG */
- { 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 4, 4, 4, 4 }, /* PORTH */
- };
+u8 pmux_offset[][16] = {
+# if defined(BF527_FAMILY)
+ { 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 4, 6, 8, 8, 10, 10 }, /* PORTF */
+ { 0, 0, 0, 0, 0, 2, 2, 4, 4, 6, 8, 10, 10, 10, 12, 12 }, /* PORTG */
+ { 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 4, 4, 4, 4 }, /* PORTH */
+# elif defined(BF518_FAMILY)
+ { 0, 2, 2, 2, 2, 2, 2, 4, 6, 6, 6, 8, 8, 8, 8, 10 }, /* PORTF */
+ { 0, 0, 0, 2, 4, 6, 6, 6, 8, 10, 10, 12, 14, 14, 14, 14 }, /* PORTG */
+ { 0, 0, 0, 0, 2, 2, 4, 6, 10, 10, 10, 10, 10, 10, 10, 10 }, /* PORTH */
+# endif
+};
# endif
+
#endif
static unsigned short reserved_gpio_map[GPIO_BANK_NUM];
OpenPOWER on IntegriCloud