diff options
author | Marc Zyngier <marc.zyngier@arm.com> | 2018-02-06 12:56:08 -0500 |
---|---|---|
committer | Catalin Marinas <catalin.marinas@arm.com> | 2018-02-06 17:53:54 -0500 |
commit | 1a2fb94e6a771ff94f4afa22497a4695187b820c (patch) | |
tree | 97abad3081ae492e24dfb0a23f9d425cdfb173e0 | |
parent | f5115e8869e1dfafac0e414b4f1664f3a84a4683 (diff) |
arm/arm64: KVM: Consolidate the PSCI include files
As we're about to update the PSCI support, and because I'm lazy,
let's move the PSCI include file to include/kvm so that both
ARM architectures can find it.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org>
Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
-rw-r--r-- | arch/arm/include/asm/kvm_psci.h | 27 | ||||
-rw-r--r-- | arch/arm/kvm/handle_exit.c | 2 | ||||
-rw-r--r-- | arch/arm64/kvm/handle_exit.c | 3 | ||||
-rw-r--r-- | include/kvm/arm_psci.h (renamed from arch/arm64/include/asm/kvm_psci.h) | 6 | ||||
-rw-r--r-- | virt/kvm/arm/arm.c | 2 | ||||
-rw-r--r-- | virt/kvm/arm/psci.c | 3 |
6 files changed, 9 insertions, 34 deletions
diff --git a/arch/arm/include/asm/kvm_psci.h b/arch/arm/include/asm/kvm_psci.h deleted file mode 100644 index 6bda945d31fa..000000000000 --- a/arch/arm/include/asm/kvm_psci.h +++ /dev/null | |||
@@ -1,27 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2012 - ARM Ltd | ||
3 | * Author: Marc Zyngier <marc.zyngier@arm.com> | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or modify | ||
6 | * it under the terms of the GNU General Public License version 2 as | ||
7 | * published by the Free Software Foundation. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, | ||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | * GNU General Public License for more details. | ||
13 | * | ||
14 | * You should have received a copy of the GNU General Public License | ||
15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
16 | */ | ||
17 | |||
18 | #ifndef __ARM_KVM_PSCI_H__ | ||
19 | #define __ARM_KVM_PSCI_H__ | ||
20 | |||
21 | #define KVM_ARM_PSCI_0_1 1 | ||
22 | #define KVM_ARM_PSCI_0_2 2 | ||
23 | |||
24 | int kvm_psci_version(struct kvm_vcpu *vcpu); | ||
25 | int kvm_psci_call(struct kvm_vcpu *vcpu); | ||
26 | |||
27 | #endif /* __ARM_KVM_PSCI_H__ */ | ||
diff --git a/arch/arm/kvm/handle_exit.c b/arch/arm/kvm/handle_exit.c index a4bf0f6f024a..230ae4079108 100644 --- a/arch/arm/kvm/handle_exit.c +++ b/arch/arm/kvm/handle_exit.c | |||
@@ -21,7 +21,7 @@ | |||
21 | #include <asm/kvm_emulate.h> | 21 | #include <asm/kvm_emulate.h> |
22 | #include <asm/kvm_coproc.h> | 22 | #include <asm/kvm_coproc.h> |
23 | #include <asm/kvm_mmu.h> | 23 | #include <asm/kvm_mmu.h> |
24 | #include <asm/kvm_psci.h> | 24 | #include <kvm/arm_psci.h> |
25 | #include <trace/events/kvm.h> | 25 | #include <trace/events/kvm.h> |
26 | 26 | ||
27 | #include "trace.h" | 27 | #include "trace.h" |
diff --git a/arch/arm64/kvm/handle_exit.c b/arch/arm64/kvm/handle_exit.c index 5493bbefbd0d..588f910632a7 100644 --- a/arch/arm64/kvm/handle_exit.c +++ b/arch/arm64/kvm/handle_exit.c | |||
@@ -22,13 +22,14 @@ | |||
22 | #include <linux/kvm.h> | 22 | #include <linux/kvm.h> |
23 | #include <linux/kvm_host.h> | 23 | #include <linux/kvm_host.h> |
24 | 24 | ||
25 | #include <kvm/arm_psci.h> | ||
26 | |||
25 | #include <asm/esr.h> | 27 | #include <asm/esr.h> |
26 | #include <asm/exception.h> | 28 | #include <asm/exception.h> |
27 | #include <asm/kvm_asm.h> | 29 | #include <asm/kvm_asm.h> |
28 | #include <asm/kvm_coproc.h> | 30 | #include <asm/kvm_coproc.h> |
29 | #include <asm/kvm_emulate.h> | 31 | #include <asm/kvm_emulate.h> |
30 | #include <asm/kvm_mmu.h> | 32 | #include <asm/kvm_mmu.h> |
31 | #include <asm/kvm_psci.h> | ||
32 | #include <asm/debug-monitors.h> | 33 | #include <asm/debug-monitors.h> |
33 | #include <asm/traps.h> | 34 | #include <asm/traps.h> |
34 | 35 | ||
diff --git a/arch/arm64/include/asm/kvm_psci.h b/include/kvm/arm_psci.h index bc39e557c56c..2042bb909474 100644 --- a/arch/arm64/include/asm/kvm_psci.h +++ b/include/kvm/arm_psci.h | |||
@@ -15,8 +15,8 @@ | |||
15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
16 | */ | 16 | */ |
17 | 17 | ||
18 | #ifndef __ARM64_KVM_PSCI_H__ | 18 | #ifndef __KVM_ARM_PSCI_H__ |
19 | #define __ARM64_KVM_PSCI_H__ | 19 | #define __KVM_ARM_PSCI_H__ |
20 | 20 | ||
21 | #define KVM_ARM_PSCI_0_1 1 | 21 | #define KVM_ARM_PSCI_0_1 1 |
22 | #define KVM_ARM_PSCI_0_2 2 | 22 | #define KVM_ARM_PSCI_0_2 2 |
@@ -24,4 +24,4 @@ | |||
24 | int kvm_psci_version(struct kvm_vcpu *vcpu); | 24 | int kvm_psci_version(struct kvm_vcpu *vcpu); |
25 | int kvm_psci_call(struct kvm_vcpu *vcpu); | 25 | int kvm_psci_call(struct kvm_vcpu *vcpu); |
26 | 26 | ||
27 | #endif /* __ARM64_KVM_PSCI_H__ */ | 27 | #endif /* __KVM_ARM_PSCI_H__ */ |
diff --git a/virt/kvm/arm/arm.c b/virt/kvm/arm/arm.c index 15bf026eb182..af3e98fc377e 100644 --- a/virt/kvm/arm/arm.c +++ b/virt/kvm/arm/arm.c | |||
@@ -31,6 +31,7 @@ | |||
31 | #include <linux/irqbypass.h> | 31 | #include <linux/irqbypass.h> |
32 | #include <trace/events/kvm.h> | 32 | #include <trace/events/kvm.h> |
33 | #include <kvm/arm_pmu.h> | 33 | #include <kvm/arm_pmu.h> |
34 | #include <kvm/arm_psci.h> | ||
34 | 35 | ||
35 | #define CREATE_TRACE_POINTS | 36 | #define CREATE_TRACE_POINTS |
36 | #include "trace.h" | 37 | #include "trace.h" |
@@ -46,7 +47,6 @@ | |||
46 | #include <asm/kvm_mmu.h> | 47 | #include <asm/kvm_mmu.h> |
47 | #include <asm/kvm_emulate.h> | 48 | #include <asm/kvm_emulate.h> |
48 | #include <asm/kvm_coproc.h> | 49 | #include <asm/kvm_coproc.h> |
49 | #include <asm/kvm_psci.h> | ||
50 | #include <asm/sections.h> | 50 | #include <asm/sections.h> |
51 | 51 | ||
52 | #ifdef REQUIRES_VIRT | 52 | #ifdef REQUIRES_VIRT |
diff --git a/virt/kvm/arm/psci.c b/virt/kvm/arm/psci.c index f1e363bab5e8..b322e46fd142 100644 --- a/virt/kvm/arm/psci.c +++ b/virt/kvm/arm/psci.c | |||
@@ -21,9 +21,10 @@ | |||
21 | 21 | ||
22 | #include <asm/cputype.h> | 22 | #include <asm/cputype.h> |
23 | #include <asm/kvm_emulate.h> | 23 | #include <asm/kvm_emulate.h> |
24 | #include <asm/kvm_psci.h> | ||
25 | #include <asm/kvm_host.h> | 24 | #include <asm/kvm_host.h> |
26 | 25 | ||
26 | #include <kvm/arm_psci.h> | ||
27 | |||
27 | #include <uapi/linux/psci.h> | 28 | #include <uapi/linux/psci.h> |
28 | 29 | ||
29 | /* | 30 | /* |