irq.h 307 B

1234567891011121314151617181920
  1. #ifndef __IRQ_H
  2. #define __IRQ_H
  3. #include <linux/kvm_host.h>
  4. static inline int irqchip_in_kernel(struct kvm *kvm)
  5. {
  6. int ret = 0;
  7. #ifdef CONFIG_KVM_MPIC
  8. ret = ret || (kvm->arch.mpic != NULL);
  9. #endif
  10. #ifdef CONFIG_KVM_XICS
  11. ret = ret || (kvm->arch.xics != NULL);
  12. #endif
  13. smp_rmb();
  14. return ret;
  15. }
  16. #endif