net/virtio: add Rx free threshold setting
authorMarvin Liu <yong.liu@intel.com>
Wed, 29 Apr 2020 07:28:14 +0000 (15:28 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 5 May 2020 13:54:26 +0000 (15:54 +0200)
commit1982462eadeaf52e9b4bc0f9c3a795787e7e5624
treef8befe13f57745739874ce48b0b7e6779bd87364
parent9f09b1ca15c57ecdd6af793ec7ca776d7cb2e313
net/virtio: add Rx free threshold setting

Introduce free threshold setting in Rx queue, its default value is 32.
Limit the threshold size to multiple of four as only vectorized packed
Rx function will utilize it. Virtio driver will rearm Rx queue when
more than rx_free_thresh descs were dequeued.

Signed-off-by: Marvin Liu <yong.liu@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
drivers/net/virtio/virtio_rxtx.c
drivers/net/virtio/virtqueue.h