]> www.infradead.org Git - users/jedix/linux-maple.git/commit
xen, cpu_hotplug: call device_offline instead of cpu_down
authorStefano Stabellini <stefano.stabellini@eu.citrix.com>
Thu, 22 Oct 2015 16:21:46 +0000 (16:21 +0000)
committerJoao Martins <joao.m.martins@oracle.com>
Sun, 27 Mar 2016 01:01:24 +0000 (02:01 +0100)
commit90d4aede271655b4059d2450748c4ad991a0accc
tree4c87225a3b8b2adc8cb25d95fb28dae6acfb90af
parent1e717c5997ccc98f7a8fee633652372b9b97c7e1
xen, cpu_hotplug: call device_offline instead of cpu_down

When offlining a cpu, instead of cpu_down, call device_offline, which
also takes care of updating the cpu.dev.offline field. This keeps the
sysfs file /sys/devices/system/cpu/cpuN/online, up to date.  Also move
the call to disable_hotplug_cpu, because it makes more sense to have it
there.

We don't call device_online at cpu-hotplug time, because that would
immediately take the cpu online, while we want to retain the current
behaviour: the user needs to explicitly enable the cpu after it has
been hotplugged.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Reviewed-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
CC: konrad.wilk@oracle.com
CC: boris.ostrovsky@oracle.com
CC: david.vrabel@citrix.com
(cherry picked from commit 1c7a62137bb23bc8a2c05d1dad6105afa569b20e)
Signed-off-by: Joao Martins <joao.m.martins@oracle.com>
drivers/xen/cpu_hotplug.c