hv: Add bit representation for MSI addr and data

As we enable Interrupt Remapping, bit positions in MSI address and
data registers have a different syntax for programming. This patch adds
bit granularity for MSI address and data structs.

Tracked-On: #2407
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
This commit is contained in:
Sainath Grandhi
2019-01-26 01:31:14 -08:00
committed by wenlingz
parent 6825043078
commit 7d57eb056e
7 changed files with 92 additions and 55 deletions

View File

@@ -102,17 +102,6 @@ uint32_t alloc_irq_vector(uint32_t irq);
*/
uint32_t irq_to_vector(uint32_t irq);
/*
* Some MSI message definitions
*/
#define MSI_ADDR_MASK 0xfff00000UL
#define MSI_ADDR_BASE 0xfee00000UL
#define MSI_ADDR_RH 0x00000008UL /* Redirection Hint */
#define MSI_ADDR_LOG 0x00000004UL /* Destination Mode */
#define MSI_ADDR_DEST 0x000FF000UL /* Destination Field */
#define MSI_ADDR_DEST_SHIFT (12U)
/* RFLAGS */
#define HV_ARCH_VCPU_RFLAGS_IF (1UL<<9U)