From 6a756d1495fc0a852b119f7ecbb7a20131f0aba7 Mon Sep 17 00:00:00 2001 From: Jason Wang Date: Fri, 3 Sep 2021 17:10:15 +0800 Subject: vhost_net: do not assume nvqs is always 2 This patch switches to initialize dev.nvqs from the VhostNetOptions instead of assuming it was 2. This is useful for implementing control virtqueue support which will be a single vhost_net structure with a single cvq. Note that nvqs is still set to 2 for all users and this patch does not change functionality. Reviewed-by: Stefano Garzarella Reviewed-by: Eli Cohen Signed-off-by: Jason Wang Message-Id: <20210903091031.47303-6-jasowang@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- include/net/vhost_net.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/net') diff --git a/include/net/vhost_net.h b/include/net/vhost_net.h index 172b0051d8..fba40cf695 100644 --- a/include/net/vhost_net.h +++ b/include/net/vhost_net.h @@ -14,6 +14,7 @@ typedef struct VhostNetOptions { VhostBackendType backend_type; NetClientState *net_backend; uint32_t busyloop_timeout; + unsigned int nvqs; void *opaque; } VhostNetOptions; -- cgit v1.2.3