aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXie XiuQi <xiexiuqi@huawei.com>2013-07-29 23:06:09 -0400
committerIngo Molnar <mingo@kernel.org>2013-07-30 16:19:05 -0400
commit46591962cb5bfd2bfb0baf42497119c816503598 (patch)
tree68086c02d0921b98d149471daa18c6472d2bdf0d
parent323f54ed0f3ce20e9946c961fc928ccdb80d9345 (diff)
generic-ipi: Kill unnecessary variable - csd_flags
After commit 8969a5ede0f9e17da4b943712429aef2c9bcd82b ("generic-ipi: remove kmalloc()"), wait = 0 can be guaranteed, and all callsites of generic_exec_single() do an unconditional csd_lock() now. So csd_flags is unnecessary now. Remove it. Signed-off-by: Xie XiuQi <xiexiuqi@huawei.com> Signed-off-by: Peter Zijlstra <peterz@infradead.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Nick Piggin <npiggin@suse.de> Cc: Jens Axboe <jens.axboe@oracle.com> Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Link: http://lkml.kernel.org/r/51F72DA1.7010401@huawei.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r--kernel/smp.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/kernel/smp.c b/kernel/smp.c
index fe9f773d7114..7332697cd184 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -186,25 +186,13 @@ void generic_smp_call_function_single_interrupt(void)
186 186
187 while (!list_empty(&list)) { 187 while (!list_empty(&list)) {
188 struct call_single_data *csd; 188 struct call_single_data *csd;
189 unsigned int csd_flags;
190 189
191 csd = list_entry(list.next, struct call_single_data, list); 190 csd = list_entry(list.next, struct call_single_data, list);
192 list_del(&csd->list); 191 list_del(&csd->list);
193 192
194 /*
195 * 'csd' can be invalid after this call if flags == 0
196 * (when called through generic_exec_single()),
197 * so save them away before making the call:
198 */
199 csd_flags = csd->flags;
200
201 csd->func(csd->info); 193 csd->func(csd->info);
202 194
203 /* 195 csd_unlock(csd);
204 * Unlocked CSDs are valid through generic_exec_single():
205 */
206 if (csd_flags & CSD_FLAG_LOCK)
207 csd_unlock(csd);
208 } 196 }
209} 197}
210 198