Skip to content

Commit d4645d3

Browse files
Sebastian Andrzej Siewioringomolnar
authored andcommitted
smpboot: Place the __percpu annotation correctly
The test robot reported a wrong assignment of a per-CPU variable which it detected by using sparse and sent a report. The assignment itself is correct. The annotation for sparse was wrong and hence the report. The first pointer is a "normal" pointer and points to the per-CPU memory area. That means that the __percpu annotation has to be moved. Move the __percpu annotation to pointer which points to the per-CPU area. This change affects only the sparse tool (and is ignored by the compiler). Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: f97f8f0 ("smpboot: Provide infrastructure for percpu hotplug threads") Link: http://lkml.kernel.org/r/20190424085253.12178-1-bigeasy@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org>
1 parent de7b77e commit d4645d3

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎include/linux/smpboot.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ struct smpboot_thread_data;
2929
* @thread_comm: The base name of the thread
3030
*/
3131
struct smp_hotplug_thread {
32-
struct task_struct __percpu **store;
32+
struct task_struct * __percpu *store;
3333
struct list_head list;
3434
int (*thread_should_run)(unsigned int cpu);
3535
void (*thread_fn)(unsigned int cpu);

0 commit comments

Comments
 (0)