From 4970e2f7030b506ecc22ac027570b998cfe3eeea Mon Sep 17 00:00:00 2001 From: Liu Bo Date: Fri, 7 Feb 2020 17:00:45 -0800 Subject: [PATCH] vhost-user-fs: add dax tests for vhost_user_fs rust daemon Now that vhost_user_fs rust daemon supports virtiofs's dax mode, this adds the two dax tests accordingly. Signed-off-by: Liu Bo --- src/main.rs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/main.rs b/src/main.rs index 617f72133..ea7493ee3 100755 --- a/src/main.rs +++ b/src/main.rs @@ -3387,6 +3387,21 @@ mod tests { test_virtio_fs(false, None, "none", &prepare_virtiofsd) } + #[cfg_attr(not(feature = "mmio"), test)] + fn test_virtio_fs_dax_on_default_cache_size_w_vhost_user_fs_daemon() { + test_virtio_fs(true, None, "none", &prepare_vhost_user_fs_daemon) + } + + #[cfg_attr(not(feature = "mmio"), test)] + fn test_virtio_fs_dax_on_cache_size_1_gib_w_vhost_user_fs_daemon() { + test_virtio_fs( + true, + Some(0x4000_0000), + "none", + &prepare_vhost_user_fs_daemon, + ) + } + #[cfg_attr(not(feature = "mmio"), test)] fn test_virtio_fs_dax_off_w_vhost_user_fs_daemon() { test_virtio_fs(false, None, "none", &prepare_vhost_user_fs_daemon)