diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2012-08-27 09:43:49 -0400 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2012-09-26 09:44:53 -0400 |
commit | 1c725922dd8274b6e0b370ad33cfaef9013fd70b (patch) | |
tree | bbb73a34f41d5772b100d629b1fffbcf0c612622 /arch | |
parent | 0d0e471b46d4ba1de4617d04cf071c6ae4a5df76 (diff) |
s390/cpu hotplug: mask out CPU_TASKS_FROZEN in cu hotplug notifiers
Unify all our cpu hotplug notifiers to mask out the CPU_TASKS_FROZEN
bit, so we don't have to add all the *_FROZEN variant cases to the
notifiers.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/s390/kernel/smp.c | 4 | ||||
-rw-r--r-- | arch/s390/kernel/vtime.c | 3 | ||||
-rw-r--r-- | arch/s390/mm/fault.c | 3 |
3 files changed, 3 insertions, 7 deletions
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c index 823c5bfecfea..87be1024d91b 100644 --- a/arch/s390/kernel/smp.c +++ b/arch/s390/kernel/smp.c | |||
@@ -959,13 +959,11 @@ static int __cpuinit smp_cpu_notify(struct notifier_block *self, | |||
959 | struct device *s = &c->dev; | 959 | struct device *s = &c->dev; |
960 | int err = 0; | 960 | int err = 0; |
961 | 961 | ||
962 | switch (action) { | 962 | switch (action & ~CPU_TASKS_FROZEN) { |
963 | case CPU_ONLINE: | 963 | case CPU_ONLINE: |
964 | case CPU_ONLINE_FROZEN: | ||
965 | err = sysfs_create_group(&s->kobj, &cpu_online_attr_group); | 964 | err = sysfs_create_group(&s->kobj, &cpu_online_attr_group); |
966 | break; | 965 | break; |
967 | case CPU_DEAD: | 966 | case CPU_DEAD: |
968 | case CPU_DEAD_FROZEN: | ||
969 | sysfs_remove_group(&s->kobj, &cpu_online_attr_group); | 967 | sysfs_remove_group(&s->kobj, &cpu_online_attr_group); |
970 | break; | 968 | break; |
971 | } | 969 | } |
diff --git a/arch/s390/kernel/vtime.c b/arch/s390/kernel/vtime.c index 4fc97b40a6e1..d100c92cfcf8 100644 --- a/arch/s390/kernel/vtime.c +++ b/arch/s390/kernel/vtime.c | |||
@@ -378,9 +378,8 @@ static int __cpuinit s390_nohz_notify(struct notifier_block *self, | |||
378 | long cpu = (long) hcpu; | 378 | long cpu = (long) hcpu; |
379 | 379 | ||
380 | idle = &per_cpu(s390_idle, cpu); | 380 | idle = &per_cpu(s390_idle, cpu); |
381 | switch (action) { | 381 | switch (action & ~CPU_TASKS_FROZEN) { |
382 | case CPU_DYING: | 382 | case CPU_DYING: |
383 | case CPU_DYING_FROZEN: | ||
384 | idle->nohz_delay = 0; | 383 | idle->nohz_delay = 0; |
385 | default: | 384 | default: |
386 | break; | 385 | break; |
diff --git a/arch/s390/mm/fault.c b/arch/s390/mm/fault.c index 6c013f544146..12c887bcdf1f 100644 --- a/arch/s390/mm/fault.c +++ b/arch/s390/mm/fault.c | |||
@@ -628,9 +628,8 @@ static int __cpuinit pfault_cpu_notify(struct notifier_block *self, | |||
628 | struct thread_struct *thread, *next; | 628 | struct thread_struct *thread, *next; |
629 | struct task_struct *tsk; | 629 | struct task_struct *tsk; |
630 | 630 | ||
631 | switch (action) { | 631 | switch (action & ~CPU_TASKS_FROZEN) { |
632 | case CPU_DEAD: | 632 | case CPU_DEAD: |
633 | case CPU_DEAD_FROZEN: | ||
634 | spin_lock_irq(&pfault_lock); | 633 | spin_lock_irq(&pfault_lock); |
635 | list_for_each_entry_safe(thread, next, &pfault_list, list) { | 634 | list_for_each_entry_safe(thread, next, &pfault_list, list) { |
636 | thread->pfault_wait = 0; | 635 | thread->pfault_wait = 0; |