--- zzzz-none-000/linux-3.10.107/arch/m68k/apollo/config.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/arch/m68k/apollo/config.c 2021-02-04 17:41:59.000000000 +0000 @@ -1,3 +1,4 @@ +#include #include #include #include @@ -9,6 +10,8 @@ #include #include +#include +#include #include #include #include @@ -43,28 +46,27 @@ [APOLLO_DN4500-APOLLO_DN3000] = "DN4500 (Roadrunner)" }; -int apollo_parse_bootinfo(const struct bi_record *record) { - +int __init apollo_parse_bootinfo(const struct bi_record *record) +{ int unknown = 0; - const unsigned long *data = record->data; + const void *data = record->data; - switch(record->tag) { - case BI_APOLLO_MODEL: - apollo_model=*data; - break; + switch (be16_to_cpu(record->tag)) { + case BI_APOLLO_MODEL: + apollo_model = be32_to_cpup(data); + break; - default: - unknown=1; + default: + unknown=1; } return unknown; } -void dn_setup_model(void) { - - - printk("Apollo hardware found: "); - printk("[%s]\n", apollo_models[apollo_model - APOLLO_DN3000]); +static void __init dn_setup_model(void) +{ + pr_info("Apollo hardware found: [%s]\n", + apollo_models[apollo_model - APOLLO_DN3000]); switch(apollo_model) { case APOLLO_UNKNOWN: @@ -195,8 +197,10 @@ *(volatile unsigned char *)(pica+1)&=(~8); #if 0 - printk("*(0x10803) %02x\n",*(volatile unsigned char *)(apollo_timer + 0x3)); - printk("*(0x10803) %02x\n",*(volatile unsigned char *)(apollo_timer + 0x3)); + pr_info("*(0x10803) %02x\n", + *(volatile unsigned char *)(apollo_timer + 0x3)); + pr_info("*(0x10803) %02x\n", + *(volatile unsigned char *)(apollo_timer + 0x3)); #endif if (request_irq(IRQ_APOLLO, dn_timer_int, 0, "time", timer_routine)) @@ -234,12 +238,10 @@ } -int dn_dummy_set_clock_mmss(unsigned long nowtime) { - - printk("set_clock_mmss\n"); - - return 0; - +int dn_dummy_set_clock_mmss(unsigned long nowtime) +{ + pr_info("set_clock_mmss\n"); + return 0; } void dn_dummy_reset(void) {