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:
Mingqiang Chi
2019-09-09 16:07:42 +08:00
committed by ACRN System Integration
parent 2ea2716cd9
commit 4f98cb03a7
5 changed files with 15 additions and 12 deletions

View File

@@ -8,7 +8,6 @@
#define PTDEV_H
#include <list.h>
#include <spinlock.h>
#include <pci.h>
#include <timer.h>
#define PTDEV_INTR_MSI (1U << 0U)
@@ -25,16 +24,6 @@ union source_id (name) = {.msi_id = {.bdf = (a), .entry_nr = (b)} }
#define DEFINE_IOAPIC_SID(name, a, b) \
union source_id (name) = {.intx_id = {.pin = (a), .src = (b)} }
union source {
uint16_t ioapic_id;
union pci_bdf msi;
};
struct intr_source {
bool is_msi;
union source src;
};
union irte_index {
uint16_t index;
struct {