History

smp: Cleanup smp_call_function*()

Get rid of the __call_single_node union and cleanup the API a little to avoid external code relying on the structure layout as much.

Peter Zijlstra committed 6 years ago

Commit 545b8c81 parent 7a9f50a13 files · +60 −94Browse files

Showing the changes to kernel/debug/debug_core.c (1 of 13 files). Show all

Unified · Split

kernel/debug/debug_core.c+3−3
@@ -225,8 +225,6 @@ NOKPROBE_SYMBOL(kgdb_skipexception); · 224 unmodified lines
225225 * Default (weak) implementation for kgdb_roundup_cpus
226226 */
227227
228−static DEFINE_PER_CPU(call_single_data_t, kgdb_roundup_csd);
229−
230228 void __weak kgdb_call_nmi_hook(void *ignored)
231229 {
232230 /*
@@ -241,6 +239,9 @@ void __weak kgdb_call_nmi_hook(void *ignored) · 8 unmodified lines
241239 }
242240 NOKPROBE_SYMBOL(kgdb_call_nmi_hook);
243241
242+static DEFINE_PER_CPU(call_single_data_t, kgdb_roundup_csd) =
243+ CSD_INIT(kgdb_call_nmi_hook, NULL);
244+
244245 void __weak kgdb_roundup_cpus(void)
245246 {
246247 call_single_data_t *csd;
@@ -267,7 +268,6 @@ void __weak kgdb_roundup_cpus(void) · 20 unmodified lines
267268 continue;
268269 kgdb_info[cpu].rounding_up = true;
269270
270− csd->func = kgdb_call_nmi_hook;
271271 ret = smp_call_function_single_async(cpu, csd);
272272 if (ret)
273273 kgdb_info[cpu].rounding_up = false;