diff options
| author | Hawkins Jiawei <yin31149@gmail.com> | 2023-07-07 23:27:28 +0800 |
|---|---|---|
| committer | Michael S. Tsirkin <mst@redhat.com> | 2023-07-10 18:59:32 -0400 |
| commit | 2848c6aa7536fb48a57f38dabed1dce97fb45c6f (patch) | |
| tree | 9bc9cddffbea53dad24670602684a84f08de75c5 /hw/virtio/vhost-shadow-virtqueue.c | |
| parent | 7c228c5f3301113ffd7cfee7f982e7ae04c8ffda (diff) | |
| download | focaccia-qemu-2848c6aa7536fb48a57f38dabed1dce97fb45c6f.tar.gz focaccia-qemu-2848c6aa7536fb48a57f38dabed1dce97fb45c6f.zip | |
vdpa: Use iovec for vhost_vdpa_net_load_cmd()
According to VirtIO standard, "The driver MUST follow the VIRTIO_NET_CTRL_MAC_TABLE_SET command by a le32 number, followed by that number of non-multicast MAC addresses, followed by another le32 number, followed by that number of multicast addresses." Considering that these data is not stored in contiguous memory, this patch refactors vhost_vdpa_net_load_cmd() to accept scattered data, eliminating the need for an addtional data copy or packing the data into s->cvq_cmd_out_buffer outside of vhost_vdpa_net_load_cmd(). Signed-off-by: Hawkins Jiawei <yin31149@gmail.com> Message-Id: <3482cc50eebd13db4140b8b5dec9d0cc25b20b1b.1688743107.git.yin31149@gmail.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/virtio/vhost-shadow-virtqueue.c')
0 files changed, 0 insertions, 0 deletions