diff options
author | Ben Dooks <ben-linux@fluff.org> | 2008-12-11 19:24:15 -0500 |
---|---|---|
committer | Ben Dooks <ben-linux@fluff.org> | 2009-03-10 12:29:11 -0400 |
commit | 333053733f52fa8c8e44c621b7b17fe5df215d4a (patch) | |
tree | 71bd5a2608f6139322614e50124a4cfbcea89825 /arch | |
parent | 5b3d515fcfe93d012107b9bd4895e2d913cbe8c3 (diff) |
[ARM] S3C64XX: Add EINT group regs and move IRQ_EINT to regs-gpio.h
Add definitions for the EINT group registers and move the EINT IRQ
register definitions out of arch/arm/plat-s3c64xx/irq-eint.c so that
they are available for re-use with PM and the other code.
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/plat-s3c64xx/include/plat/regs-gpio.h | 78 | ||||
-rw-r--r-- | arch/arm/plat-s3c64xx/irq-eint.c | 14 |
2 files changed, 61 insertions, 31 deletions
diff --git a/arch/arm/plat-s3c64xx/include/plat/regs-gpio.h b/arch/arm/plat-s3c64xx/include/plat/regs-gpio.h index 75b873d82808..51a84cd6320e 100644 --- a/arch/arm/plat-s3c64xx/include/plat/regs-gpio.h +++ b/arch/arm/plat-s3c64xx/include/plat/regs-gpio.h | |||
@@ -13,23 +13,67 @@ | |||
13 | 13 | ||
14 | /* Base addresses for each of the banks */ | 14 | /* Base addresses for each of the banks */ |
15 | 15 | ||
16 | #define S3C64XX_GPA_BASE (S3C64XX_VA_GPIO + 0x0000) | 16 | #define S3C64XX_GPIOREG(reg) (S3C64XX_VA_GPIO + (reg)) |
17 | #define S3C64XX_GPB_BASE (S3C64XX_VA_GPIO + 0x0020) | 17 | |
18 | #define S3C64XX_GPC_BASE (S3C64XX_VA_GPIO + 0x0040) | 18 | #define S3C64XX_GPA_BASE S3C64XX_GPIOREG(0x0000) |
19 | #define S3C64XX_GPD_BASE (S3C64XX_VA_GPIO + 0x0060) | 19 | #define S3C64XX_GPB_BASE S3C64XX_GPIOREG(0x0020) |
20 | #define S3C64XX_GPE_BASE (S3C64XX_VA_GPIO + 0x0080) | 20 | #define S3C64XX_GPC_BASE S3C64XX_GPIOREG(0x0040) |
21 | #define S3C64XX_GPF_BASE (S3C64XX_VA_GPIO + 0x00A0) | 21 | #define S3C64XX_GPD_BASE S3C64XX_GPIOREG(0x0060) |
22 | #define S3C64XX_GPG_BASE (S3C64XX_VA_GPIO + 0x00C0) | 22 | #define S3C64XX_GPE_BASE S3C64XX_GPIOREG(0x0080) |
23 | #define S3C64XX_GPH_BASE (S3C64XX_VA_GPIO + 0x00E0) | 23 | #define S3C64XX_GPF_BASE S3C64XX_GPIOREG(0x00A0) |
24 | #define S3C64XX_GPI_BASE (S3C64XX_VA_GPIO + 0x0100) | 24 | #define S3C64XX_GPG_BASE S3C64XX_GPIOREG(0x00C0) |
25 | #define S3C64XX_GPJ_BASE (S3C64XX_VA_GPIO + 0x0120) | 25 | #define S3C64XX_GPH_BASE S3C64XX_GPIOREG(0x00E0) |
26 | #define S3C64XX_GPK_BASE (S3C64XX_VA_GPIO + 0x0800) | 26 | #define S3C64XX_GPI_BASE S3C64XX_GPIOREG(0x0100) |
27 | #define S3C64XX_GPL_BASE (S3C64XX_VA_GPIO + 0x0810) | 27 | #define S3C64XX_GPJ_BASE S3C64XX_GPIOREG(0x0120) |
28 | #define S3C64XX_GPM_BASE (S3C64XX_VA_GPIO + 0x0820) | 28 | #define S3C64XX_GPK_BASE S3C64XX_GPIOREG(0x0800) |
29 | #define S3C64XX_GPN_BASE (S3C64XX_VA_GPIO + 0x0830) | 29 | #define S3C64XX_GPL_BASE S3C64XX_GPIOREG(0x0810) |
30 | #define S3C64XX_GPO_BASE (S3C64XX_VA_GPIO + 0x0140) | 30 | #define S3C64XX_GPM_BASE S3C64XX_GPIOREG(0x0820) |
31 | #define S3C64XX_GPP_BASE (S3C64XX_VA_GPIO + 0x0160) | 31 | #define S3C64XX_GPN_BASE S3C64XX_GPIOREG(0x0830) |
32 | #define S3C64XX_GPQ_BASE (S3C64XX_VA_GPIO + 0x0180) | 32 | #define S3C64XX_GPO_BASE S3C64XX_GPIOREG(0x0140) |
33 | #define S3C64XX_GPP_BASE S3C64XX_GPIOREG(0x0160) | ||
34 | #define S3C64XX_GPQ_BASE S3C64XX_GPIOREG(0x0180) | ||
35 | |||
36 | /* External interrupt registers */ | ||
37 | |||
38 | #define S3C64XX_EINT12CON S3C64XX_GPIOREG(0x200) | ||
39 | #define S3C64XX_EINT34CON S3C64XX_GPIOREG(0x204) | ||
40 | #define S3C64XX_EINT56CON S3C64XX_GPIOREG(0x208) | ||
41 | #define S3C64XX_EINT78CON S3C64XX_GPIOREG(0x20C) | ||
42 | #define S3C64XX_EINT9CON S3C64XX_GPIOREG(0x210) | ||
43 | |||
44 | #define S3C64XX_EINT12FLTCON S3C64XX_GPIOREG(0x220) | ||
45 | #define S3C64XX_EINT34FLTCON S3C64XX_GPIOREG(0x224) | ||
46 | #define S3C64XX_EINT56FLTCON S3C64XX_GPIOREG(0x228) | ||
47 | #define S3C64XX_EINT78FLTCON S3C64XX_GPIOREG(0x22C) | ||
48 | #define S3C64XX_EINT9FLTCON S3C64XX_GPIOREG(0x230) | ||
49 | |||
50 | #define S3C64XX_EINT12MASK S3C64XX_GPIOREG(0x240) | ||
51 | #define S3C64XX_EINT34MASK S3C64XX_GPIOREG(0x244) | ||
52 | #define S3C64XX_EINT56MASK S3C64XX_GPIOREG(0x248) | ||
53 | #define S3C64XX_EINT78MASK S3C64XX_GPIOREG(0x24C) | ||
54 | #define S3C64XX_EINT9MASK S3C64XX_GPIOREG(0x250) | ||
55 | |||
56 | #define S3C64XX_EINT12PEND S3C64XX_GPIOREG(0x260) | ||
57 | #define S3C64XX_EINT34PEND S3C64XX_GPIOREG(0x264) | ||
58 | #define S3C64XX_EINT56PEND S3C64XX_GPIOREG(0x268) | ||
59 | #define S3C64XX_EINT78PEND S3C64XX_GPIOREG(0x26C) | ||
60 | #define S3C64XX_EINT9PEND S3C64XX_GPIOREG(0x270) | ||
61 | |||
62 | #define S3C64XX_PRIORITY S3C64XX_GPIOREG(0x280) | ||
63 | #define S3C64XX_PRIORITY_ARB(x) (1 << (x)) | ||
64 | |||
65 | #define S3C64XX_SERVICE S3C64XX_GPIOREG(0x284) | ||
66 | #define S3C64XX_SERVICEPEND S3C64XX_GPIOREG(0x288) | ||
67 | |||
68 | #define S3C64XX_EINT0CON0 S3C64XX_GPIOREG(0x900) | ||
69 | #define S3C64XX_EINT0CON1 S3C64XX_GPIOREG(0x904) | ||
70 | #define S3C64XX_EINT0FLTCON0 S3C64XX_GPIOREG(0x910) | ||
71 | #define S3C64XX_EINT0FLTCON1 S3C64XX_GPIOREG(0x914) | ||
72 | #define S3C64XX_EINT0FLTCON2 S3C64XX_GPIOREG(0x918) | ||
73 | #define S3C64XX_EINT0FLTCON3 S3C64XX_GPIOREG(0x91C) | ||
74 | |||
75 | #define S3C64XX_EINT0MASK S3C64XX_GPIOREG(0x920) | ||
76 | #define S3C64XX_EINT0PEND S3C64XX_GPIOREG(0x924) | ||
33 | 77 | ||
34 | #endif /* __ASM_PLAT_S3C64XX_REGS_GPIO_H */ | 78 | #endif /* __ASM_PLAT_S3C64XX_REGS_GPIO_H */ |
35 | 79 | ||
diff --git a/arch/arm/plat-s3c64xx/irq-eint.c b/arch/arm/plat-s3c64xx/irq-eint.c index cf524826c93a..47e5155bb13e 100644 --- a/arch/arm/plat-s3c64xx/irq-eint.c +++ b/arch/arm/plat-s3c64xx/irq-eint.c | |||
@@ -27,20 +27,6 @@ | |||
27 | #include <mach/map.h> | 27 | #include <mach/map.h> |
28 | #include <plat/cpu.h> | 28 | #include <plat/cpu.h> |
29 | 29 | ||
30 | /* GPIO is 0x7F008xxx, */ | ||
31 | #define S3C64XX_GPIOREG(x) (S3C64XX_VA_GPIO + (x)) | ||
32 | |||
33 | #define S3C64XX_EINT0CON0 S3C64XX_GPIOREG(0x900) | ||
34 | #define S3C64XX_EINT0CON1 S3C64XX_GPIOREG(0x904) | ||
35 | #define S3C64XX_EINT0FLTCON0 S3C64XX_GPIOREG(0x910) | ||
36 | #define S3C64XX_EINT0FLTCON1 S3C64XX_GPIOREG(0x914) | ||
37 | #define S3C64XX_EINT0FLTCON2 S3C64XX_GPIOREG(0x918) | ||
38 | #define S3C64XX_EINT0FLTCON3 S3C64XX_GPIOREG(0x91C) | ||
39 | |||
40 | #define S3C64XX_EINT0MASK S3C64XX_GPIOREG(0x920) | ||
41 | #define S3C64XX_EINT0PEND S3C64XX_GPIOREG(0x924) | ||
42 | |||
43 | |||
44 | #define eint_offset(irq) ((irq) - IRQ_EINT(0)) | 30 | #define eint_offset(irq) ((irq) - IRQ_EINT(0)) |
45 | #define eint_irq_to_bit(irq) (1 << eint_offset(irq)) | 31 | #define eint_irq_to_bit(irq) (1 << eint_offset(irq)) |
46 | 32 | ||