diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2020-08-26 01:36:07 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2020-08-26 01:36:07 +0200 |
commit | ceb2465c51195967f11f6507538579816ac67cb8 (patch) | |
tree | eab534b1062608e36a7b54ccc7be693625f235b8 /arch/arm64/include/asm/virt.h | |
parent | genirq: Unlock irq descriptor after errors (diff) | |
parent | irqchip/ingenic: Leave parent IRQ unmasked on suspend (diff) | |
download | linux-ceb2465c51195967f11f6507538579816ac67cb8.tar.xz linux-ceb2465c51195967f11f6507538579816ac67cb8.zip |
Merge tag 'irqchip-fixes-5.9-2' of git://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms into irq/urgent
Pull irqchip fixes from Marc Zyngier:
- Revert the wholesale conversion to platform drivers of the pdc, sysirq
and cirq drivers, as it breaks a number of platforms even when the
driver is built-in (probe ordering bites you).
- Prevent interrupt from being lost with the STM32 exti driver
- Fix wake-up interrupts for the MIPS Ingenic driver
- Fix an embarassing typo in the new module helpers, leading to the probe
failing most of the time
- The promised TI firmware rework that couldn't make it into the merge
window due to a very badly managed set of dependencies
Diffstat (limited to 'arch/arm64/include/asm/virt.h')
-rw-r--r-- | arch/arm64/include/asm/virt.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/arch/arm64/include/asm/virt.h b/arch/arm64/include/asm/virt.h index 5051b388c654..09977acc007d 100644 --- a/arch/arm64/include/asm/virt.h +++ b/arch/arm64/include/asm/virt.h @@ -85,10 +85,17 @@ static inline bool is_kernel_in_hyp_mode(void) static __always_inline bool has_vhe(void) { - if (cpus_have_final_cap(ARM64_HAS_VIRT_HOST_EXTN)) + /* + * The following macros are defined for code specic to VHE/nVHE. + * If has_vhe() is inlined into those compilation units, it can + * be determined statically. Otherwise fall back to caps. + */ + if (__is_defined(__KVM_VHE_HYPERVISOR__)) return true; - - return false; + else if (__is_defined(__KVM_NVHE_HYPERVISOR__)) + return false; + else + return cpus_have_final_cap(ARM64_HAS_VIRT_HOST_EXTN); } #endif /* __ASSEMBLY__ */ |