diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-23 13:20:15 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-23 13:20:15 -0400 |
| commit | 36ec891895020f3bc9953c8b11d079c6d77d76bd (patch) | |
| tree | 89961ee93d8bf5f4e924c2e02790ddd52d61da5c /arch/sh/include | |
| parent | 70740d6c93030b339b4ad17fd58ee135dfc13913 (diff) | |
| parent | e4b41dbd60e30463cc8fab21ed45b7d6227fc338 (diff) | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (23 commits)
sh: asm/gpio.h needs linux/kernel.h for might_sleep()/WARN_ON().
sh: mach-highlander: Handle SCIF pinmuxing on R7785RP.
sh: sh7785 pinmux support
sh: update defconfigs.
sh: Kill off unused p1fc divisors from SH7763 clk fwk.
sh: improve pinmux support for single direction pins
sh: use 10MHz VIO_CLK for ov772x on Migo-R
sh: Update gpio_set_value() pin value handling
sh: update ov772x byte order on Migo-R
rtc: Add R2025S/D comment to rs5c372 Kconfig entry.
sh: Export cache flush routines needed by sh_eth on SH7619.
sh: Wire up oops reporting in the die notifier chain.
sh: ap325rxa: Kill off unused port definitions.
sh: Hook up PB0->PB7 input-only pins in SH7203 PFC.
sh: ap325rxa: Move off of hardcoded pinmux for flctl initialization.
sh: add support FLCTL for ap325rxa board
sh: gpio: Stub in dummy GPIO<->IRQ mapping routines.
sh: rsk7203: leds-gpio support for RSK+ LEDs.
sh: gpio: Include asm-generic/gpio.h for non-gpiolib stubs.
sh: fix soc-camera compile breakage on Migo-R.
...
Diffstat (limited to 'arch/sh/include')
| -rw-r--r-- | arch/sh/include/asm/gpio.h | 19 | ||||
| -rw-r--r-- | arch/sh/include/asm/kdebug.h | 1 | ||||
| -rw-r--r-- | arch/sh/include/cpu-sh4/cpu/sh7785.h | 234 | ||||
| -rw-r--r-- | arch/sh/include/mach-common/mach/highlander.h | 6 |
4 files changed, 258 insertions, 2 deletions
diff --git a/arch/sh/include/asm/gpio.h b/arch/sh/include/asm/gpio.h index 9650e7c9c39e..90673658eb14 100644 --- a/arch/sh/include/asm/gpio.h +++ b/arch/sh/include/asm/gpio.h | |||
| @@ -12,6 +12,9 @@ | |||
| 12 | #ifndef __ASM_SH_GPIO_H | 12 | #ifndef __ASM_SH_GPIO_H |
| 13 | #define __ASM_SH_GPIO_H | 13 | #define __ASM_SH_GPIO_H |
| 14 | 14 | ||
| 15 | #include <linux/kernel.h> | ||
| 16 | #include <linux/errno.h> | ||
| 17 | |||
| 15 | #if defined(CONFIG_CPU_SH3) | 18 | #if defined(CONFIG_CPU_SH3) |
| 16 | #include <cpu/gpio.h> | 19 | #include <cpu/gpio.h> |
| 17 | #endif | 20 | #endif |
| @@ -62,6 +65,7 @@ struct pinmux_data_reg { | |||
| 62 | struct pinmux_range { | 65 | struct pinmux_range { |
| 63 | pinmux_enum_t begin; | 66 | pinmux_enum_t begin; |
| 64 | pinmux_enum_t end; | 67 | pinmux_enum_t end; |
| 68 | pinmux_enum_t force; | ||
| 65 | }; | 69 | }; |
| 66 | 70 | ||
| 67 | struct pinmux_info { | 71 | struct pinmux_info { |
| @@ -99,9 +103,20 @@ int gpio_direction_input(unsigned gpio); | |||
| 99 | int gpio_direction_output(unsigned gpio, int value); | 103 | int gpio_direction_output(unsigned gpio, int value); |
| 100 | int gpio_get_value(unsigned gpio); | 104 | int gpio_get_value(unsigned gpio); |
| 101 | void gpio_set_value(unsigned gpio, int value); | 105 | void gpio_set_value(unsigned gpio, int value); |
| 102 | static inline int gpio_export(unsigned gpio, bool direction_may_change) | 106 | |
| 107 | /* IRQ modes are unspported */ | ||
| 108 | static inline int gpio_to_irq(unsigned gpio) | ||
| 109 | { | ||
| 110 | WARN_ON(1); | ||
| 111 | return -EINVAL; | ||
| 112 | } | ||
| 113 | |||
| 114 | static inline int irq_to_gpio(unsigned irq) | ||
| 103 | { | 115 | { |
| 104 | return 0; | 116 | WARN_ON(1); |
| 117 | return -EINVAL; | ||
| 105 | } | 118 | } |
| 106 | 119 | ||
| 120 | #include <asm-generic/gpio.h> | ||
| 121 | |||
| 107 | #endif /* __ASM_SH_GPIO_H */ | 122 | #endif /* __ASM_SH_GPIO_H */ |
diff --git a/arch/sh/include/asm/kdebug.h b/arch/sh/include/asm/kdebug.h index 49cd69051a88..0b9f896f203c 100644 --- a/arch/sh/include/asm/kdebug.h +++ b/arch/sh/include/asm/kdebug.h | |||
| @@ -4,6 +4,7 @@ | |||
| 4 | /* Grossly misnamed. */ | 4 | /* Grossly misnamed. */ |
| 5 | enum die_val { | 5 | enum die_val { |
| 6 | DIE_TRAP, | 6 | DIE_TRAP, |
| 7 | DIE_OOPS, | ||
| 7 | }; | 8 | }; |
| 8 | 9 | ||
| 9 | #endif /* __ASM_SH_KDEBUG_H */ | 10 | #endif /* __ASM_SH_KDEBUG_H */ |
diff --git a/arch/sh/include/cpu-sh4/cpu/sh7785.h b/arch/sh/include/cpu-sh4/cpu/sh7785.h new file mode 100644 index 000000000000..e4006afb735e --- /dev/null +++ b/arch/sh/include/cpu-sh4/cpu/sh7785.h | |||
| @@ -0,0 +1,234 @@ | |||
| 1 | #ifndef __ASM_SH7785_H__ | ||
| 2 | #define __ASM_SH7785_H__ | ||
| 3 | |||
| 4 | enum { | ||
| 5 | /* PA */ | ||
| 6 | GPIO_PA7, GPIO_PA6, GPIO_PA5, GPIO_PA4, | ||
| 7 | GPIO_PA3, GPIO_PA2, GPIO_PA1, GPIO_PA0, | ||
| 8 | |||
| 9 | /* PB */ | ||
| 10 | GPIO_PB7, GPIO_PB6, GPIO_PB5, GPIO_PB4, | ||
| 11 | GPIO_PB3, GPIO_PB2, GPIO_PB1, GPIO_PB0, | ||
| 12 | |||
| 13 | /* PC */ | ||
| 14 | GPIO_PC7, GPIO_PC6, GPIO_PC5, GPIO_PC4, | ||
| 15 | GPIO_PC3, GPIO_PC2, GPIO_PC1, GPIO_PC0, | ||
| 16 | |||
| 17 | /* PD */ | ||
| 18 | GPIO_PD7, GPIO_PD6, GPIO_PD5, GPIO_PD4, | ||
| 19 | GPIO_PD3, GPIO_PD2, GPIO_PD1, GPIO_PD0, | ||
| 20 | |||
| 21 | /* PE */ | ||
| 22 | GPIO_PE5, GPIO_PE4, GPIO_PE3, GPIO_PE2, | ||
| 23 | GPIO_PE1, GPIO_PE0, | ||
| 24 | |||
| 25 | /* PF */ | ||
| 26 | GPIO_PF7, GPIO_PF6, GPIO_PF5, GPIO_PF4, | ||
| 27 | GPIO_PF3, GPIO_PF2, GPIO_PF1, GPIO_PF0, | ||
| 28 | |||
| 29 | /* PG */ | ||
| 30 | GPIO_PG7, GPIO_PG6, GPIO_PG5, GPIO_PG4, | ||
| 31 | GPIO_PG3, GPIO_PG2, GPIO_PG1, GPIO_PG0, | ||
| 32 | |||
| 33 | /* PH */ | ||
| 34 | GPIO_PH7, GPIO_PH6, GPIO_PH5, GPIO_PH4, | ||
| 35 | GPIO_PH3, GPIO_PH2, GPIO_PH1, GPIO_PH0, | ||
| 36 | |||
| 37 | /* PJ */ | ||
| 38 | GPIO_PJ7, GPIO_PJ6, GPIO_PJ5, GPIO_PJ4, | ||
| 39 | GPIO_PJ3, GPIO_PJ2, GPIO_PJ1, GPIO_PJ0, | ||
| 40 | |||
| 41 | /* PK */ | ||
| 42 | GPIO_PK7, GPIO_PK6, GPIO_PK5, GPIO_PK4, | ||
| 43 | GPIO_PK3, GPIO_PK2, GPIO_PK1, GPIO_PK0, | ||
| 44 | |||
| 45 | /* PL */ | ||
| 46 | GPIO_PL7, GPIO_PL6, GPIO_PL5, GPIO_PL4, | ||
| 47 | GPIO_PL3, GPIO_PL2, GPIO_PL1, GPIO_PL0, | ||
| 48 | |||
| 49 | /* PM */ | ||
| 50 | GPIO_PM1, GPIO_PM0, | ||
| 51 | |||
| 52 | /* PN */ | ||
| 53 | GPIO_PN7, GPIO_PN6, GPIO_PN5, GPIO_PN4, | ||
| 54 | GPIO_PN3, GPIO_PN2, GPIO_PN1, GPIO_PN0, | ||
| 55 | |||
| 56 | /* PP */ | ||
| 57 | GPIO_PP5, GPIO_PP4, | ||
| 58 | GPIO_PP3, GPIO_PP2, GPIO_PP1, GPIO_PP0, | ||
| 59 | |||
| 60 | /* PQ */ | ||
| 61 | GPIO_PQ4, | ||
| 62 | GPIO_PQ3, GPIO_PQ2, GPIO_PQ1, GPIO_PQ0, | ||
| 63 | |||
| 64 | /* PR */ | ||
| 65 | GPIO_PR3, GPIO_PR2, GPIO_PR1, GPIO_PR0, | ||
| 66 | |||
| 67 | GPIO_FN_D63_AD31, | ||
| 68 | GPIO_FN_D62_AD30, | ||
| 69 | GPIO_FN_D61_AD29, | ||
| 70 | GPIO_FN_D60_AD28, | ||
| 71 | GPIO_FN_D59_AD27, | ||
| 72 | GPIO_FN_D58_AD26, | ||
| 73 | GPIO_FN_D57_AD25, | ||
| 74 | GPIO_FN_D56_AD24, | ||
| 75 | GPIO_FN_D55_AD23, | ||
| 76 | GPIO_FN_D54_AD22, | ||
| 77 | GPIO_FN_D53_AD21, | ||
| 78 | GPIO_FN_D52_AD20, | ||
| 79 | GPIO_FN_D51_AD19, | ||
| 80 | GPIO_FN_D50_AD18, | ||
| 81 | GPIO_FN_D49_AD17_DB5, | ||
| 82 | GPIO_FN_D48_AD16_DB4, | ||
| 83 | GPIO_FN_D47_AD15_DB3, | ||
| 84 | GPIO_FN_D46_AD14_DB2, | ||
| 85 | GPIO_FN_D45_AD13_DB1, | ||
| 86 | GPIO_FN_D44_AD12_DB0, | ||
| 87 | GPIO_FN_D43_AD11_DG5, | ||
| 88 | GPIO_FN_D42_AD10_DG4, | ||
| 89 | GPIO_FN_D41_AD9_DG3, | ||
| 90 | GPIO_FN_D40_AD8_DG2, | ||
| 91 | GPIO_FN_D39_AD7_DG1, | ||
| 92 | GPIO_FN_D38_AD6_DG0, | ||
| 93 | GPIO_FN_D37_AD5_DR5, | ||
| 94 | GPIO_FN_D36_AD4_DR4, | ||
| 95 | GPIO_FN_D35_AD3_DR3, | ||
| 96 | GPIO_FN_D34_AD2_DR2, | ||
| 97 | GPIO_FN_D33_AD1_DR1, | ||
| 98 | GPIO_FN_D32_AD0_DR0, | ||
| 99 | GPIO_FN_REQ1, | ||
| 100 | GPIO_FN_REQ2, | ||
| 101 | GPIO_FN_REQ3, | ||
| 102 | GPIO_FN_GNT1, | ||
| 103 | GPIO_FN_GNT2, | ||
| 104 | GPIO_FN_GNT3, | ||
| 105 | GPIO_FN_MMCCLK, | ||
| 106 | GPIO_FN_D31, | ||
| 107 | GPIO_FN_D30, | ||
| 108 | GPIO_FN_D29, | ||
| 109 | GPIO_FN_D28, | ||
| 110 | GPIO_FN_D27, | ||
| 111 | GPIO_FN_D26, | ||
| 112 | GPIO_FN_D25, | ||
| 113 | GPIO_FN_D24, | ||
| 114 | GPIO_FN_D23, | ||
| 115 | GPIO_FN_D22, | ||
| 116 | GPIO_FN_D21, | ||
| 117 | GPIO_FN_D20, | ||
| 118 | GPIO_FN_D19, | ||
| 119 | GPIO_FN_D18, | ||
| 120 | GPIO_FN_D17, | ||
| 121 | GPIO_FN_D16, | ||
| 122 | GPIO_FN_SCIF1_SCK, | ||
| 123 | GPIO_FN_SCIF1_RXD, | ||
| 124 | GPIO_FN_SCIF1_TXD, | ||
| 125 | GPIO_FN_SCIF0_CTS, | ||
| 126 | GPIO_FN_INTD, | ||
| 127 | GPIO_FN_FCE, | ||
| 128 | GPIO_FN_SCIF0_RTS, | ||
| 129 | GPIO_FN_HSPI_CS, | ||
| 130 | GPIO_FN_FSE, | ||
| 131 | GPIO_FN_SCIF0_SCK, | ||
| 132 | GPIO_FN_HSPI_CLK, | ||
| 133 | GPIO_FN_FRE, | ||
| 134 | GPIO_FN_SCIF0_RXD, | ||
| 135 | GPIO_FN_HSPI_RX, | ||
| 136 | GPIO_FN_FRB, | ||
| 137 | GPIO_FN_SCIF0_TXD, | ||
| 138 | GPIO_FN_HSPI_TX, | ||
| 139 | GPIO_FN_FWE, | ||
| 140 | GPIO_FN_SCIF5_TXD, | ||
| 141 | GPIO_FN_HAC1_SYNC, | ||
| 142 | GPIO_FN_SSI1_WS, | ||
| 143 | GPIO_FN_SIOF_TXD_PJ, | ||
| 144 | GPIO_FN_HAC0_SDOUT, | ||
| 145 | GPIO_FN_SSI0_SDATA, | ||
| 146 | GPIO_FN_SIOF_RXD_PJ, | ||
| 147 | GPIO_FN_HAC0_SDIN, | ||
| 148 | GPIO_FN_SSI0_SCK, | ||
| 149 | GPIO_FN_SIOF_SYNC_PJ, | ||
| 150 | GPIO_FN_HAC0_SYNC, | ||
| 151 | GPIO_FN_SSI0_WS, | ||
| 152 | GPIO_FN_SIOF_MCLK_PJ, | ||
| 153 | GPIO_FN_HAC_RES, | ||
| 154 | GPIO_FN_SIOF_SCK_PJ, | ||
| 155 | GPIO_FN_HAC0_BITCLK, | ||
| 156 | GPIO_FN_SSI0_CLK, | ||
| 157 | GPIO_FN_HAC1_BITCLK, | ||
| 158 | GPIO_FN_SSI1_CLK, | ||
| 159 | GPIO_FN_TCLK, | ||
| 160 | GPIO_FN_IOIS16, | ||
| 161 | GPIO_FN_STATUS0, | ||
| 162 | GPIO_FN_DRAK0_PK3, | ||
| 163 | GPIO_FN_STATUS1, | ||
| 164 | GPIO_FN_DRAK1_PK2, | ||
| 165 | GPIO_FN_DACK2, | ||
| 166 | GPIO_FN_SCIF2_TXD, | ||
| 167 | GPIO_FN_MMCCMD, | ||
| 168 | GPIO_FN_SIOF_TXD_PK, | ||
| 169 | GPIO_FN_DACK3, | ||
| 170 | GPIO_FN_SCIF2_SCK, | ||
| 171 | GPIO_FN_MMCDAT, | ||
| 172 | GPIO_FN_SIOF_SCK_PK, | ||
| 173 | GPIO_FN_DREQ0, | ||
| 174 | GPIO_FN_DREQ1, | ||
| 175 | GPIO_FN_DRAK0_PK1, | ||
| 176 | GPIO_FN_DRAK1_PK0, | ||
| 177 | GPIO_FN_DREQ2, | ||
| 178 | GPIO_FN_INTB, | ||
| 179 | GPIO_FN_DREQ3, | ||
| 180 | GPIO_FN_INTC, | ||
| 181 | GPIO_FN_DRAK2, | ||
| 182 | GPIO_FN_CE2A, | ||
| 183 | GPIO_FN_IRL4, | ||
| 184 | GPIO_FN_FD4, | ||
| 185 | GPIO_FN_IRL5, | ||
| 186 | GPIO_FN_FD5, | ||
| 187 | GPIO_FN_IRL6, | ||
| 188 | GPIO_FN_FD6, | ||
| 189 | GPIO_FN_IRL7, | ||
| 190 | GPIO_FN_FD7, | ||
| 191 | GPIO_FN_DRAK3, | ||
| 192 | GPIO_FN_CE2B, | ||
| 193 | GPIO_FN_BREQ_BSACK, | ||
| 194 | GPIO_FN_BACK_BSREQ, | ||
| 195 | GPIO_FN_SCIF5_RXD, | ||
| 196 | GPIO_FN_HAC1_SDIN, | ||
| 197 | GPIO_FN_SSI1_SCK, | ||
| 198 | GPIO_FN_SCIF5_SCK, | ||
| 199 | GPIO_FN_HAC1_SDOUT, | ||
| 200 | GPIO_FN_SSI1_SDATA, | ||
| 201 | GPIO_FN_SCIF3_TXD, | ||
| 202 | GPIO_FN_FCLE, | ||
| 203 | GPIO_FN_SCIF3_RXD, | ||
| 204 | GPIO_FN_FALE, | ||
| 205 | GPIO_FN_SCIF3_SCK, | ||
| 206 | GPIO_FN_FD0, | ||
| 207 | GPIO_FN_SCIF4_TXD, | ||
| 208 | GPIO_FN_FD1, | ||
| 209 | GPIO_FN_SCIF4_RXD, | ||
| 210 | GPIO_FN_FD2, | ||
| 211 | GPIO_FN_SCIF4_SCK, | ||
| 212 | GPIO_FN_FD3, | ||
| 213 | GPIO_FN_DEVSEL_DCLKOUT, | ||
| 214 | GPIO_FN_STOP_CDE, | ||
| 215 | GPIO_FN_LOCK_ODDF, | ||
| 216 | GPIO_FN_TRDY_DISPL, | ||
| 217 | GPIO_FN_IRDY_HSYNC, | ||
| 218 | GPIO_FN_PCIFRAME_VSYNC, | ||
| 219 | GPIO_FN_INTA, | ||
| 220 | GPIO_FN_GNT0_GNTIN, | ||
| 221 | GPIO_FN_REQ0_REQOUT, | ||
| 222 | GPIO_FN_PERR, | ||
| 223 | GPIO_FN_SERR, | ||
| 224 | GPIO_FN_WE7_CBE3, | ||
| 225 | GPIO_FN_WE6_CBE2, | ||
| 226 | GPIO_FN_WE5_CBE1, | ||
| 227 | GPIO_FN_WE4_CBE0, | ||
| 228 | GPIO_FN_SCIF2_RXD, | ||
| 229 | GPIO_FN_SIOF_RXD, | ||
| 230 | GPIO_FN_MRESETOUT, | ||
| 231 | GPIO_FN_IRQOUT, | ||
| 232 | }; | ||
| 233 | |||
| 234 | #endif /* __ASM_SH7785_H__ */ | ||
diff --git a/arch/sh/include/mach-common/mach/highlander.h b/arch/sh/include/mach-common/mach/highlander.h index 306f7359f7d4..bd26a848cb0b 100644 --- a/arch/sh/include/mach-common/mach/highlander.h +++ b/arch/sh/include/mach-common/mach/highlander.h | |||
| @@ -195,4 +195,10 @@ | |||
| 195 | 195 | ||
| 196 | unsigned char *highlander_plat_irq_setup(void); | 196 | unsigned char *highlander_plat_irq_setup(void); |
| 197 | 197 | ||
| 198 | #ifdef CONFIG_SH_R7785RP | ||
| 199 | void highlander_plat_pinmux_setup(void); | ||
| 200 | #else | ||
| 201 | #define highlander_plat_pinmux_setup() do { } while (0) | ||
| 202 | #endif | ||
| 203 | |||
| 198 | #endif /* __ASM_SH_RENESAS_R7780RP */ | 204 | #endif /* __ASM_SH_RENESAS_R7780RP */ |
