virtio-devices: seccomp: Add seccomp filters for vhost_blk thread

This patch enables the seccomp filters for the vhost_blk worker thread.

Partially fixes: #925

Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
Bo Chen
2020-08-17 21:59:27 -07:00
committed by Sebastien Boeuf
parent 4e0ea15075
commit 02d87833f0
3 changed files with 42 additions and 5 deletions
+6 -2
View File
@@ -1642,8 +1642,12 @@ impl DeviceManager {
queue_size: disk_cfg.queue_size,
};
let vhost_user_block_device = Arc::new(Mutex::new(
virtio_devices::vhost_user::Blk::new(id.clone(), vu_cfg)
.map_err(DeviceManagerError::CreateVhostUserBlk)?,
virtio_devices::vhost_user::Blk::new(
id.clone(),
vu_cfg,
self.seccomp_action.clone(),
)
.map_err(DeviceManagerError::CreateVhostUserBlk)?,
));
// Fill the device tree with a new node. In case of restore, we