# git rev-parse -q --verify 792993919349fefba20f58ae4843c80e8b01f518^{commit} 792993919349fefba20f58ae4843c80e8b01f518 already have revision, skipping fetch # git checkout -q -f -B kisskb 792993919349fefba20f58ae4843c80e8b01f518 # git clean -qxdf # < git log -1 # commit 792993919349fefba20f58ae4843c80e8b01f518 # Author: Christophe Leroy # Date: Fri Feb 11 15:16:51 2022 +0100 # # powerpc/64: Force inlining of prevent_user_access() and set_kuap() # # A ppc64_defconfig build exhibits about 10 copied of # prevent_user_access(). It also have one copy of set_kuap(). # # c000000000017340 <.prevent_user_access.constprop.0>: # c00000000001a038: 4b ff d3 09 bl c000000000017340 <.prevent_user_access.constprop.0> # c00000000001aabc: 4b ff c8 85 bl c000000000017340 <.prevent_user_access.constprop.0> # c00000000001ab38: 4b ff c8 09 bl c000000000017340 <.prevent_user_access.constprop.0> # c00000000001ade0: 4b ff c5 61 bl c000000000017340 <.prevent_user_access.constprop.0> # c000000000039b90 <.prevent_user_access.constprop.0>: # c00000000003ac08: 4b ff ef 89 bl c000000000039b90 <.prevent_user_access.constprop.0> # c00000000003b9d0: 4b ff e1 c1 bl c000000000039b90 <.prevent_user_access.constprop.0> # c00000000003ba54: 4b ff e1 3d bl c000000000039b90 <.prevent_user_access.constprop.0> # c00000000003bbfc: 4b ff df 95 bl c000000000039b90 <.prevent_user_access.constprop.0> # c00000000015dde0 <.prevent_user_access.constprop.0>: # c0000000001612c0: 4b ff cb 21 bl c00000000015dde0 <.prevent_user_access.constprop.0> # c000000000161b54: 4b ff c2 8d bl c00000000015dde0 <.prevent_user_access.constprop.0> # c000000000188cf0 <.prevent_user_access.constprop.0>: # c00000000018d658: 4b ff b6 99 bl c000000000188cf0 <.prevent_user_access.constprop.0> # c00000000030fe20 <.prevent_user_access.constprop.0>: # c0000000003123d4: 4b ff da 4d bl c00000000030fe20 <.prevent_user_access.constprop.0> # c000000000313970: 4b ff c4 b1 bl c00000000030fe20 <.prevent_user_access.constprop.0> # c0000000005e6bd0 <.prevent_user_access.constprop.0>: # c0000000005e7d8c: 4b ff ee 45 bl c0000000005e6bd0 <.prevent_user_access.constprop.0> # c0000000007bcae0 <.prevent_user_access.constprop.0>: # c0000000007bda10: 4b ff f0 d1 bl c0000000007bcae0 <.prevent_user_access.constprop.0> # c0000000007bda54: 4b ff f0 8d bl c0000000007bcae0 <.prevent_user_access.constprop.0> # c0000000007bdd28: 4b ff ed b9 bl c0000000007bcae0 <.prevent_user_access.constprop.0> # c0000000007c0390: 4b ff c7 51 bl c0000000007bcae0 <.prevent_user_access.constprop.0> # c00000000094e4f0 <.prevent_user_access.constprop.0>: # c000000000950e40: 4b ff d6 b1 bl c00000000094e4f0 <.prevent_user_access.constprop.0> # c00000000097d2d0 <.prevent_user_access.constprop.0>: # c0000000009813fc: 4b ff be d5 bl c00000000097d2d0 <.prevent_user_access.constprop.0> # c000000000acd540 <.prevent_user_access.constprop.0>: # c000000000ad1d60: 4b ff b7 e1 bl c000000000acd540 <.prevent_user_access.constprop.0> # c000000000e5d680 <.prevent_user_access.constprop.0>: # c000000000e64b60: 4b ff 8b 21 bl c000000000e5d680 <.prevent_user_access.constprop.0> # c000000000e64b6c: 4b ff 8b 15 bl c000000000e5d680 <.prevent_user_access.constprop.0> # c000000000e64c38: 4b ff 8a 49 bl c000000000e5d680 <.prevent_user_access.constprop.0> # # When building signal_64.c with -Winline the following messages appear: # # ./arch/powerpc/include/asm/book3s/64/kup.h:331:20: error: inlining failed in call to 'set_kuap': call is unlikely and code size would grow [-Werror=inline] # ./arch/powerpc/include/asm/book3s/64/kup.h:401:20: error: inlining failed in call to 'prevent_user_access.constprop': call is unlikely and code size would grow [-Werror=inline] # # Those functions are used on hot pathes and have been # expected to be inlined at all time. # # Force them inline. # # This patch reduces the kernel text size by 700 bytes, confirming # that not inlining those functions is not worth it. # # Signed-off-by: Christophe Leroy # Signed-off-by: Michael Ellerman # Link: https://lore.kernel.org/r/eff9b2b211957fa2e8707e46f31674097fd563a3.1644588972.git.christophe.leroy@csgroup.eu # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-ld --version # < git log --format=%s --max-count=1 792993919349fefba20f58ae4843c80e8b01f518 # < make -s -j 32 ARCH=x86 O=/kisskb/build/powerpc-next_x86-allmodconfig_x86_64-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux- allmodconfig # Added to kconfig CONFIG_BUILD_DOCSRC=n # Added to kconfig CONFIG_MODULE_SIG=n # Added to kconfig CONFIG_SAMPLES=n # < make -s -j 32 ARCH=x86 O=/kisskb/build/powerpc-next_x86-allmodconfig_x86_64-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux- help # make -s -j 32 ARCH=x86 O=/kisskb/build/powerpc-next_x86-allmodconfig_x86_64-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux- olddefconfig # make -s -j 32 ARCH=x86 O=/kisskb/build/powerpc-next_x86-allmodconfig_x86_64-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux- /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-objdump: mm/kfence/kfence_test.o: unable to initialize decompress status for section .debug_info /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-objdump: mm/kfence/kfence_test.o: unable to initialize decompress status for section .debug_info /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-objdump: mm/kfence/kfence_test.o: File format not recognized vmlinux.o: warning: objtool: __do_fast_syscall_32()+0xa: call to stackleak_track_stack() leaves .noinstr.text section vmlinux.o: warning: objtool: do_syscall_64()+0x8: call to stackleak_track_stack() leaves .noinstr.text section vmlinux.o: warning: objtool: do_int80_syscall_32()+0x8: call to stackleak_track_stack() leaves .noinstr.text section vmlinux.o: warning: objtool: exc_general_protection()+0x24: call to stackleak_track_stack() leaves .noinstr.text section vmlinux.o: warning: objtool: fixup_bad_iret()+0x21: call to stackleak_track_stack() leaves .noinstr.text section vmlinux.o: warning: objtool: do_machine_check()+0x27: call to stackleak_track_stack() leaves .noinstr.text section vmlinux.o: warning: objtool: .text+0x4580e: call to stackleak_erase() leaves .noinstr.text section vmlinux.o: warning: objtool: .entry.text+0x143: call to stackleak_erase() leaves .noinstr.text section vmlinux.o: warning: objtool: .entry.text+0x10eb: call to stackleak_erase() leaves .noinstr.text section vmlinux.o: warning: objtool: .entry.text+0x17f9: call to stackleak_erase() leaves .noinstr.text section /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-ld: mm/kfence/kfence_test.o: unable to initialize decompress status for section .debug_info /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-ld: mm/kfence/kfence_test.o: unable to initialize decompress status for section .debug_info /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-ld: mm/kfence/kfence_test.o: unable to initialize decompress status for section .debug_info /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux-ld: mm/kfence/kfence_test.o: unable to initialize decompress status for section .debug_info mm/kfence/kfence_test.o: file not recognized: File format not recognized make[3]: *** [/kisskb/src/scripts/Makefile.modfinal:60: mm/kfence/kfence_test.ko] Error 1 make[3]: *** Waiting for unfinished jobs.... make[2]: *** [/kisskb/src/scripts/Makefile.modpost:140: __modpost] Error 2 make[1]: *** [/kisskb/src/Makefile:1746: modules] Error 2 make: *** [Makefile:219: __sub-make] Error 2 Command 'make -s -j 32 ARCH=x86 O=/kisskb/build/powerpc-next_x86-allmodconfig_x86_64-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/x86_64-linux/bin/x86_64-linux- ' returned non-zero exit status 2 # rm -rf /kisskb/build/powerpc-next_x86-allmodconfig_x86_64-gcc8 # Build took: 0:33:43.188354