From: liguang Date: Tue, 30 Apr 2013 22:27:26 +0000 (-0700) Subject: kernel/smp.c: remove 'priv' of call_single_data X-Git-Tag: v3.12-rc1~951^2~79 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3440a1ca99707f093e9568ba9762764d3162dd8f;p=kernel%2Fkernel-generic.git kernel/smp.c: remove 'priv' of call_single_data The 'priv' field is redundant; we can pass data via 'info'. Signed-off-by: liguang Cc: Peter Zijlstra Cc: Oleg Nesterov Cc: Ingo Molnar Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/include/linux/smp.h b/include/linux/smp.h index 3e07a7d..e6564c1 100644 --- a/include/linux/smp.h +++ b/include/linux/smp.h @@ -20,7 +20,6 @@ struct call_single_data { smp_call_func_t func; void *info; u16 flags; - u16 priv; }; /* total number of cpus in this system (may exceed NR_CPUS) */ diff --git a/kernel/softirq.c b/kernel/softirq.c index 14d7758..aa82723 100644 --- a/kernel/softirq.c +++ b/kernel/softirq.c @@ -620,8 +620,7 @@ static void remote_softirq_receive(void *data) unsigned long flags; int softirq; - softirq = cp->priv; - + softirq = *(int *)cp->info; local_irq_save(flags); __local_trigger(cp, softirq); local_irq_restore(flags); @@ -631,9 +630,8 @@ static int __try_remote_softirq(struct call_single_data *cp, int cpu, int softir { if (cpu_online(cpu)) { cp->func = remote_softirq_receive; - cp->info = cp; + cp->info = &softirq; cp->flags = 0; - cp->priv = softirq; __smp_call_function_single(cpu, cp, 0); return 0;