From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-eopbgr60082.outbound.protection.outlook.com [40.107.6.82]) by dpdk.org (Postfix) with ESMTP id B4B231B347 for ; Fri, 19 Jan 2018 01:45:08 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=bhYfG5UyYaeRSVX9AOxgk5u6nSebBNMH6eGtHDD/Fro=; b=PxuMb/BSt5OLs7jgPcZ2rfKk8O1Gceie+ZBoupLsOQuRec3gDgsW+lojxc9+ieG6u7BV0CgS0aCm56LXKz5H/ORaYKmfY2R0vcWM2wXjfSudWg3VYCp86tApzNOMVMTTW8DyvHyQVstrdFGpB8xwv/pGA/J/VNQBRhg4/CW5540= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=yskoh@mellanox.com; Received: from mellanox.com (209.116.155.178) by VI1PR0501MB2045.eurprd05.prod.outlook.com (2603:10a6:800:36::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.428.17; Fri, 19 Jan 2018 00:45:03 +0000 From: Yongseok Koh To: adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com, bruce.richardson@intel.com, konstantin.ananyev@intel.com, chaozhu@linux.vnet.ibm.com, jerin.jacob@caviumnetworks.com, jianbo.liu@arm.com Cc: dev@dpdk.org, Yongseok Koh Date: Thu, 18 Jan 2018 16:44:29 -0800 Message-Id: <20180119004430.15305-8-yskoh@mellanox.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180119004430.15305-1-yskoh@mellanox.com> References: <20180116011050.18866-1-yskoh@mellanox.com> <20180119004430.15305-1-yskoh@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [209.116.155.178] X-ClientProxiedBy: DM5PR2001CA0022.namprd20.prod.outlook.com (2603:10b6:4:16::32) To VI1PR0501MB2045.eurprd05.prod.outlook.com (2603:10a6:800:36::19) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 4cea0455-ea4a-4caa-0c2f-08d55ed5e218 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4604075)(48565401081)(2017052603307)(7153060)(7193020); SRVR:VI1PR0501MB2045; X-Microsoft-Exchange-Diagnostics: 1; VI1PR0501MB2045; 3:bWZB402dXt4BJg447u1Kxrjfl8w/IoEwYdfVoYTS0T21k24EupwSK2c6b4apOcu4SuOPOQHpR0eAOQewBoH64gd7z57HFqD/02sJX3WEpGVFJG5UCfpZbqspj5tcZHgIpYmaJme8AraQbadvYG7no12olAeSf8+osjG5GdCWNiMFQqg57MUe1NAPTFoZVtdEgYf0qJcdEJqS7K9UyYPIaXlPuvid0lwMJ18VGrDAxHY3Ds8Eb5ViPdlqze/ih3T7; 25:lVKZhGNdC0zF2oMv2A+eg3GFkzpIGspjTYZmhgJIo2p3a/5TzbCsiQBjLju/odr4yfICCoOQSlmOhngv+9y2odOU27oPe6wFhzboMJSAQhAo2g3xjs+nlKEx6/7ER8sPkaSPZ1tUCQQXa6pS6ePksrIeYUQYelYL18kVscg2g+cTGp77MuqQe2Yzc+/FMFyQckE1Qh3NPviSEpMoaQY1nzAwrHzrTmO6hZA+7hW6YrtrwL13TcZ3INiOZY9haNE6ybSleBnEtJ6XAEbIaUvQt0PT1/pzThWCUJRuAkYyyK95fUy8alFc3X14EXLjAFOwHhBMukiSs1uZ+pnLHmHUVQ==; 31:BXGGr4i4WZG8/RcIallU04qPCgVkQpSEWZOIXhHoaRj6irLs0L1OasS5G1xDE2m9e1gZtIdjWNtO5GXGBBLSTOkVo59uMobDOIEpiAsEauyBP0pNbBe6gv75LJWEUAvDE9L+A1fE80mTGHdDB9PQfpYCCbMz0wYrCt3CNQeb10ffMxW6Lj0W8BQRWP4MP66ItL7wiyzW25C8iN/b7Ere4j+YywMIyazC1h27IvnjS8k= X-MS-TrafficTypeDiagnostic: VI1PR0501MB2045: X-LD-Processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr X-Microsoft-Exchange-Diagnostics: 1; VI1PR0501MB2045; 20:YwNQc8zx9IeS1N1Te8b/LY4LkZhCq95YsYzeh7AhfJROyXFkOuMPz0MAyd3crd0k1ZKRO8Dv1G/2kYX1bcC0F7ZD/Fz+Mrv6aKNKtD3wLKnAD+Fq2BcABIlPPkSg9ttyzzowUhXRse/hVptX6JDYr+taU0rqWV82gsh12qeR9eRcrpIXWGRQs5heFdE03mf0SGWJdA6R9i6Ny4aAxcATlj/iZZhP7YM0VjaLHzE75ySFph503N2kFVqUQT37qj+P52kLm3R6rdFb/E1ou8wpfAuId9orh3tj4lfcftLZ6lobHwjJ8sQ3UUz0AmLQGlO/6EJYbS6d8XknTShnEfMNEPTrNAqOMSc9WhCgnVvXAucl7f80pjdLuHnZ+tr5AVkQiKR5rSdKZWJNs95zg8OsI9QKX+k0TEEjji3f25zgUiUXZ70tMnKhqr8hkIfCNx5Z7ePFLKceZ3AgZ32Z/g/O8LIvpQUNo86fvxnkyUc0UT7n0kZ68twpp/p1tVeDNBTX; 4:RrshYIiY1ObGcP/COWgwsdCB7VobIHHhXbjHbzP/xGt7+C+CWxiGkVai0gNZQHTxDRHQhTnJHr7Lw8ZzRZxI6aP0/ZGHYlVS/AvcWVwk6dw0dBGXPGG9mJjrO5VWr0zZumfJZOBkdmgxlIoNLOYhDQgwQ1meqL05Itg3Ky7DEn7g1En0QFm+2IDS9QVbMKuSF0Wm5kf8HxyywNHSD1nfcmUwhePidA/UNcGZOHNoiZ4q7Lz58OKSowCbWpkznl1MSrjqUanz2dCAzSMVwty/vO557Fa0F3+qrVpxv/rcy1nY+lpB6x7ozoRfyCw2DgEN X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(788757137089); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040495)(2401047)(5005006)(8121501046)(3231023)(2400069)(944501161)(10201501046)(3002001)(93006095)(93001095)(6055026)(6041282)(20161123562045)(20161123564045)(20161123558120)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011); SRVR:VI1PR0501MB2045; BCL:0; PCL:0; RULEID:(100000803101)(100110400095); SRVR:VI1PR0501MB2045; X-Forefront-PRVS: 0557CBAD84 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(39380400002)(396003)(346002)(376002)(366004)(39860400002)(189003)(199004)(25786009)(48376002)(59450400001)(50466002)(386003)(7696005)(76176011)(51416003)(52116002)(4326008)(478600001)(86362001)(36756003)(305945005)(7736002)(16526018)(26005)(16586007)(2950100002)(6666003)(316002)(97736004)(5660300001)(105586002)(106356001)(53936002)(47776003)(66066001)(8936002)(8676002)(21086003)(81156014)(50226002)(81166006)(2906002)(6116002)(3846002)(68736007)(69596002)(107886003)(1076002)(55016002); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR0501MB2045; H:mellanox.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; VI1PR0501MB2045; 23:Jf8nRErhjUzH5Km5l0yoBa0yMmQa7miAYbnDr9t?= =?us-ascii?Q?y9LaX9IsBvCY3Rb5XB8vJmu+wwrK57wfujH01NRRpkDqYliBVme9VSYoylXw?= =?us-ascii?Q?ZG1eYRsWHVYQkUTbM8WN7MTsf8kD6tWrZPua80a0jbvMdcTalE5i8wDbgGnp?= =?us-ascii?Q?8ZUvVmRh9pwnSYETa/Cs4xlGZkDHXO2ye6HQHerAPwAwp0mD230IzWoeVARU?= =?us-ascii?Q?U2WiQXnLi/v6t8oS5M2dER0WCguuyoUCUWQV0a1m8tqu2J/m/qdxZwN7bQzd?= =?us-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WB5/5afFnN31hxQ=3D?= =?us-ascii?Q?=3D?= X-Microsoft-Exchange-Diagnostics: 1; VI1PR0501MB2045; 6:G5BC0/3jcD21rWlvOG6Q94bTAe/KixiVBMU3odSgW5WdKqtGPYHAx4x0MAPAB5UZgvbDOn07psIzVj9PZx5naXMgIYCEhCCkdInN7Ur7+Ra8vwRnKtFzbIIvFmMyeffFlpG8dIBO8IL22lswH9582nHoKX220LQwY3emTvPbtdGKmEXvh9H1pmopma2e8dvA4BwNql8dvWm2ob9O/arsLG7cHDRl6kis2Q44cFPqhQlwu8LTtcC3p3rc+r+5r963EkP6eFc6wzCrxQBoq7fNrsjxTRSAZD7GZKzuOVzrYB1tvl9QvKO4eMOUFTgy3dA1ELZUCLr/thVrGewLDTjMA4zH59eLlYX7bEvcBHk0mNk=; 5:IRePW2DIquDV9bgn2y8wWDj1oCAojAdtDO3EWrEnTSgpHhj8UZkgRyNXMLyuoLQ9rL/u8VhOUjO5erEh7TwLKBJaFWo582Kq9c+rpuwP09lHJgfzcqdN124J6sGJtFheHt9QzMO4DDSh+aguW07C8EW8FkzlUoc6g3yMEKBwc5Y=; 24:CXxz3p4//GW5WHrUV26b75iIWVIVZ7ZLN0dqRY3OpzFkq73EMItvcaC66xrOG8IXkRmhFfeuaYWltr3ePADUQdIZGIefH7aNvC509ya0nMk=; 7:b/7NhmFO90wdBlcs54lUTC9aK4ohwwxft8AkanYF+jS4NKdJLT8VqaD4r8fSbbcmqEQN07YMzwpsJ8sgyKOsniFWT5pwxAsYCniCqljj5afjAOufo4Y58TJLdhynPvu5HiVKgzAx8fyvaZ2KEszAYexDktDDDAi5KE7fJo2ZyK/IZM4RuoKCMpIKpgjfKiKZI+BVC2CjQcUzrXzqGaU6BlMSeIEYpTC0LcuoVeeZ7T80qEGykFXooafJus4NyTgY SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Jan 2018 00:45:03.8002 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 4cea0455-ea4a-4caa-0c2f-08d55ed5e218 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0501MB2045 Subject: [dpdk-dev] [PATCH v3 7/8] net/mlx5: replace IO memory barrier with DMA memory barrier X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jan 2018 00:45:09 -0000 Signed-off-by: Yongseok Koh --- drivers/net/mlx5/mlx5_rxtx.c | 4 ++-- drivers/net/mlx5/mlx5_rxtx.h | 2 +- drivers/net/mlx5/mlx5_rxtx_vec.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/mlx5/mlx5_rxtx.c b/drivers/net/mlx5/mlx5_rxtx.c index 3b8f71c28..99a5f8681 100644 --- a/drivers/net/mlx5/mlx5_rxtx.c +++ b/drivers/net/mlx5/mlx5_rxtx.c @@ -1898,9 +1898,9 @@ mlx5_rx_burst(void *dpdk_rxq, struct rte_mbuf **pkts, uint16_t pkts_n) return 0; /* Update the consumer index. */ rxq->rq_ci = rq_ci >> sges_n; - rte_io_wmb(); + rte_dma_wmb(); *rxq->cq_db = rte_cpu_to_be_32(rxq->cq_ci); - rte_io_wmb(); + rte_dma_wmb(); *rxq->rq_db = rte_cpu_to_be_32(rxq->rq_ci); #ifdef MLX5_PMD_SOFT_COUNTERS /* Increment packets counter. */ diff --git a/drivers/net/mlx5/mlx5_rxtx.h b/drivers/net/mlx5/mlx5_rxtx.h index a239642ac..480653f34 100644 --- a/drivers/net/mlx5/mlx5_rxtx.h +++ b/drivers/net/mlx5/mlx5_rxtx.h @@ -598,7 +598,7 @@ mlx5_tx_dbrec_cond_wmb(struct mlx5_txq_data *txq, volatile struct mlx5_wqe *wqe, uint64_t *dst = (uint64_t *)((uintptr_t)txq->bf_reg); volatile uint64_t *src = ((volatile uint64_t *)wqe); - rte_io_wmb(); + rte_dma_wmb(); *txq->qp_db = rte_cpu_to_be_32(txq->wqe_ci); /* Ensure ordering between DB record and BF copy. */ rte_wmb(); diff --git a/drivers/net/mlx5/mlx5_rxtx_vec.h b/drivers/net/mlx5/mlx5_rxtx_vec.h index 7d7f016f1..9db1dddbe 100644 --- a/drivers/net/mlx5/mlx5_rxtx_vec.h +++ b/drivers/net/mlx5/mlx5_rxtx_vec.h @@ -135,7 +135,7 @@ mlx5_rx_replenish_bulk_mbuf(struct mlx5_rxq_data *rxq, uint16_t n) elts_idx = rxq->rq_ci & q_mask; for (i = 0; i < MLX5_VPMD_DESCS_PER_LOOP; ++i) (*rxq->elts)[elts_idx + i] = &rxq->fake_mbuf; - rte_io_wmb(); + rte_dma_wmb(); *rxq->rq_db = rte_cpu_to_be_32(rxq->rq_ci); } -- 2.11.0