[dpdk-dev] [PATCH] vhost: reserve some spaces for virtio_net and vhost_virtqueue struct

Thomas Monjalon thomas.monjalon at 6wind.com
Tue Dec 8 00:54:15 CET 2015


2015-12-03 10:27, Yuanhan Liu:
> So that we will not break ABI in future extension by adding few more
> fields.
> 
> Struct vhost_virtqueue is reserved with 16 qwords (the later vhost-live
> migration support would at least consume 3 of them), and struct virtio_net
> is reserved with a bit more, 64 qwords, as there is only one instance for
> a virtio nic instance.
> 
> Note that both reservation are not placed at the end of the struct, but
> instead before the last field, since both the last field at the two struct
> take a lot spaces. Putting the reservation after it would divide those
> reserved fields to another cacheline. (we might need fix them in future, btw)
> 
> CC: Panu Matilainen <pmatilai at redhat.com>
> CC: Thomas Monjalon <thomas.monjalon at 6wind.com>
> CC: Michael S. Tsirkin <mst at redhat.com>
> CC: Victor Kaplansky <vkaplans at redhat.com>
> Suggested-by: Panu Matilainen <pmatilai at redhat.com>
> Signed-off-by: Yuanhan Liu <yuanhan.liu at linux.intel.com>
> ---
> 
> Is the reservation a bit too large? :)

You are maintainer in this area.

Applied, thanks


More information about the dev mailing list