aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m68knommu/platform
diff options
context:
space:
mode:
authorGreg Ungerer <gerg@uclinux.org>2010-11-01 22:05:29 -0400
committerGreg Ungerer <gerg@uclinux.org>2011-01-05 00:19:17 -0500
commit5b2e6555ac3eb58a4e5eb5020471df08f0c42c01 (patch)
tree38514c0431fce8567a5ae74ea76e99ef910891d9 /arch/m68knommu/platform
parent9c68015b149d45a35114b4a1ed44c21fa66bc430 (diff)
m68knommu: make Coldfire 548x support more generic
The ColdFire 547x family of processors is very similar to the ColdFire 548x series. Almost all of the support for them is the same. Make the code supporting the 548x more gneric, so it will be capable of supporting both families. For the most part this is a renaming excerise to make the support code more obviously apply to both families. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Diffstat (limited to 'arch/m68knommu/platform')
-rw-r--r--arch/m68knommu/platform/54xx/Makefile (renamed from arch/m68knommu/platform/548x/Makefile)0
-rw-r--r--arch/m68knommu/platform/54xx/config.c (renamed from arch/m68knommu/platform/548x/config.c)32
-rw-r--r--arch/m68knommu/platform/coldfire/Makefile2
3 files changed, 17 insertions, 17 deletions
diff --git a/arch/m68knommu/platform/548x/Makefile b/arch/m68knommu/platform/54xx/Makefile
index e6035e7a2d3f..e6035e7a2d3f 100644
--- a/arch/m68knommu/platform/548x/Makefile
+++ b/arch/m68knommu/platform/54xx/Makefile
diff --git a/arch/m68knommu/platform/548x/config.c b/arch/m68knommu/platform/54xx/config.c
index 9888846bd1cf..78130984db95 100644
--- a/arch/m68knommu/platform/548x/config.c
+++ b/arch/m68knommu/platform/54xx/config.c
@@ -1,7 +1,7 @@
1/***************************************************************************/ 1/***************************************************************************/
2 2
3/* 3/*
4 * linux/arch/m68knommu/platform/548x/config.c 4 * linux/arch/m68knommu/platform/54xx/config.c
5 * 5 *
6 * Copyright (C) 2010, Philippe De Muyter <phdm@macqel.be> 6 * Copyright (C) 2010, Philippe De Muyter <phdm@macqel.be>
7 */ 7 */
@@ -15,13 +15,13 @@
15#include <linux/io.h> 15#include <linux/io.h>
16#include <asm/machdep.h> 16#include <asm/machdep.h>
17#include <asm/coldfire.h> 17#include <asm/coldfire.h>
18#include <asm/m548xsim.h> 18#include <asm/m54xxsim.h>
19#include <asm/mcfuart.h> 19#include <asm/mcfuart.h>
20#include <asm/m548xgpt.h> 20#include <asm/m54xxgpt.h>
21 21
22/***************************************************************************/ 22/***************************************************************************/
23 23
24static struct mcf_platform_uart m548x_uart_platform[] = { 24static struct mcf_platform_uart m54xx_uart_platform[] = {
25 { 25 {
26 .mapbase = MCF_MBAR + MCFUART_BASE1, 26 .mapbase = MCF_MBAR + MCFUART_BASE1,
27 .irq = 64 + 35, 27 .irq = 64 + 35,
@@ -40,20 +40,20 @@ static struct mcf_platform_uart m548x_uart_platform[] = {
40 }, 40 },
41}; 41};
42 42
43static struct platform_device m548x_uart = { 43static struct platform_device m54xx_uart = {
44 .name = "mcfuart", 44 .name = "mcfuart",
45 .id = 0, 45 .id = 0,
46 .dev.platform_data = m548x_uart_platform, 46 .dev.platform_data = m54xx_uart_platform,
47}; 47};
48 48
49static struct platform_device *m548x_devices[] __initdata = { 49static struct platform_device *m54xx_devices[] __initdata = {
50 &m548x_uart, 50 &m54xx_uart,
51}; 51};
52 52
53 53
54/***************************************************************************/ 54/***************************************************************************/
55 55
56static void __init m548x_uart_init_line(int line, int irq) 56static void __init m54xx_uart_init_line(int line, int irq)
57{ 57{
58 int rts_cts; 58 int rts_cts;
59 59
@@ -72,18 +72,18 @@ static void __init m548x_uart_init_line(int line, int irq)
72 MCF_MBAR + MCF_PAR_PSC(line)); 72 MCF_MBAR + MCF_PAR_PSC(line));
73} 73}
74 74
75static void __init m548x_uarts_init(void) 75static void __init m54xx_uarts_init(void)
76{ 76{
77 const int nrlines = ARRAY_SIZE(m548x_uart_platform); 77 const int nrlines = ARRAY_SIZE(m54xx_uart_platform);
78 int line; 78 int line;
79 79
80 for (line = 0; (line < nrlines); line++) 80 for (line = 0; (line < nrlines); line++)
81 m548x_uart_init_line(line, m548x_uart_platform[line].irq); 81 m54xx_uart_init_line(line, m54xx_uart_platform[line].irq);
82} 82}
83 83
84/***************************************************************************/ 84/***************************************************************************/
85 85
86static void mcf548x_reset(void) 86static void mcf54xx_reset(void)
87{ 87{
88 /* disable interrupts and enable the watchdog */ 88 /* disable interrupts and enable the watchdog */
89 asm("movew #0x2700, %sr\n"); 89 asm("movew #0x2700, %sr\n");
@@ -97,8 +97,8 @@ static void mcf548x_reset(void)
97 97
98void __init config_BSP(char *commandp, int size) 98void __init config_BSP(char *commandp, int size)
99{ 99{
100 mach_reset = mcf548x_reset; 100 mach_reset = mcf54xx_reset;
101 m548x_uarts_init(); 101 m54xx_uarts_init();
102} 102}
103 103
104/***************************************************************************/ 104/***************************************************************************/
@@ -106,7 +106,7 @@ void __init config_BSP(char *commandp, int size)
106static int __init init_BSP(void) 106static int __init init_BSP(void)
107{ 107{
108 108
109 platform_add_devices(m548x_devices, ARRAY_SIZE(m548x_devices)); 109 platform_add_devices(m54xx_devices, ARRAY_SIZE(m54xx_devices));
110 return 0; 110 return 0;
111} 111}
112 112
diff --git a/arch/m68knommu/platform/coldfire/Makefile b/arch/m68knommu/platform/coldfire/Makefile
index 45f501fa4525..53a27e1a7904 100644
--- a/arch/m68knommu/platform/coldfire/Makefile
+++ b/arch/m68knommu/platform/coldfire/Makefile
@@ -26,7 +26,7 @@ obj-$(CONFIG_M528x) += pit.o intc-2.o
26obj-$(CONFIG_M5307) += timers.o intc.o 26obj-$(CONFIG_M5307) += timers.o intc.o
27obj-$(CONFIG_M532x) += timers.o intc-simr.o 27obj-$(CONFIG_M532x) += timers.o intc-simr.o
28obj-$(CONFIG_M5407) += timers.o intc.o 28obj-$(CONFIG_M5407) += timers.o intc.o
29obj-$(CONFIG_M548x) += sltimers.o intc-2.o 29obj-$(CONFIG_M54xx) += sltimers.o intc-2.o
30 30
31obj-y += pinmux.o gpio.o 31obj-y += pinmux.o gpio.o
32extra-y := head.o 32extra-y := head.o