aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/xen/cpu_hotplug.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/xen/cpu_hotplug.c')
-rw-r--r--drivers/xen/cpu_hotplug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/xen/cpu_hotplug.c b/drivers/xen/cpu_hotplug.c
index b1357aa4bc55..f192b6f42da9 100644
--- a/drivers/xen/cpu_hotplug.c
+++ b/drivers/xen/cpu_hotplug.c
@@ -54,7 +54,7 @@ static int vcpu_online(unsigned int cpu)
}
static void vcpu_hotplug(unsigned int cpu)
{
- if (!cpu_possible(cpu))
+ if (cpu >= nr_cpu_ids || !cpu_possible(cpu))
return;
switch (vcpu_online(cpu)) {