Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 232030
b: refs/heads/master
c: bd924e8
h: refs/heads/master
v: v3
  • Loading branch information
Tejun Heo authored and Ingo Molnar committed Jan 20, 2011
1 parent bad6935 commit 973da35
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2ce802f62ba32a7d95748ac92bf351f76affb6ff
refs/heads/master: bd924e8cbd4b73ffb7d707a774c04f7e2cae88ed
11 changes: 7 additions & 4 deletions trunk/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ void smp_call_function_many(const struct cpumask *mask,
* can't happen.
*/
WARN_ON_ONCE(cpu_online(this_cpu) && irqs_disabled()
&& !oops_in_progress);
&& !oops_in_progress && !early_boot_irqs_disabled);

/* So, what's a CPU they want? Ignoring this one. */
cpu = cpumask_first_and(mask, cpu_online_mask);
Expand Down Expand Up @@ -533,17 +533,20 @@ void ipi_call_unlock_irq(void)
#endif /* USE_GENERIC_SMP_HELPERS */

/*
* Call a function on all processors
* Call a function on all processors. May be used during early boot while
* early_boot_irqs_disabled is set. Use local_irq_save/restore() instead
* of local_irq_disable/enable().
*/
int on_each_cpu(void (*func) (void *info), void *info, int wait)
{
unsigned long flags;
int ret = 0;

preempt_disable();
ret = smp_call_function(func, info, wait);
local_irq_disable();
local_irq_save(flags);
func(info);
local_irq_enable();
local_irq_restore(flags);
preempt_enable();
return ret;
}
Expand Down

0 comments on commit 973da35

Please sign in to comment.