-
-
Save marmarek/810ae5c079d218928535514b08a07716 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/xen/common/smp.c b/xen/common/smp.c | |
index 79f4ebd14502..155d6d52f655 100644 | |
--- a/xen/common/smp.c | |
+++ b/xen/common/smp.c | |
@@ -51,6 +51,7 @@ void on_selected_cpus( | |
int wait) | |
{ | |
unsigned int nr_cpus; | |
+ unsigned long counter = 0; | |
ASSERT(local_irq_is_enabled()); | |
ASSERT(cpumask_subset(selected, &cpu_online_map)); | |
@@ -69,8 +70,15 @@ void on_selected_cpus( | |
smp_send_call_function_mask(&call_data.selected); | |
- while ( !cpumask_empty(&call_data.selected) ) | |
+ while ( !cpumask_empty(&call_data.selected) ) { | |
+ if (counter > 100000) { | |
+ printk(XENLOG_WARNING "still waiting for %*pbl\n", CPUMASK_PR(&call_data.selected)); | |
+ WARN(); | |
+ counter = 0; | |
+ } | |
+ counter++; | |
cpu_relax(); | |
+ } | |
out: | |
spin_unlock(&call_lock); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment