I want to compile the kernel on a pi4 host(target is pi3B), follow the document https://www.raspberrypi.com/documentati ... ernel.html, I run the commands:The host is a pi4, hostnamectl output:
Code:
sudo apt install git bc bison flex libssl-dev makegit clone --depth=1 https://github.com/raspberrypi/linuxcd linuxKERNEL=kernel8make bcm2711_defconfig## configuration written to .config#make -j4 Image modules dtbsSYNC include/config/auto.conf.cmdwarning: ld does not support --fix-cortex-a53-843419; kernel may be susceptible to erratumwarning: LSE atomics not supported by binutils CC kernel/bounds.s UPD include/generated/timeconst.hIn file included from ./arch/arm64/include/asm/lse.h:5, from ./arch/arm64/include/asm/cmpxchg.h:14, from ./arch/arm64/include/asm/atomic.h:16, from ./include/linux/atomic.h:7, from ./include/asm-generic/bitops/atomic.h:5, from ./arch/arm64/include/asm/bitops.h:25, from ./include/linux/bitops.h:68, from ./include/linux/log2.h:12, from kernel/bounds.c:13:./arch/arm64/include/asm/atomic_ll_sc.h:298:2: error: unknown type name ‘u128’ 298 | u128 full; | ^~~~ ./arch/arm64/include/asm/atomic_ll_sc.h:305:24: error: unknown type name ‘u128’ 305 | static __always_inline u128 \ | ^~~~./arch/arm64/include/asm/atomic_ll_sc.h:332:1: note: in expansion of macro ‘__CMPXCHG128’ 332 | __CMPXCHG128( , , ) | ^~~~~~~~~~~~./arch/arm64/include/asm/atomic_ll_sc.h:306:36: error: unknown type name ‘u128’ 306 | __ll_sc__cmpxchg128##name(volatile u128 *ptr, u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/atomic_ll_sc.h:332:1: note: in expansion of macro ‘__CMPXCHG128’ 332 | __CMPXCHG128( , , ) | ^~~~~~~~~~~~ ./arch/arm64/include/asm/atomic_ll_sc.h:306:47: error: unknown type name ‘u128’ 306 | __ll_sc__cmpxchg128##name(volatile u128 *ptr, u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/atomic_ll_sc.h:332:1: note: in expansion of macro ‘__CMPXCHG128’ 332 | __CMPXCHG128( , , ) | ^~~~~~~~~~~~./arch/arm64/include/asm/atomic_ll_sc.h:306:57: error: unknown type name ‘u128’ 306 | __ll_sc__cmpxchg128##name(volatile u128 *ptr, u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/atomic_ll_sc.h:332:1: note: in expansion of macro ‘__CMPXCHG128’ 332 | __CMPXCHG128( , , ) | ^~~~~~~~~~~~./arch/arm64/include/asm/atomic_ll_sc.h:305:24: error: unknown type name ‘u128’ 305 | static __always_inline u128 \ | ^~~~ ./arch/arm64/include/asm/atomic_ll_sc.h:333:1: note: in expansion of macro ‘__CMPXCHG128’ 333 | __CMPXCHG128(_mb, dmb ish, l, "memory") | ^~~~~~~~~~~~./arch/arm64/include/asm/atomic_ll_sc.h:306:36: error: unknown type name ‘u128’ 306 | __ll_sc__cmpxchg128##name(volatile u128 *ptr, u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/atomic_ll_sc.h:333:1: note: in expansion of macro ‘__CMPXCHG128’ 333 | __CMPXCHG128(_mb, dmb ish, l, "memory") | ^~~~~~~~~~~~./arch/arm64/include/asm/atomic_ll_sc.h:306:47: error: unknown type name ‘u128’ 306 | __ll_sc__cmpxchg128##name(volatile u128 *ptr, u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/atomic_ll_sc.h:333:1: note: in expansion of macro ‘__CMPXCHG128’ 333 | __CMPXCHG128(_mb, dmb ish, l, "memory") | ^~~~~~~~~~~~./arch/arm64/include/asm/atomic_ll_sc.h:306:57: error: unknown type name ‘u128’ 306 | __ll_sc__cmpxchg128##name(volatile u128 *ptr, u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/atomic_........./arch/arm64/include/asm/cmpxchg.h:142:1: note: in expansion of macro ‘__CMPXCHG128’ 142 | __CMPXCHG128(_mb) | ^~~~~~~~~~~~./arch/arm64/include/asm/cmpxchg.h:135:21: error: unknown type name ‘u128’ 135 | u128 old, u128 new) \ | ^~~~./arch/arm64/include/asm/cmpxchg.h:142:1: note: in expansion of macro ‘__CMPXCHG128’ 142 | __CMPXCHG128(_mb) | ^~~~~~~~~~~~make[2]: *** [scripts/Makefile.build:116:kernel/bounds.s] 错误 1make[1]: *** [/root/linux-rpi-6.6.y/Makefile:1202:prepare0] 错误 2make: *** [Makefile:234:__sub-make] 错误 2
Code:
Static hostname: rpi-bullseye-armhf Icon name: computer Machine ID: 008cf0926c7c4fa6b0e80298c964fe39 Boot ID: b22ef6ae569441f59b046bf0547221f0 Operating System: Raspbian GNU/Linux 11 (bullseye) Kernel: Linux 6.1.21-v8+ Architecture: arm64
Statistics: Posted by chengjianwen — Sat Apr 13, 2024 1:28 am