diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2013-08-26 04:52:23 -0400 |
---|---|---|
committer | Simon Horman <horms+renesas@verge.net.au> | 2013-09-30 03:34:07 -0400 |
commit | 71d7472f63385f4f6fb7c8548450b2e4665dc542 (patch) | |
tree | 3df47154f139cbfedbdf704e56cb36bee04773eb /arch/arm/mach-shmobile | |
parent | 37bf8103c51a1508d6323de19a7ae1c13c3ed3f5 (diff) |
ARM: shmobile: bockw: enable global use of FPGA
This patch enables global use of FPGA,
since it will be used from many devices.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Diffstat (limited to 'arch/arm/mach-shmobile')
-rw-r--r-- | arch/arm/mach-shmobile/board-bockw.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/arch/arm/mach-shmobile/board-bockw.c b/arch/arm/mach-shmobile/board-bockw.c index 6b9faf3908f7..b998c6b2a270 100644 --- a/arch/arm/mach-shmobile/board-bockw.c +++ b/arch/arm/mach-shmobile/board-bockw.c | |||
@@ -38,6 +38,10 @@ | |||
38 | #include <mach/r8a7778.h> | 38 | #include <mach/r8a7778.h> |
39 | #include <asm/mach/arch.h> | 39 | #include <asm/mach/arch.h> |
40 | 40 | ||
41 | #define FPGA 0x18200000 | ||
42 | #define IRQ0MR 0x30 | ||
43 | static void __iomem *fpga; | ||
44 | |||
41 | /* | 45 | /* |
42 | * CN9(Upper side) SCIF/RCAN selection | 46 | * CN9(Upper side) SCIF/RCAN selection |
43 | * | 47 | * |
@@ -224,8 +228,6 @@ static const struct pinctrl_map bockw_pinctrl_map[] = { | |||
224 | "vin1_data8", "vin1"), | 228 | "vin1_data8", "vin1"), |
225 | }; | 229 | }; |
226 | 230 | ||
227 | #define FPGA 0x18200000 | ||
228 | #define IRQ0MR 0x30 | ||
229 | #define PFC 0xfffc0000 | 231 | #define PFC 0xfffc0000 |
230 | #define PUPR4 0x110 | 232 | #define PUPR4 0x110 |
231 | static void __init bockw_init(void) | 233 | static void __init bockw_init(void) |
@@ -269,8 +271,8 @@ static void __init bockw_init(void) | |||
269 | 271 | ||
270 | 272 | ||
271 | /* for SMSC */ | 273 | /* for SMSC */ |
272 | base = ioremap_nocache(FPGA, SZ_1M); | 274 | fpga = ioremap_nocache(FPGA, SZ_1M); |
273 | if (base) { | 275 | if (fpga) { |
274 | /* | 276 | /* |
275 | * CAUTION | 277 | * CAUTION |
276 | * | 278 | * |
@@ -278,10 +280,9 @@ static void __init bockw_init(void) | |||
278 | * it should be cared in the future | 280 | * it should be cared in the future |
279 | * Now, it is assuming IRQ0 was used only from SMSC. | 281 | * Now, it is assuming IRQ0 was used only from SMSC. |
280 | */ | 282 | */ |
281 | u16 val = ioread16(base + IRQ0MR); | 283 | u16 val = ioread16(fpga + IRQ0MR); |
282 | val &= ~(1 << 4); /* enable SMSC911x */ | 284 | val &= ~(1 << 4); /* enable SMSC911x */ |
283 | iowrite16(val, base + IRQ0MR); | 285 | iowrite16(val, fpga + IRQ0MR); |
284 | iounmap(base); | ||
285 | 286 | ||
286 | regulator_register_fixed(0, dummy_supplies, | 287 | regulator_register_fixed(0, dummy_supplies, |
287 | ARRAY_SIZE(dummy_supplies)); | 288 | ARRAY_SIZE(dummy_supplies)); |