diff options
author | Frederic Weisbecker <fweisbec@gmail.com> | 2015-09-04 18:45:06 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-09-04 19:54:41 -0400 |
commit | 230ec93909f00678401cb2d63b8b95f1dea68e40 (patch) | |
tree | 1eb01a44e0d66d76306f598d595a4bdaccd21b64 /include/linux/smpboot.h | |
parent | 3dd08c0c918f9bf058572ddbf26e7d6fb5674a5c (diff) |
smpboot: allow passing the cpumask on per-cpu thread registration
It makes the registration cheaper and simpler for the smpboot per-cpu
kthread users that don't need to always update the cpumask after threads
creation.
[sfr@canb.auug.org.au: fix for allow passing the cpumask on per-cpu thread registration]
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Reviewed-by: Chris Metcalf <cmetcalf@ezchip.com>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Chris Metcalf <cmetcalf@ezchip.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/smpboot.h')
-rw-r--r-- | include/linux/smpboot.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/include/linux/smpboot.h b/include/linux/smpboot.h index da3c593f9845..e6109a6cd8f6 100644 --- a/include/linux/smpboot.h +++ b/include/linux/smpboot.h | |||
@@ -48,7 +48,16 @@ struct smp_hotplug_thread { | |||
48 | const char *thread_comm; | 48 | const char *thread_comm; |
49 | }; | 49 | }; |
50 | 50 | ||
51 | int smpboot_register_percpu_thread(struct smp_hotplug_thread *plug_thread); | 51 | int smpboot_register_percpu_thread_cpumask(struct smp_hotplug_thread *plug_thread, |
52 | const struct cpumask *cpumask); | ||
53 | |||
54 | static inline int | ||
55 | smpboot_register_percpu_thread(struct smp_hotplug_thread *plug_thread) | ||
56 | { | ||
57 | return smpboot_register_percpu_thread_cpumask(plug_thread, | ||
58 | cpu_possible_mask); | ||
59 | } | ||
60 | |||
52 | void smpboot_unregister_percpu_thread(struct smp_hotplug_thread *plug_thread); | 61 | void smpboot_unregister_percpu_thread(struct smp_hotplug_thread *plug_thread); |
53 | int smpboot_update_cpumask_percpu_thread(struct smp_hotplug_thread *plug_thread, | 62 | int smpboot_update_cpumask_percpu_thread(struct smp_hotplug_thread *plug_thread, |
54 | const struct cpumask *); | 63 | const struct cpumask *); |