aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m68knommu
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-04-03 12:44:58 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-03 12:44:58 -0400
commit5de1ccbe51e89c51a2fe5ab333b7c9c2e7294aff (patch)
tree588d68842d6a082828e3a17efa3de6177b712a97 /arch/m68knommu
parent223cdea4c4b5af5181b2da00ac85711d1e0c737c (diff)
parentb4d63e8e745b0000ba22f44ff34cd51e8b4d0389 (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu: (41 commits) m68knommu: improve compile arch switch settings m68knommu: fix 5407 ColdFire UART vector setup m68knommu: fix 5307 ColdFire UART vector setup m68knommu: fix 5249 ColdFire UART vector setup m68knommu: fix 5249 ColdFire UART setup m68knommu: fix end of uart table marker m68knommu: switch to using generic_handle_irq() m68k: merge the mmu and non-mmu versions of tlbflush.h m68knommu: introduce basic clk infrastructure m68k: merge the mmu and non-mmu versions of module.h m68knommu: add missing interrupt line definition for UART 2 m68k: merge the mmu and non-mmu versions of mmu_context.h m68k: merge the mmu and non-mmu versions of current.h m68k: merge the mmu and non-mmu versions of div64.h m68k: merge the mmu and non-mmu versions of bugs.h m68k: merge the mmu and non-mmu versions of bug.h m68k: use the mmu version of cache.h for m68knommu as well m68k: use the mmu version of bootinfo.h for m68knommu as well m68k: merge the mmu and non-mmu versions of fb.h m68k: merge the mmu and non-mmu versions of segment.h ...
Diffstat (limited to 'arch/m68knommu')
-rw-r--r--arch/m68knommu/Makefile14
-rw-r--r--arch/m68knommu/kernel/dma.c8
-rw-r--r--arch/m68knommu/kernel/irq.c2
-rw-r--r--arch/m68knommu/mm/init.c6
-rw-r--r--arch/m68knommu/platform/5249/config.c11
-rw-r--r--arch/m68knommu/platform/5307/config.c8
-rw-r--r--arch/m68knommu/platform/5407/config.c8
-rw-r--r--arch/m68knommu/platform/coldfire/Makefile2
-rw-r--r--arch/m68knommu/platform/coldfire/clk.c40
9 files changed, 71 insertions, 28 deletions
diff --git a/arch/m68knommu/Makefile b/arch/m68knommu/Makefile
index fd0fb303d885..ce404bc9ccbd 100644
--- a/arch/m68knommu/Makefile
+++ b/arch/m68knommu/Makefile
@@ -88,18 +88,18 @@ export PLATFORM BOARD MODEL CPUCLASS
88# 88#
89# Some CFLAG additions based on specific CPU type. 89# Some CFLAG additions based on specific CPU type.
90# 90#
91cflags-$(CONFIG_M5206) := -m5200 91cflags-$(CONFIG_M5206) := $(call cc-option,-mcpu=5206,-m5200)
92cflags-$(CONFIG_M5206e) := -m5200 92cflags-$(CONFIG_M5206e) := $(call cc-option,-m5206e,-m5200)
93cflags-$(CONFIG_M520x) := -m5307 93cflags-$(CONFIG_M520x) := $(call cc-option,-mcpu=5208,-m5200)
94cflags-$(CONFIG_M523x) := $(call cc-option,-mcpu=523x,-m5307) 94cflags-$(CONFIG_M523x) := $(call cc-option,-mcpu=523x,-m5307)
95cflags-$(CONFIG_M5249) := -m5200 95cflags-$(CONFIG_M5249) := $(call cc-option,-mcpu=5249,-m5200)
96cflags-$(CONFIG_M5271) := $(call cc-option,-mcpu=5271,-m5307) 96cflags-$(CONFIG_M5271) := $(call cc-option,-mcpu=5271,-m5307)
97cflags-$(CONFIG_M5272) := -m5307 97cflags-$(CONFIG_M5272) := $(call cc-option,-mcpu=5271,-m5200)
98cflags-$(CONFIG_M5275) := $(call cc-option,-mcpu=5275,-m5307) 98cflags-$(CONFIG_M5275) := $(call cc-option,-mcpu=5275,-m5307)
99cflags-$(CONFIG_M528x) := $(call cc-option,-m528x,-m5307) 99cflags-$(CONFIG_M528x) := $(call cc-option,-m528x,-m5307)
100cflags-$(CONFIG_M5307) := -m5307 100cflags-$(CONFIG_M5307) := $(call cc-option,-m5307,-m5200)
101cflags-$(CONFIG_M532x) := $(call cc-option,-mcpu=532x,-m5307) 101cflags-$(CONFIG_M532x) := $(call cc-option,-mcpu=532x,-m5307)
102cflags-$(CONFIG_M5407) := -m5200 102cflags-$(CONFIG_M5407) := $(call cc-option,-m5407,-m5200)
103cflags-$(CONFIG_M68328) := -m68000 103cflags-$(CONFIG_M68328) := -m68000
104cflags-$(CONFIG_M68EZ328) := -m68000 104cflags-$(CONFIG_M68EZ328) := -m68000
105cflags-$(CONFIG_M68VZ328) := -m68000 105cflags-$(CONFIG_M68VZ328) := -m68000
diff --git a/arch/m68knommu/kernel/dma.c b/arch/m68knommu/kernel/dma.c
index e10eafc52789..936125806638 100644
--- a/arch/m68knommu/kernel/dma.c
+++ b/arch/m68knommu/kernel/dma.c
@@ -9,10 +9,11 @@
9#include <linux/mm.h> 9#include <linux/mm.h>
10#include <linux/string.h> 10#include <linux/string.h>
11#include <linux/device.h> 11#include <linux/device.h>
12#include <linux/dma-mapping.h>
12#include <asm/io.h> 13#include <asm/io.h>
13 14
14void *dma_alloc_coherent(struct device *dev, size_t size, 15void *dma_alloc_coherent(struct device *dev, size_t size,
15 dma_addr_t *dma_handle, int gfp) 16 dma_addr_t *dma_handle, gfp_t gfp)
16{ 17{
17 void *ret; 18 void *ret;
18 /* ignore region specifiers */ 19 /* ignore region specifiers */
@@ -34,3 +35,8 @@ void dma_free_coherent(struct device *dev, size_t size,
34{ 35{
35 free_pages((unsigned long)vaddr, get_order(size)); 36 free_pages((unsigned long)vaddr, get_order(size));
36} 37}
38
39void dma_sync_single_for_cpu(struct device *dev, dma_addr_t handle, size_t size, enum dma_data_direction dir)
40{
41}
42
diff --git a/arch/m68knommu/kernel/irq.c b/arch/m68knommu/kernel/irq.c
index bba1bb48a21f..56e0f4c55a67 100644
--- a/arch/m68knommu/kernel/irq.c
+++ b/arch/m68knommu/kernel/irq.c
@@ -23,7 +23,7 @@ asmlinkage void do_IRQ(int irq, struct pt_regs *regs)
23 struct pt_regs *oldregs = set_irq_regs(regs); 23 struct pt_regs *oldregs = set_irq_regs(regs);
24 24
25 irq_enter(); 25 irq_enter();
26 __do_IRQ(irq); 26 generic_handle_irq(irq);
27 irq_exit(); 27 irq_exit();
28 28
29 set_irq_regs(oldregs); 29 set_irq_regs(oldregs);
diff --git a/arch/m68knommu/mm/init.c b/arch/m68knommu/mm/init.c
index 3bf249c53e41..7befc0c357e0 100644
--- a/arch/m68knommu/mm/init.c
+++ b/arch/m68knommu/mm/init.c
@@ -111,11 +111,7 @@ void __init paging_init(void)
111 { 111 {
112 unsigned long zones_size[MAX_NR_ZONES] = {0, }; 112 unsigned long zones_size[MAX_NR_ZONES] = {0, };
113 113
114 zones_size[ZONE_DMA] = 0 >> PAGE_SHIFT; 114 zones_size[ZONE_DMA] = (end_mem - PAGE_OFFSET) >> PAGE_SHIFT;
115 zones_size[ZONE_NORMAL] = (end_mem - PAGE_OFFSET) >> PAGE_SHIFT;
116#ifdef CONFIG_HIGHMEM
117 zones_size[ZONE_HIGHMEM] = 0;
118#endif
119 free_area_init(zones_size); 115 free_area_init(zones_size);
120 } 116 }
121} 117}
diff --git a/arch/m68knommu/platform/5249/config.c b/arch/m68knommu/platform/5249/config.c
index d299f7b8768a..9eab19d01eb1 100644
--- a/arch/m68knommu/platform/5249/config.c
+++ b/arch/m68knommu/platform/5249/config.c
@@ -32,7 +32,8 @@ static struct mcf_platform_uart m5249_uart_platform[] = {
32 { 32 {
33 .mapbase = MCF_MBAR + MCFUART_BASE2, 33 .mapbase = MCF_MBAR + MCFUART_BASE2,
34 .irq = 74, 34 .irq = 74,
35 } 35 },
36 { },
36}; 37};
37 38
38static struct platform_device m5249_uart = { 39static struct platform_device m5249_uart = {
@@ -50,12 +51,12 @@ static struct platform_device *m5249_devices[] __initdata = {
50static void __init m5249_uart_init_line(int line, int irq) 51static void __init m5249_uart_init_line(int line, int irq)
51{ 52{
52 if (line == 0) { 53 if (line == 0) {
53 writel(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI1, MCF_MBAR + MCFSIM_UART1ICR); 54 writeb(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI1, MCF_MBAR + MCFSIM_UART1ICR);
54 writeb(irq, MCFUART_BASE1 + MCFUART_UIVR); 55 writeb(irq, MCF_MBAR + MCFUART_BASE1 + MCFUART_UIVR);
55 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART1); 56 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART1);
56 } else if (line == 1) { 57 } else if (line == 1) {
57 writel(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI2, MCF_MBAR + MCFSIM_UART2ICR); 58 writeb(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI2, MCF_MBAR + MCFSIM_UART2ICR);
58 writeb(irq, MCFUART_BASE2 + MCFUART_UIVR); 59 writeb(irq, MCF_MBAR + MCFUART_BASE2 + MCFUART_UIVR);
59 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART2); 60 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART2);
60 } 61 }
61} 62}
diff --git a/arch/m68knommu/platform/5307/config.c b/arch/m68knommu/platform/5307/config.c
index 724faf05852a..44803bf70a6e 100644
--- a/arch/m68knommu/platform/5307/config.c
+++ b/arch/m68knommu/platform/5307/config.c
@@ -65,12 +65,12 @@ static struct platform_device *m5307_devices[] __initdata = {
65static void __init m5307_uart_init_line(int line, int irq) 65static void __init m5307_uart_init_line(int line, int irq)
66{ 66{
67 if (line == 0) { 67 if (line == 0) {
68 writel(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI1, MCF_MBAR + MCFSIM_UART1ICR); 68 writeb(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI1, MCF_MBAR + MCFSIM_UART1ICR);
69 writeb(irq, MCFUART_BASE1 + MCFUART_UIVR); 69 writeb(irq, MCF_MBAR + MCFUART_BASE1 + MCFUART_UIVR);
70 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART1); 70 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART1);
71 } else if (line == 1) { 71 } else if (line == 1) {
72 writel(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI2, MCF_MBAR + MCFSIM_UART2ICR); 72 writeb(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI2, MCF_MBAR + MCFSIM_UART2ICR);
73 writeb(irq, MCFUART_BASE2 + MCFUART_UIVR); 73 writeb(irq, MCF_MBAR + MCFUART_BASE2 + MCFUART_UIVR);
74 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART2); 74 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART2);
75 } 75 }
76} 76}
diff --git a/arch/m68knommu/platform/5407/config.c b/arch/m68knommu/platform/5407/config.c
index 648b8b778211..0ee8c1a200c8 100644
--- a/arch/m68knommu/platform/5407/config.c
+++ b/arch/m68knommu/platform/5407/config.c
@@ -56,12 +56,12 @@ static struct platform_device *m5407_devices[] __initdata = {
56static void __init m5407_uart_init_line(int line, int irq) 56static void __init m5407_uart_init_line(int line, int irq)
57{ 57{
58 if (line == 0) { 58 if (line == 0) {
59 writel(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI1, MCF_MBAR + MCFSIM_UART1ICR); 59 writeb(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI1, MCF_MBAR + MCFSIM_UART1ICR);
60 writeb(irq, MCFUART_BASE1 + MCFUART_UIVR); 60 writeb(irq, MCF_MBAR + MCFUART_BASE1 + MCFUART_UIVR);
61 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART1); 61 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART1);
62 } else if (line == 1) { 62 } else if (line == 1) {
63 writel(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI2, MCF_MBAR + MCFSIM_UART2ICR); 63 writeb(MCFSIM_ICR_LEVEL6 | MCFSIM_ICR_PRI2, MCF_MBAR + MCFSIM_UART2ICR);
64 writeb(irq, MCFUART_BASE2 + MCFUART_UIVR); 64 writeb(irq, MCF_MBAR + MCFUART_BASE2 + MCFUART_UIVR);
65 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART2); 65 mcf_setimr(mcf_getimr() & ~MCFSIM_IMR_UART2);
66 } 66 }
67} 67}
diff --git a/arch/m68knommu/platform/coldfire/Makefile b/arch/m68knommu/platform/coldfire/Makefile
index 4f416a91a829..1bcb9372353f 100644
--- a/arch/m68knommu/platform/coldfire/Makefile
+++ b/arch/m68knommu/platform/coldfire/Makefile
@@ -14,7 +14,7 @@
14 14
15asflags-$(CONFIG_FULLDEBUG) := -DDEBUGGER_COMPATIBLE_CACHE=1 15asflags-$(CONFIG_FULLDEBUG) := -DDEBUGGER_COMPATIBLE_CACHE=1
16 16
17obj-$(CONFIG_COLDFIRE) += dma.o entry.o vectors.o 17obj-$(CONFIG_COLDFIRE) += clk.o dma.o entry.o vectors.o
18obj-$(CONFIG_M5206) += timers.o 18obj-$(CONFIG_M5206) += timers.o
19obj-$(CONFIG_M5206e) += timers.o 19obj-$(CONFIG_M5206e) += timers.o
20obj-$(CONFIG_M520x) += pit.o 20obj-$(CONFIG_M520x) += pit.o
diff --git a/arch/m68knommu/platform/coldfire/clk.c b/arch/m68knommu/platform/coldfire/clk.c
new file mode 100644
index 000000000000..7cdbf445b28f
--- /dev/null
+++ b/arch/m68knommu/platform/coldfire/clk.c
@@ -0,0 +1,40 @@
1/***************************************************************************/
2
3/*
4 * clk.c -- general ColdFire CPU kernel clk handling
5 *
6 * Copyright (C) 2009, Greg Ungerer (gerg@snapgear.com)
7 */
8
9/***************************************************************************/
10
11#include <linux/kernel.h>
12#include <linux/clk.h>
13#include <asm/coldfire.h>
14
15/***************************************************************************/
16
17struct clk *clk_get(struct device *dev, const char *id)
18{
19 return NULL;
20}
21
22int clk_enable(struct clk *clk)
23{
24 return 0;
25}
26
27void clk_disable(struct clk *clk)
28{
29}
30
31void clk_put(struct clk *clk)
32{
33}
34
35unsigned long clk_get_rate(struct clk *clk)
36{
37 return MCF_CLK;
38}
39
40/***************************************************************************/