From: Keir Fraser Date: Tue, 18 May 2010 12:41:55 +0000 (+0100) Subject: cpu hotplug: tasklet and timer initialisation is high priority. X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~12129 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=852ed0aaf07ad074ac111b1a432de5b816aad7fd;p=xen.git cpu hotplug: tasklet and timer initialisation is high priority. Signed-off-by: Keir Fraser --- diff --git a/xen/common/tasklet.c b/xen/common/tasklet.c index 2e23232c41..3dff65074e 100644 --- a/xen/common/tasklet.c +++ b/xen/common/tasklet.c @@ -188,7 +188,8 @@ static int cpu_callback( } static struct notifier_block cpu_nfb = { - .notifier_call = cpu_callback + .notifier_call = cpu_callback, + .priority = 99 }; void __init tasklet_subsys_init(void) diff --git a/xen/common/timer.c b/xen/common/timer.c index 0759df818f..57d488ce9a 100644 --- a/xen/common/timer.c +++ b/xen/common/timer.c @@ -521,18 +521,29 @@ static int cpu_callback( struct notifier_block *nfb, unsigned long action, void *hcpu) { unsigned int cpu = (unsigned long)hcpu; + struct timers *ts = &per_cpu(timers, cpu); - if ( action == CPU_UP_PREPARE ) + switch ( action ) { - spin_lock_init(&per_cpu(timers, cpu).lock); - per_cpu(timers, cpu).heap = &dummy_heap; + case CPU_UP_PREPARE: + spin_lock_init(&ts->lock); + ts->heap = &dummy_heap; + break; + case CPU_UP_CANCELED: + case CPU_DEAD: + /* Enable this later. */ + /*WARN_ON(GET_HEAP_SIZE(ts->heap) || ts->list);*/ + break; + default: + break; } return NOTIFY_DONE; } static struct notifier_block cpu_nfb = { - .notifier_call = cpu_callback + .notifier_call = cpu_callback, + .priority = 99 }; void __init timer_init(void)