Carl van Schaik 25ff9fd8d7 aarch64: add core okl4 hypervisor config
Adds the OKL4_GUEST config to the arm64 architecture, which
serves as a root selector to enable additional drivers for
running on the OKL4 hypervisor.

include/asm-generic/okl4_virq.h:
  A generic helper for OKL4 hypervisor aware drivers.

Change-Id: Ie89c5341cad762812485115bbe45c3bb4a1d7a15
Signed-off-by: Carl van Schaik <carl@cog.systems>
Git-commit: 936194027fc9abaacec9b253c0f3e468a3d51577
Git-repo: https://github.com/CogSystems/linux-msm/commits/msm-4.9-hyp
Signed-off-by: Murali Nalajala <mnalajal@codeaurora.org>
2018-11-19 18:17:33 -08:00

28 lines
625 B
C

/*
* include/asm-generic/okl4_virq.h
*
* Copyright (c) 2017 General Dynamics
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/
#ifndef __OKL4_VIRQ_H__
#define __OKL4_VIRQ_H__
#include <linux/irq.h>
#include <microvisor/microvisor.h>
static inline okl4_virq_flags_t okl4_get_virq_payload(unsigned int irq)
{
struct irq_data *irqd = irq_get_irq_data(irq);
if (WARN_ON_ONCE(!irqd))
return 0;
return _okl4_sys_interrupt_get_payload(irqd_to_hwirq(irqd)).payload;
}
#endif