mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-22 01:07:57 +00:00
hv:move down the structure intr_source
Now the structures(union source & struct intr_source) are defined in ptdev.h,they are used in vtd.c and assign.c, vtd is the hardware layer and ptdev is the upper-layer module from the modularization perspective, this patch move down these structures to avoid reversed dependency. Tracked-On: #1842 Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com> Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
committed by
ACRN System Integration
parent
2ea2716cd9
commit
4f98cb03a7
@@ -6,7 +6,8 @@
|
||||
|
||||
#ifndef VTD_H
|
||||
#define VTD_H
|
||||
#include <ptdev.h>
|
||||
#include <types.h>
|
||||
#include <pci.h>
|
||||
/*
|
||||
* Intel IOMMU register specification per version 1.0 public spec.
|
||||
*/
|
||||
@@ -56,6 +57,16 @@ struct iommu_domain {
|
||||
bool iommu_snoop;
|
||||
};
|
||||
|
||||
union source {
|
||||
uint16_t ioapic_id;
|
||||
union pci_bdf msi;
|
||||
};
|
||||
|
||||
struct intr_source {
|
||||
bool is_msi;
|
||||
union source src;
|
||||
};
|
||||
|
||||
static inline uint8_t dmar_ver_major(uint64_t version)
|
||||
{
|
||||
return (((uint8_t)version & 0xf0U) >> 4U);
|
||||
|
Reference in New Issue
Block a user