linux-stable/arch
Raghavendra Rao Ananta af406bdbf3 KVM: arm64: Fix hardware enable/disable flows for pKVM
commit c718ca0e99 upstream.

When running in protected mode, the hyp stub is disabled after pKVM is
initialized, meaning the host cannot enable/disable the hyp at
runtime. As such, kvm_arm_hardware_enabled is always 1 after
initialization, and kvm_arch_hardware_enable() never enables the vgic
maintenance irq or timer irqs.

Unconditionally enable/disable the vgic + timer irqs in the respective
calls, instead relying on the percpu bookkeeping in the generic code
to keep track of which cpus have the interrupts unmasked.

Fixes: 466d27e48d ("KVM: arm64: Simplify the CPUHP logic")
Reported-by: Oliver Upton <oliver.upton@linux.dev>
Suggested-by: Oliver Upton <oliver.upton@linux.dev>
Signed-off-by: Raghavendra Rao Ananta <rananta@google.com>
Link: https://lore.kernel.org/r/20230719175400.647154-1-rananta@google.com
Acked-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-08-16 18:32:23 +02:00
..
alpha init: Remove check_bugs() leftovers 2023-08-08 20:04:49 +02:00
arc ARC: define ASM_NL and __ALIGN(_STR) outside #ifdef __ASSEMBLY__ guard 2023-07-19 16:36:19 +02:00
arm ARM: dts: nxp/imx6sll: fix wrong property name in usbphy node 2023-08-11 12:14:27 +02:00
arm64 KVM: arm64: Fix hardware enable/disable flows for pKVM 2023-08-16 18:32:23 +02:00
csky csky: fix up lock_mm_and_find_vma() conversion 2023-07-01 13:12:41 +02:00
hexagon mm/fault: convert remaining simple cases to lock_mm_and_find_vma() 2023-07-01 13:12:39 +02:00
ia64 ia64/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:48 +02:00
loongarch loongarch/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:48 +02:00
m68k m68k/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:48 +02:00
microblaze mm: always expand the stack with the mmap write lock held 2023-07-01 13:12:40 +02:00
mips mips/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:48 +02:00
nios2 mm/fault: convert remaining simple cases to lock_mm_and_find_vma() 2023-07-01 13:12:39 +02:00
openrisc openrisc: Union fpcsr and oldmask in sigcontext to unbreak userspace ABI 2023-07-23 13:53:45 +02:00
parisc parisc: Fix lightweight spinlock checks to not break futexes 2023-08-16 18:32:18 +02:00
powerpc powerpc/mm/altmap: Fix altmap boundary check 2023-08-11 12:14:27 +02:00
riscv riscv: mm: fix 2 instances of -Wmissing-variable-declarations 2023-08-16 18:32:18 +02:00
s390 KVM: s390: fix sthyi error handling 2023-08-11 12:14:08 +02:00
sh sh/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:49 +02:00
sparc sparc/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:49 +02:00
um um/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:04:49 +02:00
x86 x86: Move gds_ucode_mitigated() declaration to header 2023-08-16 18:32:22 +02:00
xtensa init: Remove check_bugs() leftovers 2023-08-08 20:04:49 +02:00
.gitignore
Kconfig init: Provide arch_cpu_finalize_init() 2023-08-08 20:04:47 +02:00