| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * SMP support for PowerNV machines. |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Copyright 2011 IBM Corp. |
|---|
| 5 | | - * |
|---|
| 6 | | - * This program is free software; you can redistribute it and/or |
|---|
| 7 | | - * modify it under the terms of the GNU General Public License |
|---|
| 8 | | - * as published by the Free Software Foundation; either version |
|---|
| 9 | | - * 2 of the License, or (at your option) any later version. |
|---|
| 10 | 6 | */ |
|---|
| 11 | 7 | |
|---|
| 12 | 8 | #include <linux/kernel.h> |
|---|
| .. | .. |
|---|
| 147 | 143 | xive_smp_disable_cpu(); |
|---|
| 148 | 144 | else |
|---|
| 149 | 145 | xics_migrate_irqs_away(); |
|---|
| 146 | + |
|---|
| 147 | + cleanup_cpu_mmu_context(); |
|---|
| 148 | + |
|---|
| 150 | 149 | return 0; |
|---|
| 151 | 150 | } |
|---|
| 152 | 151 | |
|---|
| .. | .. |
|---|
| 162 | 161 | } |
|---|
| 163 | 162 | } |
|---|
| 164 | 163 | |
|---|
| 165 | | -static void pnv_smp_cpu_kill_self(void) |
|---|
| 164 | +static void pnv_cpu_offline_self(void) |
|---|
| 166 | 165 | { |
|---|
| 167 | 166 | unsigned long srr1, unexpected_mask, wmask; |
|---|
| 168 | 167 | unsigned int cpu; |
|---|
| .. | .. |
|---|
| 421 | 420 | #ifdef CONFIG_HOTPLUG_CPU |
|---|
| 422 | 421 | .cpu_disable = pnv_smp_cpu_disable, |
|---|
| 423 | 422 | .cpu_die = generic_cpu_die, |
|---|
| 423 | + .cpu_offline_self = pnv_cpu_offline_self, |
|---|
| 424 | 424 | #endif /* CONFIG_HOTPLUG_CPU */ |
|---|
| 425 | 425 | }; |
|---|
| 426 | 426 | |
|---|
| .. | .. |
|---|
| 434 | 434 | smp_ops = &pnv_smp_ops; |
|---|
| 435 | 435 | |
|---|
| 436 | 436 | #ifdef CONFIG_HOTPLUG_CPU |
|---|
| 437 | | - ppc_md.cpu_die = pnv_smp_cpu_kill_self; |
|---|
| 438 | 437 | #ifdef CONFIG_KEXEC_CORE |
|---|
| 439 | 438 | crash_wake_offline = 1; |
|---|
| 440 | 439 | #endif |
|---|