ARM: Fix compiler warning when CONFIG_ATAGS is not set
PATCH 1/1 ARM: Fix compiler warning when CONFIG_ATAGS is not set
This patch fix following compiler warning:
CC arch/arm/kernel/setup.o
In file included from arch/arm/kernel/setup.c:58:
arch/arm/kernel/atags.h: In function 'setup_machine_tags':
arch/arm/kernel/atags.h:18: warning: no return statement in function returning non-void
Signed-off-by Alexander Shiyan <[email protected]>
--- arch/arm/kernel/atags.h | 8 -------- arch/arm/kernel/setup.c | 8 +++++++- 2 files changed, 7 insertions(+), 9 deletions(-)
arch/arm/kernel/atags.h +0 -8
@@ -8,12 +8,4 @@ void convert_to_tag_list(struct tag *tags);#ifdef CONFIG_ATAGS struct machine_desc *setup_machine_tags (phys_addr_t __atags_pointer,unsigned int machine_nr); -#else -static inline struct machine_desc * -setup_machine_tags (phys_addr_t __atags_pointer,unsigned int machine_nr) -{ -early_print ("no ATAGS support: can't continue\n" ); -while (true); -unreachable (); -}#endif
arch/arm/kernel/setup.c +7 -1
@@ -732,8 +732,14 @@ void __init setup_arch(char **cmdline_p)setup_processor (); mdesc =setup_machine_fdt (__atags_pointer); -if (!mdesc) +if (!mdesc) { +#ifdef CONFIG_ATAGS mdesc =setup_machine_tags (__atags_pointer, __machine_arch_type); +#else +early_print ("no ATAGS support: can't continue\n" ); +while (1 ); +#endif + } machine_desc = mdesc; machine_name = mdesc->name;
Signature · 1 line
1.7.12.4