Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
vhost: fix virtqueues metadata allocation
The Vhost-user backend implementation assumes there will be no holes in the device's array of virtqueues metadata pointers. It can happen though, and would cause segmentation faults, memory leaks or undefined behaviour. This patch keep the assumption that there is no holes in this array, and allocate all uninitialized virtqueues metadata up to requested index. Fixes: 160cbc8 ("vhost: remove a hack on queue allocation") Cc: stable@dpdk.org Suggested-by: Adrian Moreno <amorenoz@redhat.com> Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
- Loading branch information