Add support for virtio-net.tx_queue_size

https://bugzilla.redhat.com/show_bug.cgi?id=1462653

Just like I've added support for setting rx_queue_size (in
c56cdf259 and friends), qemu just gained support for setting tx
ring size.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Michal Privoznik
2017-07-12 14:19:26 +02:00
parent 8b9d017de3
commit 2074ef6cd4
13 changed files with 67 additions and 14 deletions

View File

@@ -5074,7 +5074,7 @@ qemu-kvm -net nic,model=? /dev/null
&lt;source network='default'/&gt;
&lt;target dev='vnet1'/&gt;
&lt;model type='virtio'/&gt;
<b>&lt;driver name='vhost' txmode='iothread' ioeventfd='on' event_idx='off' queues='5' rx_queue_size='256'&gt;
<b>&lt;driver name='vhost' txmode='iothread' ioeventfd='on' event_idx='off' queues='5' rx_queue_size='256' tx_queue_size='256'&gt;
&lt;host csum='off' gso='off' tso4='off' tso6='off' ecn='off' ufo='off' mrg_rxbuf='off'/&gt;
&lt;guest csum='off' tso4='off' tso6='off' ecn='off' ufo='off'/&gt;
&lt;/driver&gt;
@@ -5204,6 +5204,19 @@ qemu-kvm -net nic,model=? /dev/null
<b>In general you should leave this option alone, unless you
are very certain you know what you are doing.</b>
</dd>
<dt><code>tx_queue_size</code></dt>
<dd>
The optional <code>tx_queue_size</code> attribute controls
the size of virtio ring for each queue as described above.
The default value is hypervisor dependent and may change
across its releases. Moreover, some hypervisors may pose
some restrictions on actual value. For instance, QEMU
v2.9 requires value to be a power of two from [256, 1024] range.
<span class="since">Since 3.7.0 (QEMU and KVM only)</span><br/><br/>
<b>In general you should leave this option alone, unless you
are very certain you know what you are doing.</b>
</dd>
<dt>virtio options</dt>
<dd>
For virtio interfaces,

View File

@@ -2711,6 +2711,11 @@
<ref name='positiveInteger'/>
</attribute>
</optional>
<optional>
<attribute name='tx_queue_size'>
<ref name='positiveInteger'/>
</attribute>
</optional>
<optional>
<attribute name="txmode">
<choice>