From: Eugenio Pérez Date: Mon, 31 Aug 2020 07:59:22 +0000 (+0200) Subject: vhost: fix IOTLB mempool single-consumer flag X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=46d3f57537059ef9ec497f97d98e57a1e5f2f417;p=dpdk.git vhost: fix IOTLB mempool single-consumer flag Control thread (which handles iotlb msg) and forwarding thread both use iotlb to translate address. The former may modify the same entry of mempool and may cause a loop in iotlb_pending_entries list. Bugzilla ID: 523 Fixes: d012d1f293f4 ("vhost: add IOTLB helper functions") Cc: stable@dpdk.org Signed-off-by: Eugenio Pérez Reviewed-by: Chenbo Xia Reviewed-by: Maxime Coquelin --- diff --git a/lib/librte_vhost/iotlb.c b/lib/librte_vhost/iotlb.c index 5b3a0c090c..e0b67721b6 100644 --- a/lib/librte_vhost/iotlb.c +++ b/lib/librte_vhost/iotlb.c @@ -321,8 +321,7 @@ vhost_user_iotlb_init(struct virtio_net *dev, int vq_index) IOTLB_CACHE_SIZE, sizeof(struct vhost_iotlb_entry), 0, 0, 0, NULL, NULL, NULL, socket, MEMPOOL_F_NO_CACHE_ALIGN | - MEMPOOL_F_SP_PUT | - MEMPOOL_F_SC_GET); + MEMPOOL_F_SP_PUT); if (!vq->iotlb_pool) { VHOST_LOG_CONFIG(ERR, "Failed to create IOTLB cache pool (%s)\n",