[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH] vfio/common: init giommu_list and hostwin_list of v
From: |
Liu, Yi L |
Subject: |
[Qemu-devel] [PATCH] vfio/common: init giommu_list and hostwin_list of vfio container |
Date: |
Wed, 22 Nov 2017 15:58:02 +0800 |
The init of giommu_list and hostwin_list is missed during container
initialization.
Signed-off-by: Liu, Yi L <address@hidden>
---
hw/vfio/common.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/hw/vfio/common.c b/hw/vfio/common.c
index 7b2924c..14c5940 100644
--- a/hw/vfio/common.c
+++ b/hw/vfio/common.c
@@ -990,6 +990,8 @@ static int vfio_connect_container(VFIOGroup *group,
AddressSpace *as,
container = g_malloc0(sizeof(*container));
container->space = space;
container->fd = fd;
+ QLIST_INIT(&container->giommu_list);
+ QLIST_INIT(&container->hostwin_list);
if (ioctl(fd, VFIO_CHECK_EXTENSION, VFIO_TYPE1_IOMMU) ||
ioctl(fd, VFIO_CHECK_EXTENSION, VFIO_TYPE1v2_IOMMU)) {
bool v2 = !!ioctl(fd, VFIO_CHECK_EXTENSION, VFIO_TYPE1v2_IOMMU);
--
1.9.1
- [Qemu-devel] [PATCH] vfio/common: init giommu_list and hostwin_list of vfio container,
Liu, Yi L <=