From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 809FF5A95 for ; Thu, 29 Jan 2015 08:25:17 +0100 (CET) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP; 28 Jan 2015 23:19:03 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.97,862,1389772800"; d="scan'208";a="446876077" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by FMSMGA003.fm.intel.com with ESMTP; 28 Jan 2015 23:11:26 -0800 Received: from shecgisg004.sh.intel.com (shecgisg004.sh.intel.com [10.239.29.89]) by shvmail01.sh.intel.com with ESMTP id t0T7PCVH017637; Thu, 29 Jan 2015 15:25:12 +0800 Received: from shecgisg004.sh.intel.com (localhost [127.0.0.1]) by shecgisg004.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id t0T7P9am014807; Thu, 29 Jan 2015 15:25:11 +0800 Received: (from couyang@localhost) by shecgisg004.sh.intel.com (8.13.6/8.13.6/Submit) id t0T7P9s2014803; Thu, 29 Jan 2015 15:25:09 +0800 From: Ouyang Changchun To: dev@dpdk.org Date: Thu, 29 Jan 2015 15:24:09 +0800 Message-Id: <1422516249-14596-26-git-send-email-changchun.ouyang@intel.com> X-Mailer: git-send-email 1.7.12.2 In-Reply-To: <1422516249-14596-1-git-send-email-changchun.ouyang@intel.com> References: <1422326164-13697-1-git-send-email-changchun.ouyang@intel.com> <1422516249-14596-1-git-send-email-changchun.ouyang@intel.com> Subject: [dpdk-dev] [PATCH v3 25/25] virtio: Fix wmb issue X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Jan 2015 07:25:18 -0000 It needs use virtio_wmb instead of virtio_rmb for store memory barrier. Signed-off-by: Changchun Ouyang --- lib/librte_pmd_virtio/virtqueue.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_pmd_virtio/virtqueue.h b/lib/librte_pmd_virtio/virtqueue.h index 6c45c27..41dda50 100644 --- a/lib/librte_pmd_virtio/virtqueue.h +++ b/lib/librte_pmd_virtio/virtqueue.h @@ -266,7 +266,7 @@ virtqueue_full(const struct virtqueue *vq) static inline void vq_update_avail_idx(struct virtqueue *vq) { - virtio_rmb(); + virtio_wmb(); vq->vq_ring.avail->idx = vq->vq_avail_idx; } -- 1.8.4.2