aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-ux500/cpu-db5500.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-ux500/cpu-db5500.c')
-rw-r--r--arch/arm/mach-ux500/cpu-db5500.c50
1 files changed, 50 insertions, 0 deletions
diff --git a/arch/arm/mach-ux500/cpu-db5500.c b/arch/arm/mach-ux500/cpu-db5500.c
new file mode 100644
index 000000000000..6a3ac4539f16
--- /dev/null
+++ b/arch/arm/mach-ux500/cpu-db5500.c
@@ -0,0 +1,50 @@
1/*
2 * Copyright (C) ST-Ericsson SA 2010
3 *
4 * Author: Rabin Vincent <rabin.vincent@stericsson.com> for ST-Ericsson
5 * License terms: GNU General Public License (GPL) version 2
6 */
7
8#include <linux/platform_device.h>
9#include <linux/amba/bus.h>
10#include <linux/io.h>
11
12#include <asm/mach/map.h>
13
14#include <mach/hardware.h>
15#include <mach/devices.h>
16#include <mach/setup.h>
17
18static struct map_desc u5500_io_desc[] __initdata = {
19 __IO_DEV_DESC(U5500_GPIO0_BASE, SZ_4K),
20 __IO_DEV_DESC(U5500_GPIO1_BASE, SZ_4K),
21 __IO_DEV_DESC(U5500_GPIO2_BASE, SZ_4K),
22 __IO_DEV_DESC(U5500_GPIO3_BASE, SZ_4K),
23 __IO_DEV_DESC(U5500_GPIO4_BASE, SZ_4K),
24};
25
26static struct platform_device *u5500_platform_devs[] __initdata = {
27 &u5500_gpio_devs[0],
28 &u5500_gpio_devs[1],
29 &u5500_gpio_devs[2],
30 &u5500_gpio_devs[3],
31 &u5500_gpio_devs[4],
32 &u5500_gpio_devs[5],
33 &u5500_gpio_devs[6],
34 &u5500_gpio_devs[7],
35};
36
37void __init u5500_map_io(void)
38{
39 ux500_map_io();
40
41 iotable_init(u5500_io_desc, ARRAY_SIZE(u5500_io_desc));
42}
43
44void __init u5500_init_devices(void)
45{
46 ux500_init_devices();
47
48 platform_add_devices(u5500_platform_devs,
49 ARRAY_SIZE(u5500_platform_devs));
50}