From a4df02a217e9787a4b967197d9d9030c3e3c1088 Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Tue, 25 Jun 2013 21:15:24 +0200 Subject: m68k: Mark functions only called from setup_arch() __init Some functions that are only called (indirectly) from setup_arch() lack __init annotations. Signed-off-by: Geert Uytterhoeven --- arch/m68k/apollo/config.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'arch/m68k/apollo/config.c') diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c index 3ea56b90e718..2bdde9685a29 100644 --- a/arch/m68k/apollo/config.c +++ b/arch/m68k/apollo/config.c @@ -1,3 +1,4 @@ +#include #include #include #include @@ -43,8 +44,8 @@ static const char *apollo_models[] = { [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; @@ -60,9 +61,8 @@ int apollo_parse_bootinfo(const struct bi_record *record) { return unknown; } -void dn_setup_model(void) { - - +static void __init dn_setup_model(void) +{ printk("Apollo hardware found: "); printk("[%s]\n", apollo_models[apollo_model - APOLLO_DN3000]); -- cgit v1.2.1 From 4c3c522bcebe16a717d7a809fd14b11823794027 Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Wed, 2 Oct 2013 11:37:33 +0200 Subject: m68k/UAPI: Disintegrate arch/m68k/include/asm/bootinfo.h Export the bootinfo definitions that are used by bootstrap loaders, and split them up in generic and platform-specific parts. Signed-off-by: Geert Uytterhoeven --- arch/m68k/apollo/config.c | 1 + 1 file changed, 1 insertion(+) (limited to 'arch/m68k/apollo/config.c') diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c index 2bdde9685a29..c90c19e904bc 100644 --- a/arch/m68k/apollo/config.c +++ b/arch/m68k/apollo/config.c @@ -10,6 +10,7 @@ #include #include +#include #include #include #include -- cgit v1.2.1 From abe48101c17eaf1b5d85270272392e6111562626 Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Fri, 4 Oct 2013 11:41:24 +0200 Subject: m68k/UAPI: Use proper types (endianness/size) in Signed-off-by: Geert Uytterhoeven --- arch/m68k/apollo/config.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'arch/m68k/apollo/config.c') diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c index c90c19e904bc..9268c0f96376 100644 --- a/arch/m68k/apollo/config.c +++ b/arch/m68k/apollo/config.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include @@ -48,15 +49,15 @@ static const char *apollo_models[] = { 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; -- cgit v1.2.1