diff options
Diffstat (limited to 'arch/arm/mach-omap1/mux.c')
-rw-r--r-- | arch/arm/mach-omap1/mux.c | 77 |
1 files changed, 29 insertions, 48 deletions
diff --git a/arch/arm/mach-omap1/mux.c b/arch/arm/mach-omap1/mux.c index 721e0d9d8b1d..785371e982fc 100644 --- a/arch/arm/mach-omap1/mux.c +++ b/arch/arm/mach-omap1/mux.c | |||
@@ -29,53 +29,39 @@ | |||
29 | 29 | ||
30 | #include <asm/system.h> | 30 | #include <asm/system.h> |
31 | 31 | ||
32 | #include <mach/mux.h> | 32 | #include <plat/mux.h> |
33 | 33 | ||
34 | #ifdef CONFIG_OMAP_MUX | 34 | #ifdef CONFIG_OMAP_MUX |
35 | 35 | ||
36 | static struct omap_mux_cfg arch_mux_cfg; | 36 | static struct omap_mux_cfg arch_mux_cfg; |
37 | 37 | ||
38 | #ifdef CONFIG_ARCH_OMAP730 | 38 | #if defined(CONFIG_ARCH_OMAP730) || defined(CONFIG_ARCH_OMAP850) |
39 | static struct pin_config __initdata_or_module omap730_pins[] = { | 39 | static struct pin_config __initdata_or_module omap7xx_pins[] = { |
40 | MUX_CFG_730("E2_730_KBR0", 12, 21, 0, 20, 1, 0) | 40 | MUX_CFG_7XX("E2_7XX_KBR0", 12, 21, 0, 20, 1, 0) |
41 | MUX_CFG_730("J7_730_KBR1", 12, 25, 0, 24, 1, 0) | 41 | MUX_CFG_7XX("J7_7XX_KBR1", 12, 25, 0, 24, 1, 0) |
42 | MUX_CFG_730("E1_730_KBR2", 12, 29, 0, 28, 1, 0) | 42 | MUX_CFG_7XX("E1_7XX_KBR2", 12, 29, 0, 28, 1, 0) |
43 | MUX_CFG_730("F3_730_KBR3", 13, 1, 0, 0, 1, 0) | 43 | MUX_CFG_7XX("F3_7XX_KBR3", 13, 1, 0, 0, 1, 0) |
44 | MUX_CFG_730("D2_730_KBR4", 13, 5, 0, 4, 1, 0) | 44 | MUX_CFG_7XX("D2_7XX_KBR4", 13, 5, 0, 4, 1, 0) |
45 | MUX_CFG_730("C2_730_KBC0", 13, 9, 0, 8, 1, 0) | 45 | MUX_CFG_7XX("C2_7XX_KBC0", 13, 9, 0, 8, 1, 0) |
46 | MUX_CFG_730("D3_730_KBC1", 13, 13, 0, 12, 1, 0) | 46 | MUX_CFG_7XX("D3_7XX_KBC1", 13, 13, 0, 12, 1, 0) |
47 | MUX_CFG_730("E4_730_KBC2", 13, 17, 0, 16, 1, 0) | 47 | MUX_CFG_7XX("E4_7XX_KBC2", 13, 17, 0, 16, 1, 0) |
48 | MUX_CFG_730("F4_730_KBC3", 13, 21, 0, 20, 1, 0) | 48 | MUX_CFG_7XX("F4_7XX_KBC3", 13, 21, 0, 20, 1, 0) |
49 | MUX_CFG_730("E3_730_KBC4", 13, 25, 0, 24, 1, 0) | 49 | MUX_CFG_7XX("E3_7XX_KBC4", 13, 25, 0, 24, 1, 0) |
50 | 50 | ||
51 | MUX_CFG_730("AA17_730_USB_DM", 2, 21, 0, 20, 0, 0) | 51 | MUX_CFG_7XX("AA17_7XX_USB_DM", 2, 21, 0, 20, 0, 0) |
52 | MUX_CFG_730("W16_730_USB_PU_EN", 2, 25, 0, 24, 0, 0) | 52 | MUX_CFG_7XX("W16_7XX_USB_PU_EN", 2, 25, 0, 24, 0, 0) |
53 | MUX_CFG_730("W17_730_USB_VBUSI", 2, 29, 0, 28, 0, 0) | 53 | MUX_CFG_7XX("W17_7XX_USB_VBUSI", 2, 29, 0, 28, 0, 0) |
54 | |||
55 | /* MMC Pins */ | ||
56 | MUX_CFG_7XX("MMC_7XX_CMD", 2, 9, 0, 8, 1, 0) | ||
57 | MUX_CFG_7XX("MMC_7XX_CLK", 2, 13, 0, 12, 1, 0) | ||
58 | MUX_CFG_7XX("MMC_7XX_DAT0", 2, 17, 0, 16, 1, 0) | ||
54 | }; | 59 | }; |
55 | #define OMAP730_PINS_SZ ARRAY_SIZE(omap730_pins) | 60 | #define OMAP7XX_PINS_SZ ARRAY_SIZE(omap7xx_pins) |
56 | #else | 61 | #else |
57 | #define omap730_pins NULL | 62 | #define omap7xx_pins NULL |
58 | #define OMAP730_PINS_SZ 0 | 63 | #define OMAP7XX_PINS_SZ 0 |
59 | #endif /* CONFIG_ARCH_OMAP730 */ | 64 | #endif /* CONFIG_ARCH_OMAP730 || CONFIG_ARCH_OMAP850 */ |
60 | |||
61 | #ifdef CONFIG_ARCH_OMAP850 | ||
62 | struct pin_config __initdata_or_module omap850_pins[] = { | ||
63 | MUX_CFG_850("E2_850_KBR0", 12, 21, 0, 20, 1, 0) | ||
64 | MUX_CFG_850("J7_850_KBR1", 12, 25, 0, 24, 1, 0) | ||
65 | MUX_CFG_850("E1_850_KBR2", 12, 29, 0, 28, 1, 0) | ||
66 | MUX_CFG_850("F3_850_KBR3", 13, 1, 0, 0, 1, 0) | ||
67 | MUX_CFG_850("D2_850_KBR4", 13, 5, 0, 4, 1, 0) | ||
68 | MUX_CFG_850("C2_850_KBC0", 13, 9, 0, 8, 1, 0) | ||
69 | MUX_CFG_850("D3_850_KBC1", 13, 13, 0, 12, 1, 0) | ||
70 | MUX_CFG_850("E4_850_KBC2", 13, 17, 0, 16, 1, 0) | ||
71 | MUX_CFG_850("F4_850_KBC3", 13, 21, 0, 20, 1, 0) | ||
72 | MUX_CFG_850("E3_850_KBC4", 13, 25, 0, 24, 1, 0) | ||
73 | |||
74 | MUX_CFG_850("AA17_850_USB_DM", 2, 21, 0, 20, 0, 0) | ||
75 | MUX_CFG_850("W16_850_USB_PU_EN", 2, 25, 0, 24, 0, 0) | ||
76 | MUX_CFG_850("W17_850_USB_VBUSI", 2, 29, 0, 28, 0, 0) | ||
77 | }; | ||
78 | #endif | ||
79 | 65 | ||
80 | #if defined(CONFIG_ARCH_OMAP15XX) || defined(CONFIG_ARCH_OMAP16XX) | 66 | #if defined(CONFIG_ARCH_OMAP15XX) || defined(CONFIG_ARCH_OMAP16XX) |
81 | static struct pin_config __initdata_or_module omap1xxx_pins[] = { | 67 | static struct pin_config __initdata_or_module omap1xxx_pins[] = { |
@@ -438,11 +424,6 @@ int __init_or_module omap1_cfg_reg(const struct pin_config *cfg) | |||
438 | printk(" %s (0x%08x) = 0x%08x -> 0x%08x\n", | 424 | printk(" %s (0x%08x) = 0x%08x -> 0x%08x\n", |
439 | cfg->pull_name, cfg->pull_reg, pull_orig, pull); | 425 | cfg->pull_name, cfg->pull_reg, pull_orig, pull); |
440 | } | 426 | } |
441 | |||
442 | #ifdef CONFIG_ARCH_OMAP850 | ||
443 | omap_mux_register(omap850_pins, ARRAY_SIZE(omap850_pins)); | ||
444 | #endif | ||
445 | |||
446 | #endif | 427 | #endif |
447 | 428 | ||
448 | #ifdef CONFIG_OMAP_MUX_ERRORS | 429 | #ifdef CONFIG_OMAP_MUX_ERRORS |
@@ -454,9 +435,9 @@ int __init_or_module omap1_cfg_reg(const struct pin_config *cfg) | |||
454 | 435 | ||
455 | int __init omap1_mux_init(void) | 436 | int __init omap1_mux_init(void) |
456 | { | 437 | { |
457 | if (cpu_is_omap730()) { | 438 | if (cpu_is_omap7xx()) { |
458 | arch_mux_cfg.pins = omap730_pins; | 439 | arch_mux_cfg.pins = omap7xx_pins; |
459 | arch_mux_cfg.size = OMAP730_PINS_SZ; | 440 | arch_mux_cfg.size = OMAP7XX_PINS_SZ; |
460 | arch_mux_cfg.cfg_reg = omap1_cfg_reg; | 441 | arch_mux_cfg.cfg_reg = omap1_cfg_reg; |
461 | } | 442 | } |
462 | 443 | ||