mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-26 03:04:31 +00:00
ACRN:DM: Add one API to query the memfd/offset for the given GPA
After using the memfd to allocate memory for guest vm, it needs to query the offset in memfd for the given GPA. In order to search the memfd/offset, the added memory_region from memfd needs to be kept in one arrary. Tracked-On: #7210 Acked-by: Wang Yu <yu1.wang@intel.com> Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
This commit is contained in:
@@ -89,6 +89,12 @@ struct vm_isa_irq {
|
||||
int ioapic_irq;
|
||||
};
|
||||
|
||||
struct vm_mem_region {
|
||||
uint64_t fd_offset;
|
||||
int fd;
|
||||
};
|
||||
bool vm_find_memfd_region(struct vmctx *ctx, vm_paddr_t gpa,
|
||||
struct vm_mem_region *ret_region);
|
||||
/*
|
||||
* Create a device memory segment identified by 'segid'.
|
||||
*
|
||||
|
Reference in New Issue
Block a user