diff options
Diffstat (limited to 'arch/arm/mach-mmp/include')
-rw-r--r-- | arch/arm/mach-mmp/include/mach/gpio-pxa.h | 3 | ||||
-rw-r--r-- | arch/arm/mach-mmp/include/mach/gpio.h | 7 | ||||
-rw-r--r-- | arch/arm/mach-mmp/include/mach/irqs.h | 6 | ||||
-rw-r--r-- | arch/arm/mach-mmp/include/mach/mmp2.h | 2 | ||||
-rw-r--r-- | arch/arm/mach-mmp/include/mach/pxa168.h | 2 | ||||
-rw-r--r-- | arch/arm/mach-mmp/include/mach/pxa910.h | 2 |
6 files changed, 11 insertions, 11 deletions
diff --git a/arch/arm/mach-mmp/include/mach/gpio-pxa.h b/arch/arm/mach-mmp/include/mach/gpio-pxa.h index 99b4ce1b656..0e135a599f3 100644 --- a/arch/arm/mach-mmp/include/mach/gpio-pxa.h +++ b/arch/arm/mach-mmp/include/mach/gpio-pxa.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define __ASM_MACH_GPIO_PXA_H | 2 | #define __ASM_MACH_GPIO_PXA_H |
3 | 3 | ||
4 | #include <mach/addr-map.h> | 4 | #include <mach/addr-map.h> |
5 | #include <mach/cputype.h> | ||
5 | #include <mach/irqs.h> | 6 | #include <mach/irqs.h> |
6 | 7 | ||
7 | #define GPIO_REGS_VIRT (APB_VIRT_BASE + 0x19000) | 8 | #define GPIO_REGS_VIRT (APB_VIRT_BASE + 0x19000) |
@@ -9,8 +10,6 @@ | |||
9 | #define BANK_OFF(n) (((n) < 3) ? (n) << 2 : 0x100 + (((n) - 3) << 2)) | 10 | #define BANK_OFF(n) (((n) < 3) ? (n) << 2 : 0x100 + (((n) - 3) << 2)) |
10 | #define GPIO_REG(x) (*(volatile u32 *)(GPIO_REGS_VIRT + (x))) | 11 | #define GPIO_REG(x) (*(volatile u32 *)(GPIO_REGS_VIRT + (x))) |
11 | 12 | ||
12 | #define NR_BUILTIN_GPIO IRQ_GPIO_NUM | ||
13 | |||
14 | #define gpio_to_bank(gpio) ((gpio) >> 5) | 13 | #define gpio_to_bank(gpio) ((gpio) >> 5) |
15 | 14 | ||
16 | /* NOTE: these macros are defined here to make optimization of | 15 | /* NOTE: these macros are defined here to make optimization of |
diff --git a/arch/arm/mach-mmp/include/mach/gpio.h b/arch/arm/mach-mmp/include/mach/gpio.h index 681262359d1..13219ebf512 100644 --- a/arch/arm/mach-mmp/include/mach/gpio.h +++ b/arch/arm/mach-mmp/include/mach/gpio.h | |||
@@ -3,11 +3,6 @@ | |||
3 | 3 | ||
4 | #include <asm-generic/gpio.h> | 4 | #include <asm-generic/gpio.h> |
5 | 5 | ||
6 | #define gpio_to_irq(gpio) (IRQ_GPIO_START + (gpio)) | 6 | #include <mach/cputype.h> |
7 | #define irq_to_gpio(irq) ((irq) - IRQ_GPIO_START) | ||
8 | 7 | ||
9 | #define __gpio_is_inverted(gpio) (0) | ||
10 | #define __gpio_is_occupied(gpio) (0) | ||
11 | |||
12 | #include <plat/gpio.h> | ||
13 | #endif /* __ASM_MACH_GPIO_H */ | 8 | #endif /* __ASM_MACH_GPIO_H */ |
diff --git a/arch/arm/mach-mmp/include/mach/irqs.h b/arch/arm/mach-mmp/include/mach/irqs.h index a09d328e2dd..34635a0bbb5 100644 --- a/arch/arm/mach-mmp/include/mach/irqs.h +++ b/arch/arm/mach-mmp/include/mach/irqs.h | |||
@@ -219,10 +219,10 @@ | |||
219 | #define IRQ_MMP2_MUX_END (IRQ_MMP2_SSP_BASE + 2) | 219 | #define IRQ_MMP2_MUX_END (IRQ_MMP2_SSP_BASE + 2) |
220 | 220 | ||
221 | #define IRQ_GPIO_START 128 | 221 | #define IRQ_GPIO_START 128 |
222 | #define IRQ_GPIO_NUM 192 | 222 | #define MMP_NR_BUILTIN_GPIO 192 |
223 | #define IRQ_GPIO(x) (IRQ_GPIO_START + (x)) | 223 | #define MMP_GPIO_TO_IRQ(gpio) (IRQ_GPIO_START + (gpio)) |
224 | 224 | ||
225 | #define IRQ_BOARD_START (IRQ_GPIO_START + IRQ_GPIO_NUM) | 225 | #define IRQ_BOARD_START (IRQ_GPIO_START + MMP_NR_BUILTIN_GPIO) |
226 | 226 | ||
227 | #define NR_IRQS (IRQ_BOARD_START) | 227 | #define NR_IRQS (IRQ_BOARD_START) |
228 | 228 | ||
diff --git a/arch/arm/mach-mmp/include/mach/mmp2.h b/arch/arm/mach-mmp/include/mach/mmp2.h index 2f7b2d3c2b1..cba22fed226 100644 --- a/arch/arm/mach-mmp/include/mach/mmp2.h +++ b/arch/arm/mach-mmp/include/mach/mmp2.h | |||
@@ -32,6 +32,8 @@ extern struct pxa_device_desc mmp2_device_sdh3; | |||
32 | extern struct pxa_device_desc mmp2_device_asram; | 32 | extern struct pxa_device_desc mmp2_device_asram; |
33 | extern struct pxa_device_desc mmp2_device_isram; | 33 | extern struct pxa_device_desc mmp2_device_isram; |
34 | 34 | ||
35 | extern struct platform_device mmp2_device_gpio; | ||
36 | |||
35 | static inline int mmp2_add_uart(int id) | 37 | static inline int mmp2_add_uart(int id) |
36 | { | 38 | { |
37 | struct pxa_device_desc *d = NULL; | 39 | struct pxa_device_desc *d = NULL; |
diff --git a/arch/arm/mach-mmp/include/mach/pxa168.h b/arch/arm/mach-mmp/include/mach/pxa168.h index a677aa732c2..dc03d580a06 100644 --- a/arch/arm/mach-mmp/include/mach/pxa168.h +++ b/arch/arm/mach-mmp/include/mach/pxa168.h | |||
@@ -43,6 +43,8 @@ struct pxa168_usb_pdata { | |||
43 | /* pdata can be NULL */ | 43 | /* pdata can be NULL */ |
44 | int __init pxa168_add_usb_host(struct pxa168_usb_pdata *pdata); | 44 | int __init pxa168_add_usb_host(struct pxa168_usb_pdata *pdata); |
45 | 45 | ||
46 | extern struct platform_device pxa168_device_gpio; | ||
47 | |||
46 | static inline int pxa168_add_uart(int id) | 48 | static inline int pxa168_add_uart(int id) |
47 | { | 49 | { |
48 | struct pxa_device_desc *d = NULL; | 50 | struct pxa_device_desc *d = NULL; |
diff --git a/arch/arm/mach-mmp/include/mach/pxa910.h b/arch/arm/mach-mmp/include/mach/pxa910.h index 91be7559139..4de13abef7b 100644 --- a/arch/arm/mach-mmp/include/mach/pxa910.h +++ b/arch/arm/mach-mmp/include/mach/pxa910.h | |||
@@ -21,6 +21,8 @@ extern struct pxa_device_desc pxa910_device_pwm3; | |||
21 | extern struct pxa_device_desc pxa910_device_pwm4; | 21 | extern struct pxa_device_desc pxa910_device_pwm4; |
22 | extern struct pxa_device_desc pxa910_device_nand; | 22 | extern struct pxa_device_desc pxa910_device_nand; |
23 | 23 | ||
24 | extern struct platform_device pxa910_device_gpio; | ||
25 | |||
24 | static inline int pxa910_add_uart(int id) | 26 | static inline int pxa910_add_uart(int id) |
25 | { | 27 | { |
26 | struct pxa_device_desc *d = NULL; | 28 | struct pxa_device_desc *d = NULL; |