tree:
https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git sched/core
head: 560d2f906d7e7d006e5a4e0eafee8fcbc08830c5
commit: 048fdc63c8cd7e02182aea366a37e9b7665277f5 [1/3] sched: Fix balance_callback()
config: mips-randconfig-r005-20200909 (attached as .config)
compiler: clang version 12.0.0 (
https://github.com/llvm/llvm-project
0a5dc7effb191eff740e0e7ae7bd8e1f6bdb3ad9)
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
# install mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
git checkout 048fdc63c8cd7e02182aea366a37e9b7665277f5
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from kernel/sched/swait.c:5:
> kernel/sched/sched.h:1224:20: error: no member named
'balance_callback' in 'struct rq'
SCHED_WARN_ON(rq->balance_callback);
~~ ^
kernel/sched/sched.h:82:37: note: expanded from macro 'SCHED_WARN_ON'
# define SCHED_WARN_ON(x) WARN_ONCE(x, #x)
^
include/asm-generic/bug.h:157:27: note: expanded from macro 'WARN_ONCE'
int __ret_warn_once = !!(condition); \
^~~~~~~~~
1 error generated.
--
In file included from kernel/sched/core.c:13:
> kernel/sched/sched.h:1224:20: error: no member named
'balance_callback' in 'struct rq'
SCHED_WARN_ON(rq->balance_callback);
~~ ^
kernel/sched/sched.h:82:37: note: expanded from macro 'SCHED_WARN_ON'
# define SCHED_WARN_ON(x) WARN_ONCE(x, #x)
^
include/asm-generic/bug.h:157:27: note: expanded from macro 'WARN_ONCE'
int __ret_warn_once = !!(condition); \
^~~~~~~~~
kernel/sched/core.c:4660:35: warning: no previous prototype for function
'schedule_user' [-Wmissing-prototypes]
asmlinkage __visible void __sched schedule_user(void)
^
kernel/sched/core.c:4660:22: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage __visible void __sched schedule_user(void)
^
static
> kernel/sched/core.c:5483:9: error: implicit declaration of
function 'splice_balance_callbacks' [-Werror,-Wimplicit-function-declaration]
head = splice_balance_callbacks(rq);
^
kernel/sched/core.c:5483:9: note: did you mean '__balance_callbacks'?
kernel/sched/core.c:3540:20: note: '__balance_callbacks' declared here
static inline void __balance_callbacks(struct rq *rq)
^
kernel/sched/core.c:5483:7: warning: incompatible integer to pointer conversion
assigning to 'struct callback_head *' from 'int' [-Wint-conversion]
head = splice_balance_callbacks(rq);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings and 2 errors generated.
--
In file included from kernel/sched/fair.c:23:
> kernel/sched/sched.h:1224:20: error: no member named
'balance_callback' in 'struct rq'
SCHED_WARN_ON(rq->balance_callback);
~~ ^
kernel/sched/sched.h:82:37: note: expanded from macro 'SCHED_WARN_ON'
# define SCHED_WARN_ON(x) WARN_ONCE(x, #x)
^
include/asm-generic/bug.h:157:27: note: expanded from macro 'WARN_ONCE'
int __ret_warn_once = !!(condition); \
^~~~~~~~~
kernel/sched/fair.c:5364:6: warning: no previous prototype for function
'init_cfs_bandwidth' [-Wmissing-prototypes]
void init_cfs_bandwidth(struct cfs_bandwidth *cfs_b) {}
^
kernel/sched/fair.c:5364:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void init_cfs_bandwidth(struct cfs_bandwidth *cfs_b) {}
^
static
kernel/sched/fair.c:11113:6: warning: no previous prototype for function
'free_fair_sched_group' [-Wmissing-prototypes]
void free_fair_sched_group(struct task_group *tg) { }
^
kernel/sched/fair.c:11113:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void free_fair_sched_group(struct task_group *tg) { }
^
static
kernel/sched/fair.c:11115:5: warning: no previous prototype for function
'alloc_fair_sched_group' [-Wmissing-prototypes]
int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent)
^
kernel/sched/fair.c:11115:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent)
^
static
kernel/sched/fair.c:11120:6: warning: no previous prototype for function
'online_fair_sched_group' [-Wmissing-prototypes]
void online_fair_sched_group(struct task_group *tg) { }
^
kernel/sched/fair.c:11120:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void online_fair_sched_group(struct task_group *tg) { }
^
static
kernel/sched/fair.c:11122:6: warning: no previous prototype for function
'unregister_fair_sched_group' [-Wmissing-prototypes]
void unregister_fair_sched_group(struct task_group *tg) { }
^
kernel/sched/fair.c:11122:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void unregister_fair_sched_group(struct task_group *tg) { }
^
static
5 warnings and 1 error generated.
--
In file included from kernel/sched/rt.c:6:
> kernel/sched/sched.h:1224:20: error: no member named
'balance_callback' in 'struct rq'
SCHED_WARN_ON(rq->balance_callback);
~~ ^
kernel/sched/sched.h:82:37: note: expanded from macro 'SCHED_WARN_ON'
# define SCHED_WARN_ON(x) WARN_ONCE(x, #x)
^
include/asm-generic/bug.h:157:27: note: expanded from macro 'WARN_ONCE'
int __ret_warn_once = !!(condition); \
^~~~~~~~~
kernel/sched/rt.c:253:6: warning: no previous prototype for function
'free_rt_sched_group' [-Wmissing-prototypes]
void free_rt_sched_group(struct task_group *tg) { }
^
kernel/sched/rt.c:253:1: note: declare 'static' if the function is not intended
to be used outside of this translation unit
void free_rt_sched_group(struct task_group *tg) { }
^
static
kernel/sched/rt.c:255:5: warning: no previous prototype for function
'alloc_rt_sched_group' [-Wmissing-prototypes]
int alloc_rt_sched_group(struct task_group *tg, struct task_group *parent)
^
kernel/sched/rt.c:255:1: note: declare 'static' if the function is not intended
to be used outside of this translation unit
int alloc_rt_sched_group(struct task_group *tg, struct task_group *parent)
^
static
kernel/sched/rt.c:668:6: warning: no previous prototype for function
'sched_rt_bandwidth_account' [-Wmissing-prototypes]
bool sched_rt_bandwidth_account(struct rt_rq *rt_rq)
^
kernel/sched/rt.c:668:1: note: declare 'static' if the function is not intended
to be used outside of this translation unit
bool sched_rt_bandwidth_account(struct rt_rq *rt_rq)
^
static
3 warnings and 1 error generated.
#
https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git/commit/?...
git remote add peterz-queue
https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
git fetch --no-tags peterz-queue sched/core
git checkout 048fdc63c8cd7e02182aea366a37e9b7665277f5
vim +1224 kernel/sched/sched.h
1205
1206 /*
1207 * Lockdep annotation that avoids accidental unlocks; it's like a
1208 * sticky/continuous lockdep_assert_held().
1209 *
1210 * This avoids code that has access to 'struct rq *rq' (basically
everything in
1211 * the scheduler) from accidentally unlocking the rq if they do not also have a
1212 * copy of the (on-stack) 'struct rq_flags rf'.
1213 *
1214 * Also see Documentation/locking/lockdep-design.rst.
1215 */
1216 static inline void rq_pin_lock(struct rq *rq, struct rq_flags *rf)
1217 {
1218 rf->cookie = lockdep_pin_lock(&rq->lock);
1219
1220 #ifdef CONFIG_SCHED_DEBUG
1221 rq->clock_update_flags &= (RQCF_REQ_SKIP|RQCF_ACT_SKIP);
1222 rf->clock_update_flags = 0;
1223
1224 SCHED_WARN_ON(rq->balance_callback);
1225 #endif
1226 }
1227
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org