diff options
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-s3c2410/include/mach/gpio-nrs.h | 23 | ||||
-rw-r--r-- | arch/arm/mach-s3c2410/include/mach/gpio.h | 3 | ||||
-rw-r--r-- | arch/arm/mach-s3c2410/include/mach/regs-gpio.h | 11 |
3 files changed, 27 insertions, 10 deletions
diff --git a/arch/arm/mach-s3c2410/include/mach/gpio-nrs.h b/arch/arm/mach-s3c2410/include/mach/gpio-nrs.h new file mode 100644 index 000000000000..ce1ec69806a1 --- /dev/null +++ b/arch/arm/mach-s3c2410/include/mach/gpio-nrs.h | |||
@@ -0,0 +1,23 @@ | |||
1 | /* arch/arm/mach-s3c2410/include/mach/gpio-nrs.h | ||
2 | * | ||
3 | * Copyright (c) 2008 Simtec Electronics | ||
4 | * http://armlinux.simtec.co.uk/ | ||
5 | * Ben Dooks <ben@simtec.co.uk> | ||
6 | * | ||
7 | * S3C2410 - GPIO bank numbering | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License version 2 as | ||
11 | * published by the Free Software Foundation. | ||
12 | */ | ||
13 | |||
14 | #define S3C2410_GPIONO(bank,offset) ((bank) + (offset)) | ||
15 | |||
16 | #define S3C2410_GPIO_BANKA (32*0) | ||
17 | #define S3C2410_GPIO_BANKB (32*1) | ||
18 | #define S3C2410_GPIO_BANKC (32*2) | ||
19 | #define S3C2410_GPIO_BANKD (32*3) | ||
20 | #define S3C2410_GPIO_BANKE (32*4) | ||
21 | #define S3C2410_GPIO_BANKF (32*5) | ||
22 | #define S3C2410_GPIO_BANKG (32*6) | ||
23 | #define S3C2410_GPIO_BANKH (32*7) | ||
diff --git a/arch/arm/mach-s3c2410/include/mach/gpio.h b/arch/arm/mach-s3c2410/include/mach/gpio.h index 00476a573bbe..51a88cf9526b 100644 --- a/arch/arm/mach-s3c2410/include/mach/gpio.h +++ b/arch/arm/mach-s3c2410/include/mach/gpio.h | |||
@@ -23,3 +23,6 @@ | |||
23 | #define ARCH_NR_GPIOS (256 + CONFIG_S3C24XX_GPIO_EXTRA) | 23 | #define ARCH_NR_GPIOS (256 + CONFIG_S3C24XX_GPIO_EXTRA) |
24 | 24 | ||
25 | #include <asm-generic/gpio.h> | 25 | #include <asm-generic/gpio.h> |
26 | #include <mach/gpio-nrs.h> | ||
27 | |||
28 | #define S3C_GPIO_END (S3C2410_GPIO_BANKH + 32) | ||
diff --git a/arch/arm/mach-s3c2410/include/mach/regs-gpio.h b/arch/arm/mach-s3c2410/include/mach/regs-gpio.h index 321077613067..35a03df473fc 100644 --- a/arch/arm/mach-s3c2410/include/mach/regs-gpio.h +++ b/arch/arm/mach-s3c2410/include/mach/regs-gpio.h | |||
@@ -14,16 +14,7 @@ | |||
14 | #ifndef __ASM_ARCH_REGS_GPIO_H | 14 | #ifndef __ASM_ARCH_REGS_GPIO_H |
15 | #define __ASM_ARCH_REGS_GPIO_H | 15 | #define __ASM_ARCH_REGS_GPIO_H |
16 | 16 | ||
17 | #define S3C2410_GPIONO(bank,offset) ((bank) + (offset)) | 17 | #include <mach/gpio-nrs.h> |
18 | |||
19 | #define S3C2410_GPIO_BANKA (32*0) | ||
20 | #define S3C2410_GPIO_BANKB (32*1) | ||
21 | #define S3C2410_GPIO_BANKC (32*2) | ||
22 | #define S3C2410_GPIO_BANKD (32*3) | ||
23 | #define S3C2410_GPIO_BANKE (32*4) | ||
24 | #define S3C2410_GPIO_BANKF (32*5) | ||
25 | #define S3C2410_GPIO_BANKG (32*6) | ||
26 | #define S3C2410_GPIO_BANKH (32*7) | ||
27 | 18 | ||
28 | #ifdef CONFIG_CPU_S3C2400 | 19 | #ifdef CONFIG_CPU_S3C2400 |
29 | #define S3C24XX_GPIO_BASE(x) S3C2400_GPIO_BASE(x) | 20 | #define S3C24XX_GPIO_BASE(x) S3C2400_GPIO_BASE(x) |