virtio-serial: convert to virtio_map
This also fixes a minor bug: - virtqueue_map_sg(port->elem.out_sg, port->elem.out_addr, - port->elem.out_num, 1); is wrong: out_sg is not written so should not be marked dirty. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com>
This commit is contained in:
parent
3d8db153b4
commit
bff712dc22
@ -705,10 +705,7 @@ static int fetch_active_ports_list(QEMUFile *f, int version_id,
|
||||
|
||||
qemu_get_buffer(f, (unsigned char *)&port->elem,
|
||||
sizeof(port->elem));
|
||||
virtqueue_map_sg(port->elem.in_sg, port->elem.in_addr,
|
||||
port->elem.in_num, 1);
|
||||
virtqueue_map_sg(port->elem.out_sg, port->elem.out_addr,
|
||||
port->elem.out_num, 1);
|
||||
virtqueue_map(&port->elem);
|
||||
|
||||
/*
|
||||
* Port was throttled on source machine. Let's
|
||||
|
Loading…
Reference in New Issue
Block a user