aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m68k/apollo/config.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/m68k/apollo/config.c')
-rw-r--r--arch/m68k/apollo/config.c26
1 files changed, 14 insertions, 12 deletions
diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c
index 3ea56b90e718..9268c0f96376 100644
--- a/arch/m68k/apollo/config.c
+++ b/arch/m68k/apollo/config.c
@@ -1,3 +1,4 @@
1#include <linux/init.h>
1#include <linux/types.h> 2#include <linux/types.h>
2#include <linux/kernel.h> 3#include <linux/kernel.h>
3#include <linux/mm.h> 4#include <linux/mm.h>
@@ -9,6 +10,8 @@
9 10
10#include <asm/setup.h> 11#include <asm/setup.h>
11#include <asm/bootinfo.h> 12#include <asm/bootinfo.h>
13#include <asm/bootinfo-apollo.h>
14#include <asm/byteorder.h>
12#include <asm/pgtable.h> 15#include <asm/pgtable.h>
13#include <asm/apollohw.h> 16#include <asm/apollohw.h>
14#include <asm/irq.h> 17#include <asm/irq.h>
@@ -43,26 +46,25 @@ static const char *apollo_models[] = {
43 [APOLLO_DN4500-APOLLO_DN3000] = "DN4500 (Roadrunner)" 46 [APOLLO_DN4500-APOLLO_DN3000] = "DN4500 (Roadrunner)"
44}; 47};
45 48
46int apollo_parse_bootinfo(const struct bi_record *record) { 49int __init apollo_parse_bootinfo(const struct bi_record *record)
47 50{
48 int unknown = 0; 51 int unknown = 0;
49 const unsigned long *data = record->data; 52 const void *data = record->data;
50 53
51 switch(record->tag) { 54 switch (be16_to_cpu(record->tag)) {
52 case BI_APOLLO_MODEL: 55 case BI_APOLLO_MODEL:
53 apollo_model=*data; 56 apollo_model = be32_to_cpup(data);
54 break; 57 break;
55 58
56 default: 59 default:
57 unknown=1; 60 unknown=1;
58 } 61 }
59 62
60 return unknown; 63 return unknown;
61} 64}
62 65
63void dn_setup_model(void) { 66static void __init dn_setup_model(void)
64 67{
65
66 printk("Apollo hardware found: "); 68 printk("Apollo hardware found: ");
67 printk("[%s]\n", apollo_models[apollo_model - APOLLO_DN3000]); 69 printk("[%s]\n", apollo_models[apollo_model - APOLLO_DN3000]);
68 70