aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJohn Levon <john.levon@nutanix.com>2022-05-27 17:29:32 +0100
committerGitHub <noreply@github.com>2022-05-27 17:29:32 +0100
commit538d6063c9f8d395e1d38285ddfe405c3fcd7619 (patch)
tree96afbcf64f70916966744d3422a113b81e1c21ba /test
parent065c33e7dc7bbd1d5964a5a3af173a69ad3ee931 (diff)
downloadlibvfio-user-538d6063c9f8d395e1d38285ddfe405c3fcd7619.zip
libvfio-user-538d6063c9f8d395e1d38285ddfe405c3fcd7619.tar.gz
libvfio-user-538d6063c9f8d395e1d38285ddfe405c3fcd7619.tar.bz2
remove maps list from DMA controller (#674)
->maps existed so that if a consumer does vfu_map_sg() and then we are asked to enable dirty page tracking, we won't mark those pages as dirty, and will hence potentially lose data. Now that we require quiesce and the use of either vfu_unmap_sg() or vfu_sg_mark_dirty(), there's no need to have this list any more. Signed-off-by: John Levon <john.levon@nutanix.com> Reviewed-by: Thanos Makatos <thanos.makatos@nutanix.com>
Diffstat (limited to 'test')
-rw-r--r--test/py/libvfio_user.py2
-rw-r--r--test/py/test_dirty_pages.py2
2 files changed, 1 insertions, 3 deletions
diff --git a/test/py/libvfio_user.py b/test/py/libvfio_user.py
index ec9da7b..aeaefa5 100644
--- a/test/py/libvfio_user.py
+++ b/test/py/libvfio_user.py
@@ -547,8 +547,6 @@ class dma_sg_t(Structure):
("length", c.c_uint64),
("offset", c.c_uint64),
("writeable", c.c_bool),
- ("le_next", c.c_void_p),
- ("le_prev", c.c_void_p),
]
def __str__(self):
diff --git a/test/py/test_dirty_pages.py b/test/py/test_dirty_pages.py
index 9a0de3b..9f892bd 100644
--- a/test/py/test_dirty_pages.py
+++ b/test/py/test_dirty_pages.py
@@ -347,7 +347,7 @@ def test_dirty_pages_get_modified():
vfu_unmap_sg(ctx, sg1, iovec1)
vfu_unmap_sg(ctx, sg4, iovec4)
bitmap = get_dirty_page_bitmap()
- assert bitmap == 0b11110101
+ assert bitmap == 0b11110001
# after another two unmaps, should just be one dirty page
vfu_unmap_sg(ctx, sg2, iovec2)