lkml.org 
[lkml]   [2022]   [Jul]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectarch/arm64/kernel/proton-pack.c:1054:14: warning: no previous prototype for 'spectre_bhb_patch_loop_iter'
Hi James,

FYI, the error/warning still remains.

tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 515f71412bb73ebd7f41f90e1684fc80b8730789
commit: 558c303c9734af5a813739cd284879227f7297d2 arm64: Mitigate spectre style branch history side channels
date: 5 months ago
config: arm64-alldefconfig (https://download.01.org/0day-ci/archive/20220724/202207240834.nGEiT8tH-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 12.1.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=558c303c9734af5a813739cd284879227f7297d2
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 558c303c9734af5a813739cd284879227f7297d2
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash arch/arm64/kernel/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

arch/arm64/kernel/proton-pack.c:564:13: warning: no previous prototype for 'spectre_v4_patch_fw_mitigation_enable' [-Wmissing-prototypes]
564 | void __init spectre_v4_patch_fw_mitigation_enable(struct alt_instr *alt,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/kernel/proton-pack.c:584:13: warning: no previous prototype for 'smccc_patch_fw_mitigation_conduit' [-Wmissing-prototypes]
584 | void __init smccc_patch_fw_mitigation_conduit(struct alt_instr *alt,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/kernel/proton-pack.c:1032:14: warning: no previous prototype for 'spectre_bhb_patch_loop_mitigation_enable' [-Wmissing-prototypes]
1032 | void noinstr spectre_bhb_patch_loop_mitigation_enable(struct alt_instr *alt,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/kernel/proton-pack.c:1043:14: warning: no previous prototype for 'spectre_bhb_patch_fw_mitigation_enabled' [-Wmissing-prototypes]
1043 | void noinstr spectre_bhb_patch_fw_mitigation_enabled(struct alt_instr *alt,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/arm64/kernel/proton-pack.c:1054:14: warning: no previous prototype for 'spectre_bhb_patch_loop_iter' [-Wmissing-prototypes]
1054 | void noinstr spectre_bhb_patch_loop_iter(struct alt_instr *alt,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/arm64/kernel/proton-pack.c:1075:14: warning: no previous prototype for 'spectre_bhb_patch_wa3' [-Wmissing-prototypes]
1075 | void noinstr spectre_bhb_patch_wa3(struct alt_instr *alt,
| ^~~~~~~~~~~~~~~~~~~~~


vim +/spectre_bhb_patch_loop_iter +1054 arch/arm64/kernel/proton-pack.c

1052
1053 /* Patched to correct the immediate */
> 1054 void noinstr spectre_bhb_patch_loop_iter(struct alt_instr *alt,
1055 __le32 *origptr, __le32 *updptr, int nr_inst)
1056 {
1057 u8 rd;
1058 u32 insn;
1059 u16 loop_count = spectre_bhb_loop_affected(SCOPE_SYSTEM);
1060
1061 BUG_ON(nr_inst != 1); /* MOV -> MOV */
1062
1063 if (!IS_ENABLED(CONFIG_MITIGATE_SPECTRE_BRANCH_HISTORY))
1064 return;
1065
1066 insn = le32_to_cpu(*origptr);
1067 rd = aarch64_insn_decode_register(AARCH64_INSN_REGTYPE_RD, insn);
1068 insn = aarch64_insn_gen_movewide(rd, loop_count, 0,
1069 AARCH64_INSN_VARIANT_64BIT,
1070 AARCH64_INSN_MOVEWIDE_ZERO);
1071 *updptr++ = cpu_to_le32(insn);
1072 }
1073
1074 /* Patched to mov WA3 when supported */
> 1075 void noinstr spectre_bhb_patch_wa3(struct alt_instr *alt,

--
0-DAY CI Kernel Test Service
https://01.org/lkp

\
 
 \ /
  Last update: 2022-07-24 02:14    [W:0.084 / U:0.080 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site