hv: Bit Representation for IOAPIC RTE

As we enable Interrupt Remapping, bit positions in IOAPIC RTEs
have a different syntax for programming. ACRN should handle original
format for vIOAPIC as well IR representation for physical IOAPIC.
This patch adds bit granularity IOAPIC RTE.

Tracked-On: #2407
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
This commit is contained in:
Sainath Grandhi
2019-01-26 01:33:02 -08:00
committed by wenlingz
parent 7d57eb056e
commit 6d5456a0df
8 changed files with 158 additions and 175 deletions

View File

@@ -143,7 +143,7 @@ static void vuart_toggle_intr(const struct acrn_vuart *vu)
* modify the vioapic setting, as it's only for debug uart,
* we want to make it as an known issue.
*/
if ((rte.full & IOAPIC_RTE_INTPOL) != 0UL) {
if (rte.bits.intr_polarity == IOAPIC_RTE_INTPOL_ALO) {
operation = (intr_reason != IIR_NOPEND) ? GSI_SET_LOW : GSI_SET_HIGH;
} else {
operation = (intr_reason != IIR_NOPEND) ? GSI_SET_HIGH : GSI_SET_LOW;