diff options
author | Dmitry Baryshkov <dbaryshkov@gmail.com> | 2008-06-14 06:42:02 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-07-07 08:22:02 -0400 |
commit | bf0116e54e185fd63025f2b975f0f1616ffe41f1 (patch) | |
tree | 75a5f8c22d438e3d8d3c06b5f3d0639b1ee04d1d /include/asm-arm | |
parent | d6315949ac5527efd00d48283a9e33361c86e8e9 (diff) |
[ARM] 5097/1: Tosa: support TC6393XB device
Add definitions for Toshiba TC6393XB companion chip and register
the tc6393xb device.
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'include/asm-arm')
-rw-r--r-- | include/asm-arm/arch-pxa/irqs.h | 1 | ||||
-rw-r--r-- | include/asm-arm/arch-pxa/tosa.h | 44 |
2 files changed, 31 insertions, 14 deletions
diff --git a/include/asm-arm/arch-pxa/irqs.h b/include/asm-arm/arch-pxa/irqs.h index b6c8fe377683..fa05e76f64e8 100644 --- a/include/asm-arm/arch-pxa/irqs.h +++ b/include/asm-arm/arch-pxa/irqs.h | |||
@@ -180,6 +180,7 @@ | |||
180 | #define NR_IRQS (IRQ_LOCOMO_SPI_TEND + 1) | 180 | #define NR_IRQS (IRQ_LOCOMO_SPI_TEND + 1) |
181 | #elif defined(CONFIG_ARCH_LUBBOCK) || \ | 181 | #elif defined(CONFIG_ARCH_LUBBOCK) || \ |
182 | defined(CONFIG_MACH_LOGICPD_PXA270) || \ | 182 | defined(CONFIG_MACH_LOGICPD_PXA270) || \ |
183 | defined(CONFIG_MACH_TOSA) || \ | ||
183 | defined(CONFIG_MACH_MAINSTONE) || \ | 184 | defined(CONFIG_MACH_MAINSTONE) || \ |
184 | defined(CONFIG_MACH_PCM027) || \ | 185 | defined(CONFIG_MACH_PCM027) || \ |
185 | defined(CONFIG_MACH_MAGICIAN) | 186 | defined(CONFIG_MACH_MAGICIAN) |
diff --git a/include/asm-arm/arch-pxa/tosa.h b/include/asm-arm/arch-pxa/tosa.h index 188226216154..a16c103b7251 100644 --- a/include/asm-arm/arch-pxa/tosa.h +++ b/include/asm-arm/arch-pxa/tosa.h | |||
@@ -25,7 +25,7 @@ | |||
25 | */ | 25 | */ |
26 | #define TOSA_SCOOP_GPIO_BASE NR_BUILTIN_GPIO | 26 | #define TOSA_SCOOP_GPIO_BASE NR_BUILTIN_GPIO |
27 | #define TOSA_SCOOP_PXA_VCORE1 SCOOP_GPCR_PA11 | 27 | #define TOSA_SCOOP_PXA_VCORE1 SCOOP_GPCR_PA11 |
28 | #define TOSA_SCOOP_TC6393_REST_IN SCOOP_GPCR_PA12 | 28 | #define TOSA_GPIO_TC6393XB_REST_IN (TOSA_SCOOP_GPIO_BASE + 1) |
29 | #define TOSA_GPIO_IR_POWERDWN (TOSA_SCOOP_GPIO_BASE + 2) | 29 | #define TOSA_GPIO_IR_POWERDWN (TOSA_SCOOP_GPIO_BASE + 2) |
30 | #define TOSA_GPIO_SD_WP (TOSA_SCOOP_GPIO_BASE + 3) | 30 | #define TOSA_GPIO_SD_WP (TOSA_SCOOP_GPIO_BASE + 3) |
31 | #define TOSA_GPIO_PWR_ON (TOSA_SCOOP_GPIO_BASE + 4) | 31 | #define TOSA_GPIO_PWR_ON (TOSA_SCOOP_GPIO_BASE + 4) |
@@ -35,11 +35,9 @@ | |||
35 | #define TOSA_SCOOP_AC_IN_OL SCOOP_GPCR_PA19 | 35 | #define TOSA_SCOOP_AC_IN_OL SCOOP_GPCR_PA19 |
36 | 36 | ||
37 | /* GPIO Direction 1 : output mode / 0:input mode */ | 37 | /* GPIO Direction 1 : output mode / 0:input mode */ |
38 | #define TOSA_SCOOP_IO_DIR ( TOSA_SCOOP_PXA_VCORE1 | TOSA_SCOOP_TC6393_REST_IN | \ | 38 | #define TOSA_SCOOP_IO_DIR (TOSA_SCOOP_PXA_VCORE1 | \ |
39 | TOSA_SCOOP_AUD_PWR_ON |\ | 39 | TOSA_SCOOP_AUD_PWR_ON |\ |
40 | TOSA_SCOOP_BT_RESET | TOSA_SCOOP_BT_PWR_EN ) | 40 | TOSA_SCOOP_BT_RESET | TOSA_SCOOP_BT_PWR_EN) |
41 | /* GPIO out put level when init 1: Hi */ | ||
42 | #define TOSA_SCOOP_IO_OUT ( TOSA_SCOOP_TC6393_REST_IN ) | ||
43 | 41 | ||
44 | /* | 42 | /* |
45 | * SCOOP2 jacket GPIOs | 43 | * SCOOP2 jacket GPIOs |
@@ -49,16 +47,34 @@ | |||
49 | #define TOSA_GPIO_NOTE_LED (TOSA_SCOOP_JC_GPIO_BASE + 1) | 47 | #define TOSA_GPIO_NOTE_LED (TOSA_SCOOP_JC_GPIO_BASE + 1) |
50 | #define TOSA_GPIO_CHRG_ERR_LED (TOSA_SCOOP_JC_GPIO_BASE + 2) | 48 | #define TOSA_GPIO_CHRG_ERR_LED (TOSA_SCOOP_JC_GPIO_BASE + 2) |
51 | #define TOSA_GPIO_USB_PULLUP (TOSA_SCOOP_JC_GPIO_BASE + 3) | 49 | #define TOSA_GPIO_USB_PULLUP (TOSA_SCOOP_JC_GPIO_BASE + 3) |
52 | #define TOSA_SCOOP_JC_TC6393_SUSPEND SCOOP_GPCR_PA15 | 50 | #define TOSA_GPIO_TC6393XB_SUSPEND (TOSA_SCOOP_JC_GPIO_BASE + 4) |
53 | #define TOSA_SCOOP_JC_TC3693_L3V_ON SCOOP_GPCR_PA16 | 51 | #define TOSA_GPIO_TC6393XB_L3V_ON (TOSA_SCOOP_JC_GPIO_BASE + 5) |
54 | #define TOSA_SCOOP_JC_WLAN_DETECT SCOOP_GPCR_PA17 | 52 | #define TOSA_SCOOP_JC_WLAN_DETECT SCOOP_GPCR_PA17 |
55 | #define TOSA_GPIO_WLAN_LED (TOSA_SCOOP_JC_GPIO_BASE + 7) | 53 | #define TOSA_GPIO_WLAN_LED (TOSA_SCOOP_JC_GPIO_BASE + 7) |
56 | #define TOSA_SCOOP_JC_CARD_LIMIT_SEL SCOOP_GPCR_PA19 | 54 | #define TOSA_SCOOP_JC_CARD_LIMIT_SEL SCOOP_GPCR_PA19 |
57 | 55 | ||
58 | /* GPIO Direction 1 : output mode / 0:input mode */ | 56 | /* GPIO Direction 1 : output mode / 0:input mode */ |
59 | #define TOSA_SCOOP_JC_IO_DIR ( \ | 57 | #define TOSA_SCOOP_JC_IO_DIR (TOSA_SCOOP_JC_CARD_LIMIT_SEL) |
60 | TOSA_SCOOP_JC_TC6393_SUSPEND | TOSA_SCOOP_JC_TC3693_L3V_ON | \ | 58 | |
61 | TOSA_SCOOP_JC_CARD_LIMIT_SEL ) | 59 | /* |
60 | * TC6393XB GPIOs | ||
61 | */ | ||
62 | #define TOSA_TC6393XB_GPIO_BASE (NR_BUILTIN_GPIO + 2 * 12) | ||
63 | #define TOSA_TC6393XB_GPIO(i) (TOSA_TC6393XB_GPIO_BASE + (i)) | ||
64 | #define TOSA_TC6393XB_GPIO_BIT(gpio) (1 << (gpio - TOSA_TC6393XB_GPIO_BASE)) | ||
65 | |||
66 | #define TOSA_GPIO_TG_ON (TOSA_TC6393XB_GPIO_BASE + 0) | ||
67 | #define TOSA_GPIO_L_MUTE (TOSA_TC6393XB_GPIO_BASE + 1) | ||
68 | #define TOSA_GPIO_BL_C20MA (TOSA_TC6393XB_GPIO_BASE + 3) | ||
69 | #define TOSA_GPIO_CARD_VCC_ON (TOSA_TC6393XB_GPIO_BASE + 4) | ||
70 | #define TOSA_GPIO_CHARGE_OFF (TOSA_TC6393XB_GPIO_BASE + 6) | ||
71 | #define TOSA_GPIO_CHARGE_OFF_JC (TOSA_TC6393XB_GPIO_BASE + 7) | ||
72 | #define TOSA_GPIO_BAT0_V_ON (TOSA_TC6393XB_GPIO_BASE + 9) | ||
73 | #define TOSA_GPIO_BAT1_V_ON (TOSA_TC6393XB_GPIO_BASE + 10) | ||
74 | #define TOSA_GPIO_BU_CHRG_ON (TOSA_TC6393XB_GPIO_BASE + 11) | ||
75 | #define TOSA_GPIO_BAT_SW_ON (TOSA_TC6393XB_GPIO_BASE + 12) | ||
76 | #define TOSA_GPIO_BAT0_TH_ON (TOSA_TC6393XB_GPIO_BASE + 14) | ||
77 | #define TOSA_GPIO_BAT1_TH_ON (TOSA_TC6393XB_GPIO_BASE + 15) | ||
62 | 78 | ||
63 | /* | 79 | /* |
64 | * Timing Generator | 80 | * Timing Generator |
@@ -84,13 +100,13 @@ | |||
84 | #define TOSA_GPIO_JACKET_DETECT (7) | 100 | #define TOSA_GPIO_JACKET_DETECT (7) |
85 | #define TOSA_GPIO_nSD_DETECT (9) | 101 | #define TOSA_GPIO_nSD_DETECT (9) |
86 | #define TOSA_GPIO_nSD_INT (10) | 102 | #define TOSA_GPIO_nSD_INT (10) |
87 | #define TOSA_GPIO_TC6393_CLK (11) | 103 | #define TOSA_GPIO_TC6393XB_CLK (11) |
88 | #define TOSA_GPIO_BAT1_CRG (12) | 104 | #define TOSA_GPIO_BAT1_CRG (12) |
89 | #define TOSA_GPIO_CF_CD (13) | 105 | #define TOSA_GPIO_CF_CD (13) |
90 | #define TOSA_GPIO_BAT0_CRG (14) | 106 | #define TOSA_GPIO_BAT0_CRG (14) |
91 | #define TOSA_GPIO_TC6393_INT (15) | 107 | #define TOSA_GPIO_TC6393XB_INT (15) |
92 | #define TOSA_GPIO_BAT0_LOW (17) | 108 | #define TOSA_GPIO_BAT0_LOW (17) |
93 | #define TOSA_GPIO_TC6393_RDY (18) | 109 | #define TOSA_GPIO_TC6393XB_RDY (18) |
94 | #define TOSA_GPIO_ON_RESET (19) | 110 | #define TOSA_GPIO_ON_RESET (19) |
95 | #define TOSA_GPIO_EAR_IN (20) | 111 | #define TOSA_GPIO_EAR_IN (20) |
96 | #define TOSA_GPIO_CF_IRQ (21) /* CF slot0 Ready */ | 112 | #define TOSA_GPIO_CF_IRQ (21) /* CF slot0 Ready */ |
@@ -138,7 +154,7 @@ | |||
138 | #define TOSA_IRQ_GPIO_BAT1_CRG IRQ_GPIO(TOSA_GPIO_BAT1_CRG) | 154 | #define TOSA_IRQ_GPIO_BAT1_CRG IRQ_GPIO(TOSA_GPIO_BAT1_CRG) |
139 | #define TOSA_IRQ_GPIO_CF_CD IRQ_GPIO(TOSA_GPIO_CF_CD) | 155 | #define TOSA_IRQ_GPIO_CF_CD IRQ_GPIO(TOSA_GPIO_CF_CD) |
140 | #define TOSA_IRQ_GPIO_BAT0_CRG IRQ_GPIO(TOSA_GPIO_BAT0_CRG) | 156 | #define TOSA_IRQ_GPIO_BAT0_CRG IRQ_GPIO(TOSA_GPIO_BAT0_CRG) |
141 | #define TOSA_IRQ_GPIO_TC6393_INT IRQ_GPIO(TOSA_GPIO_TC6393_INT) | 157 | #define TOSA_IRQ_GPIO_TC6393XB_INT IRQ_GPIO(TOSA_GPIO_TC6393XB_INT) |
142 | #define TOSA_IRQ_GPIO_BAT0_LOW IRQ_GPIO(TOSA_GPIO_BAT0_LOW) | 158 | #define TOSA_IRQ_GPIO_BAT0_LOW IRQ_GPIO(TOSA_GPIO_BAT0_LOW) |
143 | #define TOSA_IRQ_GPIO_EAR_IN IRQ_GPIO(TOSA_GPIO_EAR_IN) | 159 | #define TOSA_IRQ_GPIO_EAR_IN IRQ_GPIO(TOSA_GPIO_EAR_IN) |
144 | #define TOSA_IRQ_GPIO_CF_IRQ IRQ_GPIO(TOSA_GPIO_CF_IRQ) | 160 | #define TOSA_IRQ_GPIO_CF_IRQ IRQ_GPIO(TOSA_GPIO_CF_IRQ) |