From 670d39657ca355615428d176e9de4e69bfb3cf9b Mon Sep 17 00:00:00 2001 From: Greg Ungerer Date: Mon, 12 Oct 2020 13:58:41 +1000 Subject: m68knommu: align BSS section to 4-byte boundaries The kernel start up code for all of the nommu m68k types expects the BSS section to be on a 4-byte boundary, and to be a whole number of 32bit words. The BSS initialization loop sets 32bit sized quantities and has no provision for odd or unaligned accesses. The alignment and size of the BSS has historically worked out to be 4-byte aligned and sized - although no explicit alignment or size was specified in the linker script. So the BSS zeroing code worked as expected. A problem was first observed after commit 7273ad2b08f8 ("kbuild: link lib-y objects to vmlinux forcibly when CONFIG_MODULES=y"). Some kernel builds, depending on exact configuration, then tended to generate even sized BSS sections - which is valid on m68k - but our BSS init code could not handle properly. The simplest and smallest solution is to align and size the BSS appropriately. Signed-off-by: Greg Ungerer --- arch/m68k/kernel/vmlinux-nommu.lds | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/m68k/kernel') diff --git a/arch/m68k/kernel/vmlinux-nommu.lds b/arch/m68k/kernel/vmlinux-nommu.lds index 7b975420c3d9..730bb653f9c1 100644 --- a/arch/m68k/kernel/vmlinux-nommu.lds +++ b/arch/m68k/kernel/vmlinux-nommu.lds @@ -82,7 +82,7 @@ SECTIONS { __init_end = .; } - BSS_SECTION(0, 0, 0) + BSS_SECTION(4, 0, 4) _end = .; -- cgit v1.2.3 From 8b22820efb35f93d98638563b0a8f4094e8ee399 Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Fri, 30 Oct 2020 15:26:24 +0100 Subject: m68k: m68328: remove duplicate code Building a kernel with multiple dragonball based boards enabled needlessly causes a link failure because of duplicate config_BSP() functions between the CPU versions. Avoid that merging the three almost identical files into one, and hiding the CPU configuration behind the board config. The pr_info() lines are consolidated in one place. It is still not possible to run a kernel configured for more than one board, but at least configurations that can be selected can also be built now. Signed-off-by: Arnd Bergmann Signed-off-by: Greg Ungerer --- arch/m68k/kernel/setup_no.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'arch/m68k/kernel') diff --git a/arch/m68k/kernel/setup_no.c b/arch/m68k/kernel/setup_no.c index f66f4b1d062e..58dbe10ccf56 100644 --- a/arch/m68k/kernel/setup_no.c +++ b/arch/m68k/kernel/setup_no.c @@ -106,8 +106,16 @@ void __init setup_arch(char **cmdline_p) #ifdef CONFIG_UCDIMM pr_info("uCdimm by Lineo, Inc. \n"); #endif +#ifdef CONFIG_M68328 + pr_info("68328 support D. Jeff Dionne \n"); + pr_info("68328 support Kenneth Albanowski \n"); +#endif +#ifdef CONFIG_M68EZ328 + pr_info("68EZ328 DragonBallEZ support (C) 1999 Rt-Control, Inc\n"); +#endif #ifdef CONFIG_M68VZ328 pr_info("M68VZ328 support by Evan Stawnyczy \n"); + pr_info("68VZ328 DragonBallVZ support (c) 2001 Lineo, Inc.\n"); #endif #ifdef CONFIG_COLDFIRE pr_info("COLDFIRE port done by Greg Ungerer, gerg@snapgear.com\n"); @@ -121,6 +129,7 @@ void __init setup_arch(char **cmdline_p) pr_info("Flat model support (C) 1998,1999 Kenneth Albanowski, D. Jeff Dionne\n"); #if defined( CONFIG_PILOT ) && defined( CONFIG_M68328 ) + pr_info("68328/Pilot support Bernhard Kuhn \n"); pr_info("TRG SuperPilot FLASH card support \n"); #endif #if defined( CONFIG_PILOT ) && defined( CONFIG_M68EZ328 ) -- cgit v1.2.3