virtio-devices: net: Cleanup the MQ handling in the control queue

Cleanup the control queue handling in preparation for supporting
alternative commands.

Note that this change does not make the MQ handling spec compliant.
According to the specification MQ should only be enabled once the number
of queue pairs the guest would like to use has been specified. The only
improvement towards the specication in this change is correct error
handling if the guest specifies an inappropriate number of queues (out
of range.)

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
Rob Bradford
2021-04-28 13:16:10 +01:00
committed by Sebastien Boeuf
parent 72d67fe96d
commit 4806357f52
4 changed files with 52 additions and 64 deletions
-1
View File
@@ -248,7 +248,6 @@ impl VirtioDevice for Net {
kill_evt,
pause_evt,
ctrl_q: CtrlVirtio::new(cvq_queue, cvq_queue_evt),
epoll_fd: 0,
};
let paused = self.common.paused.clone();