lkml.org 
[lkml]   [2021]   [Oct]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subject[frederic-dynticks:preempt/arm-v2 2/4] arch/arm64/kernel/patching.c:93:6: warning: no previous prototype for 'arch_static_call_transform'
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git preempt/arm-v2
head: 5700542b609d9ab640210d7dd93621c7967688e6
commit: ede0a4b67ffccf492192c29ee88076d2abb8119b [2/4] arm64: implement support for static call trampolines
config: arm64-defconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 11.2.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/frederic/linux-dynticks.git/commit/?id=ede0a4b67ffccf492192c29ee88076d2abb8119b
git remote add frederic-dynticks https://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git
git fetch --no-tags frederic-dynticks preempt/arm-v2
git checkout ede0a4b67ffccf492192c29ee88076d2abb8119b
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=arm64

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

All warnings (new ones prefixed by >>):

>> arch/arm64/kernel/patching.c:93:6: warning: no previous prototype for 'arch_static_call_transform' [-Wmissing-prototypes]
93 | void arch_static_call_transform(void *site, void *tramp, void *func, bool tail)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~


vim +/arch_static_call_transform +93 arch/arm64/kernel/patching.c

92
> 93 void arch_static_call_transform(void *site, void *tramp, void *func, bool tail)
94 {
95 /*
96 * -0x8 <literal>
97 * 0x0 bti c <--- trampoline entry point
98 * 0x4 <branch or nop>
99 * 0x8 ldr x16, <literal>
100 * 0xc cbz x16, 20
101 * 0x10 br x16
102 * 0x14 ret
103 */
104 struct {
105 u64 literal;
106 __le32 insn[2];
107 } insns;
108 u32 insn;
109 int ret;
110
111 insn = aarch64_insn_gen_hint(AARCH64_INSN_HINT_BTIC);
112 insns.literal = (u64)func;
113 insns.insn[0] = cpu_to_le32(insn);
114
115 if (!func) {
116 insn = aarch64_insn_gen_branch_reg(AARCH64_INSN_REG_LR,
117 AARCH64_INSN_BRANCH_RETURN);
118 } else {
119 insn = aarch64_insn_gen_branch_imm((u64)tramp + 4, (u64)func,
120 AARCH64_INSN_BRANCH_NOLINK);
121
122 /*
123 * Use a NOP if the branch target is out of range, and rely on
124 * the indirect call instead.
125 */
126 if (insn == AARCH64_BREAK_FAULT)
127 insn = aarch64_insn_gen_hint(AARCH64_INSN_HINT_NOP);
128 }
129 insns.insn[1] = cpu_to_le32(insn);
130
131 ret = __aarch64_insn_write(tramp - 8, &insns, sizeof(insns));
132 if (!WARN_ON(ret))
133 caches_clean_inval_pou((u64)tramp - 8, sizeof(insns));
134 }
135

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[unhandled content-type:application/gzip]
\
 
 \ /
  Last update: 2021-10-26 07:16    [W:0.030 / U:0.552 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site