Re: [rcu:dev.2020.04.03a 101/101] kernel/rcu/tasks.h:251:9: error: 'struct task_struct' has no member named 'rcu_tasks_idx'
From: Paul E. McKenney
Date: Mon Apr 06 2020 - 09:37:12 EST
On Mon, Apr 06, 2020 at 08:09:14AM +0800, kbuild test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git dev.2020.04.03a
> head: 8c64539e2d8fbd96ad4bb60a96c5d9c1ef823572
> commit: 8c64539e2d8fbd96ad4bb60a96c5d9c1ef823572 [101/101] squash! ftrace: Use synchronize_rcu_tasks_rude() instead of ftrace_sync()
> config: powerpc-defconfig (attached as .config)
> compiler: powerpc64-linux-gcc (GCC) 9.3.0
> reproduce:
> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> chmod +x ~/bin/make.cross
> git checkout 8c64539e2d8fbd96ad4bb60a96c5d9c1ef823572
> # save the attached .config to linux build tree
> GCC_VERSION=9.3.0 make.cross ARCH=powerpc
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kbuild test robot <lkp@xxxxxxxxx>
Messed up the Kconfig, and I have an alleged fix in -rcu which will be
squashed into the offending commit with attribution.
Thanx, Paul
> All errors (new ones prefixed by >>):
>
> In file included from kernel/rcu/update.c:563:
> kernel/rcu/tasks.h: In function 'exit_tasks_rcu_start':
> >> kernel/rcu/tasks.h:251:9: error: 'struct task_struct' has no member named 'rcu_tasks_idx'
> 251 | current->rcu_tasks_idx = __srcu_read_lock(&tasks_rcu_exit_srcu);
> | ^~
> kernel/rcu/tasks.h: In function 'exit_tasks_rcu_finish':
> kernel/rcu/tasks.h:263:44: error: 'struct task_struct' has no member named 'rcu_tasks_idx'
> 263 | __srcu_read_unlock(&tasks_rcu_exit_srcu, t->rcu_tasks_idx);
> | ^~
>
> vim +251 kernel/rcu/tasks.h
>
> dfdddf06801dcb Paul E. McKenney 2020-03-03 246
> dfdddf06801dcb Paul E. McKenney 2020-03-03 247 /* Do the srcu_read_lock() for the above synchronize_srcu(). */
> dfdddf06801dcb Paul E. McKenney 2020-03-03 248 void exit_tasks_rcu_start(void) __acquires(&tasks_rcu_exit_srcu)
> dfdddf06801dcb Paul E. McKenney 2020-03-03 249 {
> dfdddf06801dcb Paul E. McKenney 2020-03-03 250 preempt_disable();
> dfdddf06801dcb Paul E. McKenney 2020-03-03 @251 current->rcu_tasks_idx = __srcu_read_lock(&tasks_rcu_exit_srcu);
> dfdddf06801dcb Paul E. McKenney 2020-03-03 252 preempt_enable();
> 4dbad397293c85 Paul E. McKenney 2020-03-02 253 }
> dfdddf06801dcb Paul E. McKenney 2020-03-03 254
>
> :::::: The code at line 251 was first introduced by commit
> :::::: dfdddf06801dcbee9f3ab515aad75421b3e3e75f rcu-tasks: Refactor RCU-tasks to allow variants to be added
>
> :::::: TO: Paul E. McKenney <paulmck@xxxxxxxxxx>
> :::::: CC: Paul E. McKenney <paulmck@xxxxxxxxxx>
>
> ---
> 0-DAY CI Kernel Test Service, Intel Corporation
> https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx