diff options
author | Nathan Fontenot <nfont@linux.vnet.ibm.com> | 2015-12-16 23:54:05 +0300 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2015-12-17 14:41:02 +0300 |
commit | ac71380071d19d4ac7cd5f9fe4168d7109902cd5 (patch) | |
tree | 092123a664316847583f1af50483d42d788186c0 /arch/powerpc/platforms/pseries/pseries.h | |
parent | e666ae0b10aaa1c961c928558bafc28bc049ac87 (diff) | |
download | linux-ac71380071d19d4ac7cd5f9fe4168d7109902cd5.tar.xz |
powerpc/pseries: Add CPU dlpar remove functionality
Add the ability to dlpar remove CPUs via hotplug rtas events, either by
specifying the drc-index of the CPU to remove or providing a count of cpus
to remove.
To remove multiple cpus in a single request we create a list of possible
DR (Dynamic Reconfiguration) cpus and their drc indexes that can be
removed. We can then traverse the list remove each cpu and easily clean
up in any cases of failure.
Signed-off-by: Nathan Fontenot <nfont@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/platforms/pseries/pseries.h')
-rw-r--r-- | arch/powerpc/platforms/pseries/pseries.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/pseries/pseries.h b/arch/powerpc/platforms/pseries/pseries.h index 8411c27293e4..7aa83f00ac62 100644 --- a/arch/powerpc/platforms/pseries/pseries.h +++ b/arch/powerpc/platforms/pseries/pseries.h @@ -73,6 +73,15 @@ static inline int dlpar_memory(struct pseries_hp_errorlog *hp_elog) } #endif +#ifdef CONFIG_HOTPLUG_CPU +int dlpar_cpu(struct pseries_hp_errorlog *hp_elog); +#else +static inline int dlpar_cpu(struct pseries_hp_errorlog *hp_elog) +{ + return -EOPNOTSUPP; +} +#endif + /* PCI root bridge prepare function override for pseries */ struct pci_host_bridge; int pseries_root_bridge_prepare(struct pci_host_bridge *bridge); |