aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDinh Nguyen <Dinh.Nguyen@freescale.com>2010-11-15 12:30:00 -0500
committerSascha Hauer <s.hauer@pengutronix.de>2010-11-24 04:09:06 -0500
commitb66ff7a2cd411a2245c984793a7eb98ee91771f9 (patch)
tree2688f4581ac40abf1f0f976f5441f5cd0454a4f6
parentc0abefd30b2c9db015df4914a95d268ecdb39b00 (diff)
ARM: imx: Add mx53 support to common msl functions.
Add mx53 support to cpu.c and mm.c. Signed-off-by: Dinh Nguyen <Dinh.Nguyen@freescale.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
-rw-r--r--arch/arm/mach-mx5/cpu.c19
-rw-r--r--arch/arm/mach-mx5/mm.c19
2 files changed, 36 insertions, 2 deletions
diff --git a/arch/arm/mach-mx5/cpu.c b/arch/arm/mach-mx5/cpu.c
index 8c9a29e322dc..a00d2bc7246a 100644
--- a/arch/arm/mach-mx5/cpu.c
+++ b/arch/arm/mach-mx5/cpu.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * Copyright 2008-2009 Freescale Semiconductor, Inc. All Rights Reserved. 2 * Copyright 2008-2010 Freescale Semiconductor, Inc. All Rights Reserved.
3 * 3 *
4 * The code contained herein is licensed under the GNU General Public 4 * The code contained herein is licensed under the GNU General Public
5 * License. You may obtain a copy of the GNU General Public License 5 * License. You may obtain a copy of the GNU General Public License
@@ -92,6 +92,23 @@ static int __init mx51_neon_fixup(void)
92late_initcall(mx51_neon_fixup); 92late_initcall(mx51_neon_fixup);
93#endif 93#endif
94 94
95/*
96 * Returns:
97 * the silicon revision of the cpu
98 * -EINVAL - not a mx53
99 */
100int mx53_revision(void)
101{
102 if (!cpu_is_mx53())
103 return -EINVAL;
104
105 if (cpu_silicon_rev == -1)
106 query_silicon_parameter();
107
108 return cpu_silicon_rev;
109}
110EXPORT_SYMBOL(mx53_revision);
111
95static int __init post_cpu_init(void) 112static int __init post_cpu_init(void)
96{ 113{
97 unsigned int reg; 114 unsigned int reg;
diff --git a/arch/arm/mach-mx5/mm.c b/arch/arm/mach-mx5/mm.c
index 2822d0e6f23a..cbaf282fb818 100644
--- a/arch/arm/mach-mx5/mm.c
+++ b/arch/arm/mach-mx5/mm.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * Copyright 2008-2009 Freescale Semiconductor, Inc. All Rights Reserved. 2 * Copyright 2008-2010 Freescale Semiconductor, Inc. All Rights Reserved.
3 * 3 *
4 * The code contained herein is licensed under the GNU General Public 4 * The code contained herein is licensed under the GNU General Public
5 * License. You may obtain a copy of the GNU General Public License 5 * License. You may obtain a copy of the GNU General Public License
@@ -32,6 +32,15 @@ static struct map_desc mx51_io_desc[] __initdata = {
32}; 32};
33 33
34/* 34/*
35 * Define the MX53 memory map.
36 */
37static struct map_desc mx53_io_desc[] __initdata = {
38 imx_map_entry(MX53, AIPS1, MT_DEVICE),
39 imx_map_entry(MX53, SPBA0, MT_DEVICE),
40 imx_map_entry(MX53, AIPS2, MT_DEVICE),
41};
42
43/*
35 * This function initializes the memory map. It is called during the 44 * This function initializes the memory map. It is called during the
36 * system startup to create static physical to virtual memory mappings 45 * system startup to create static physical to virtual memory mappings
37 * for the IO modules. 46 * for the IO modules.
@@ -44,6 +53,14 @@ void __init mx51_map_io(void)
44 iotable_init(mx51_io_desc, ARRAY_SIZE(mx51_io_desc)); 53 iotable_init(mx51_io_desc, ARRAY_SIZE(mx51_io_desc));
45} 54}
46 55
56void __init mx53_map_io(void)
57{
58 mxc_set_cpu_type(MXC_CPU_MX53);
59 mxc_iomux_v3_init(MX53_IO_ADDRESS(MX53_IOMUXC_BASE_ADDR));
60 mxc_arch_reset_init(MX53_IO_ADDRESS(MX53_WDOG_BASE_ADDR));
61 iotable_init(mx53_io_desc, ARRAY_SIZE(mx53_io_desc));
62}
63
47int imx51_register_gpios(void); 64int imx51_register_gpios(void);
48 65
49void __init mx51_init_irq(void) 66void __init mx51_init_irq(void)