mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
When configuring multiple queues for a virtio device, the guest can activate between 1 and the configured amout of queues. The firmware, for example, may activate only one queue, while a Linux guest would likely activate all available queues. The constructor of virtio-net initializes the `paused_sync` barrier using the configured queue count (plus one for the main thread). This can be wrong if the guest enables a different number of queues at activation time, which can make pause hang. Thus, we now recompute the barrier size from the queues that are actually activated. On-behalf-of: SAP sebastian.eydam@sap.com Signed-off-by: Sebastian Eydam <sebastian.eydam@cyberus-technology.de>