[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <b7512db9-e3bc-7a88-d7e3-86110e63215c@I-love.SAKURA.ne.jp>
Date: Tue, 19 Jul 2022 19:19:25 +0900
From: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
kernel test robot <lkp@...el.com>
Subject: Re: arch/arm/include/asm/system_misc.h:29:9: error: implicit
declaration of function 'preempt_enable_no_resched_notrace'; did you mean
'preempt_enable_notrace'?
Commit 502825282e6f79c9 ("ftrace: add preempt_enable/disable notrace macros")
introduced preempt_enable_no_resched_notrace(), but kernel test robot says that
preempt_enable_no_resched_notrace() is conditionally defined. Why conditionally?
On 2022/07/17 11:04, kernel test robot wrote:
> tree: https://github.com/intel-lab-lkp/linux/commits/UPDATE-20220717-000210/Tetsuo-Handa/ARM-spectre-v2-fix-smp_processor_id-warning/20220622-145116
> head: 7c8920bd674d371b04dc1ee0e0c6b8af89e55987
> commit: 7c8920bd674d371b04dc1ee0e0c6b8af89e55987 ARM: spectre-v2: fix smp_processor_id() warning
> date: 10 hours ago
> config: arm-omap2plus_defconfig (https://download.01.org/0day-ci/archive/20220717/202207170947.p1AZIs0b-lkp@intel.com/config)
> compiler: arm-linux-gnueabi-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://github.com/intel-lab-lkp/linux/commit/7c8920bd674d371b04dc1ee0e0c6b8af89e55987
> git remote add linux-review https://github.com/intel-lab-lkp/linux
> git fetch --no-tags linux-review UPDATE-20220717-000210/Tetsuo-Handa/ARM-spectre-v2-fix-smp_processor_id-warning/20220622-145116
> git checkout 7c8920bd674d371b04dc1ee0e0c6b8af89e55987
> # 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=arm SHELL=/bin/bash drivers/soc/ti/
>
> If you fix the issue, kindly add following tag where applicable
> Reported-by: kernel test robot <lkp@...el.com>
>
> All errors (new ones prefixed by >>):
>
> In file included from drivers/soc/ti/pm33xx.c:33:
> arch/arm/include/asm/system_misc.h: In function 'harden_branch_predictor':
>>> arch/arm/include/asm/system_misc.h:29:9: error: implicit declaration of function 'preempt_enable_no_resched_notrace'; did you mean 'preempt_enable_notrace'? [-Werror=implicit-function-declaration]
> 29 | preempt_enable_no_resched_notrace();
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> | preempt_enable_notrace
> cc1: some warnings being treated as errors
>
>
> vim +29 arch/arm/include/asm/system_misc.h
>
> 17
> 18 #ifdef CONFIG_HARDEN_BRANCH_PREDICTOR
> 19 typedef void (*harden_branch_predictor_fn_t)(void);
> 20 DECLARE_PER_CPU(harden_branch_predictor_fn_t, harden_branch_predictor_fn);
> 21 static inline void harden_branch_predictor(void)
> 22 {
> 23 harden_branch_predictor_fn_t fn;
> 24
> 25 preempt_disable_notrace();
> 26 fn = per_cpu(harden_branch_predictor_fn, raw_smp_processor_id());
> 27 if (fn)
> 28 fn();
> > 29 preempt_enable_no_resched_notrace();
> 30 }
> 31 #else
> 32 #define harden_branch_predictor() do { } while (0)
> 33 #endif
> 34
>
Powered by blists - more mailing lists