aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/m68k/kernel/setup.c6
-rw-r--r--include/asm-m68k/fpu.h10
-rw-r--r--include/asm-m68k/irq.h2
-rw-r--r--include/asm-m68k/tlbflush.h8
4 files changed, 16 insertions, 10 deletions
diff --git a/arch/m68k/kernel/setup.c b/arch/m68k/kernel/setup.c
index a9fb83a8c180..b1f39e4cedbc 100644
--- a/arch/m68k/kernel/setup.c
+++ b/arch/m68k/kernel/setup.c
@@ -26,6 +26,7 @@
26 26
27#include <asm/bootinfo.h> 27#include <asm/bootinfo.h>
28#include <asm/setup.h> 28#include <asm/setup.h>
29#include <asm/fpu.h>
29#include <asm/irq.h> 30#include <asm/irq.h>
30#include <asm/io.h> 31#include <asm/io.h>
31#include <asm/machdep.h> 32#include <asm/machdep.h>
@@ -40,6 +41,11 @@
40#include <asm/dvma.h> 41#include <asm/dvma.h>
41#endif 42#endif
42 43
44#if !FPSTATESIZE || !NR_IRQS
45#warning No CPU/platform type selected, your kernel will not work!
46#warning Are you building an allnoconfig kernel?
47#endif
48
43unsigned long m68k_machtype; 49unsigned long m68k_machtype;
44EXPORT_SYMBOL(m68k_machtype); 50EXPORT_SYMBOL(m68k_machtype);
45unsigned long m68k_cputype; 51unsigned long m68k_cputype;
diff --git a/include/asm-m68k/fpu.h b/include/asm-m68k/fpu.h
index 59701d7b4e78..ffb6b8cfc6d5 100644
--- a/include/asm-m68k/fpu.h
+++ b/include/asm-m68k/fpu.h
@@ -7,15 +7,15 @@
7 */ 7 */
8 8
9#if defined(CONFIG_M68020) || defined(CONFIG_M68030) 9#if defined(CONFIG_M68020) || defined(CONFIG_M68030)
10#define FPSTATESIZE (216/sizeof(unsigned char)) 10#define FPSTATESIZE (216)
11#elif defined(CONFIG_M68040) 11#elif defined(CONFIG_M68040)
12#define FPSTATESIZE (96/sizeof(unsigned char)) 12#define FPSTATESIZE (96)
13#elif defined(CONFIG_M68KFPU_EMU) 13#elif defined(CONFIG_M68KFPU_EMU)
14#define FPSTATESIZE (28/sizeof(unsigned char)) 14#define FPSTATESIZE (28)
15#elif defined(CONFIG_M68060) 15#elif defined(CONFIG_M68060)
16#define FPSTATESIZE (12/sizeof(unsigned char)) 16#define FPSTATESIZE (12)
17#else 17#else
18#define FPSTATESIZE error no_cpu_type_configured 18#define FPSTATESIZE (0)
19#endif 19#endif
20 20
21#endif /* __M68K_FPU_H */ 21#endif /* __M68K_FPU_H */
diff --git a/include/asm-m68k/irq.h b/include/asm-m68k/irq.h
index eb29a5260591..226bfc0f21b1 100644
--- a/include/asm-m68k/irq.h
+++ b/include/asm-m68k/irq.h
@@ -24,7 +24,7 @@
24#elif defined(CONFIG_HP300) 24#elif defined(CONFIG_HP300)
25#define NR_IRQS 8 25#define NR_IRQS 8
26#else 26#else
27#error unknown nr of irqs 27#define NR_IRQS 0
28#endif 28#endif
29 29
30/* 30/*
diff --git a/include/asm-m68k/tlbflush.h b/include/asm-m68k/tlbflush.h
index 17707ec315e2..acb6bf21a321 100644
--- a/include/asm-m68k/tlbflush.h
+++ b/include/asm-m68k/tlbflush.h
@@ -16,7 +16,7 @@ static inline void flush_tlb_kernel_page(void *addr)
16 ".chip 68k" 16 ".chip 68k"
17 : : "a" (addr)); 17 : : "a" (addr));
18 set_fs(old_fs); 18 set_fs(old_fs);
19 } else 19 } else if (CPU_IS_020_OR_030)
20 __asm__ __volatile__("pflush #4,#4,(%0)" : : "a" (addr)); 20 __asm__ __volatile__("pflush #4,#4,(%0)" : : "a" (addr));
21} 21}
22 22
@@ -29,7 +29,7 @@ static inline void __flush_tlb(void)
29 __asm__ __volatile__(".chip 68040\n\t" 29 __asm__ __volatile__(".chip 68040\n\t"
30 "pflushan\n\t" 30 "pflushan\n\t"
31 ".chip 68k"); 31 ".chip 68k");
32 else 32 else if (CPU_IS_020_OR_030)
33 __asm__ __volatile__("pflush #0,#4"); 33 __asm__ __volatile__("pflush #0,#4");
34} 34}
35 35
@@ -45,7 +45,7 @@ static inline void __flush_tlb_one(unsigned long addr)
45{ 45{
46 if (CPU_IS_040_OR_060) 46 if (CPU_IS_040_OR_060)
47 __flush_tlb040_one(addr); 47 __flush_tlb040_one(addr);
48 else 48 else if (CPU_IS_020_OR_030)
49 __asm__ __volatile__("pflush #0,#4,(%0)" : : "a" (addr)); 49 __asm__ __volatile__("pflush #0,#4,(%0)" : : "a" (addr));
50} 50}
51 51
@@ -60,7 +60,7 @@ static inline void flush_tlb_all(void)
60 __asm__ __volatile__(".chip 68040\n\t" 60 __asm__ __volatile__(".chip 68040\n\t"
61 "pflusha\n\t" 61 "pflusha\n\t"
62 ".chip 68k"); 62 ".chip 68k");
63 else 63 else if (CPU_IS_020_OR_030)
64 __asm__ __volatile__("pflusha"); 64 __asm__ __volatile__("pflusha");
65} 65}
66 66