Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
vdpa: conditionally fill max max queue pair for stats
For the device without multiqueue feature, we will read 0 as max_virtqueue_pairs from the config. So if we fill VDPA_ATTR_DEV_NET_CFG_MAX_VQP with the value we read from the config we will confuse the user. Fixing this by only filling the value when multiqueue is offered by the device so userspace can assume 1 when the attr is not provided. Fixes: 13b00b1("vdpa: Add support for querying vendor statistics") Cc: Eli Cohen <[email protected]> Signed-off-by: Jason Wang <[email protected]> Message-Id: <[email protected]> Signed-off-by: Michael S. Tsirkin <[email protected]> Reviewed-by: Eli Cohen <[email protected]>
- Loading branch information