netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Denis Bolotin <dbolotin@marvell.com>,
	Ariel Elior <aelior@marvell.com>,
	"David S . Miller" <davem@davemloft.net>,
	Sasha Levin <sashal@kernel.org>,
	netdev@vger.kernel.org
Subject: [PATCH AUTOSEL 4.19 22/83] qed: Fix qed_ll2_post_rx_buffer_notify_fw() by adding a write memory barrier
Date: Tue, 12 Feb 2019 21:36:00 -0500	[thread overview]
Message-ID: <20190213023701.20286-22-sashal@kernel.org> (raw)
In-Reply-To: <20190213023701.20286-1-sashal@kernel.org>

From: Denis Bolotin <dbolotin@marvell.com>

[ Upstream commit 46721c3d9e273aea880e9ff835b0e1271e1cd2fb ]

Make sure chain element is updated before ringing the doorbell.

Signed-off-by: Denis Bolotin <dbolotin@marvell.com>
Signed-off-by: Ariel Elior <aelior@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 drivers/net/ethernet/qlogic/qed/qed_ll2.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/ethernet/qlogic/qed/qed_ll2.c b/drivers/net/ethernet/qlogic/qed/qed_ll2.c
index 2fa1c050a14b..92cd8abeb41d 100644
--- a/drivers/net/ethernet/qlogic/qed/qed_ll2.c
+++ b/drivers/net/ethernet/qlogic/qed/qed_ll2.c
@@ -1592,6 +1592,10 @@ static void qed_ll2_post_rx_buffer_notify_fw(struct qed_hwfn *p_hwfn,
 	cq_prod = qed_chain_get_prod_idx(&p_rx->rcq_chain);
 	rx_prod.bd_prod = cpu_to_le16(bd_prod);
 	rx_prod.cqe_prod = cpu_to_le16(cq_prod);
+
+	/* Make sure chain element is updated before ringing the doorbell */
+	dma_wmb();
+
 	DIRECT_REG_WR(p_rx->set_prod_addr, *((u32 *)&rx_prod));
 }
 
-- 
2.19.1


  parent reply	other threads:[~2019-02-13  2:55 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20190213023701.20286-1-sashal@kernel.org>
2019-02-13  2:35 ` [PATCH AUTOSEL 4.19 21/83] qed: Fix qed_chain_set_prod() for PBL chains with non power of 2 page count Sasha Levin
2019-02-13  2:36 ` Sasha Levin [this message]
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 23/83] net: hns: Fix use after free identified by SLUB debug Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 24/83] bpf: Fix [::] -> [::1] rewrite in sys_sendmsg Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 25/83] selftests/bpf: Test [::] -> [::1] rewrite in sys_sendmsg in test_sock_addr Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 27/83] net/mlx4: Get rid of page operation after dma_alloc_coherent Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 29/83] xprtrdma: Double free in rpcrdma_sendctxs_create() Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 30/83] mlxsw: spectrum_acl: Add cleanup after C-TCAM update error condition Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 31/83] selftests: forwarding: Add a test for VLAN deletion Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 32/83] netfilter: nf_tables: fix leaking object reference count Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 37/83] netfilter: nft_flow_offload: Fix reverse route lookup Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 38/83] bpf: correctly set initial window on active Fast Open sender Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 40/83] bpf: fix panic in stack_map_get_build_id() on i386 and arm32 Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 41/83] netfilter: nft_flow_offload: fix interaction with vrf slave device Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 45/83] net: stmmac: Fix PCI module removal leak Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 46/83] net: stmmac: dwxgmac2: Only clear interrupts that are active Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 47/83] net: stmmac: Check if CBS is supported before configuring Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 48/83] net: stmmac: Fix the logic of checking if RX Watchdog must be enabled Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 49/83] net: stmmac: Prevent RX starvation in stmmac_napi_poll() Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 50/83] isdn: i4l: isdn_tty: Fix some concurrency double-free bugs Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 56/83] netfilter: nft_flow_offload: fix checking method of conntrack helper Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 61/83] vhost: return EINVAL if iovecs size does not match the message size Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 70/83] bpf: don't assume build-id length is always 20 bytes Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 71/83] bpf: zero out build_id for BPF_STACK_BUILD_ID_IP Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 72/83] selftests/bpf: retry tests that expect build-id Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 73/83] atm: he: fix sign-extension overflow on large shift Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 76/83] bpf: bpf_setsockopt: reset sock dst on SO_MARK changes Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 77/83] dpaa_eth: NETIF_F_LLTX requires to do our own update of trans_start Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 78/83] mlxsw: pci: Return error on PCI reset timeout Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 79/83] net: bridge: Mark FDB entries that were added by user as such Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 80/83] mlxsw: spectrum_switchdev: Do not treat static FDB entries as sticky Sasha Levin
2019-02-13  2:36 ` [PATCH AUTOSEL 4.19 81/83] selftests: forwarding: Add a test case for externally learned FDB entries Sasha Levin
2019-02-13  2:37 ` [PATCH AUTOSEL 4.19 82/83] net/mlx5e: Fix wrong (zero) TX drop counter indication for representor Sasha Levin
2019-02-13  2:37 ` [PATCH AUTOSEL 4.19 83/83] isdn: avm: Fix string plus integer warning from Clang Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190213023701.20286-22-sashal@kernel.org \
    --to=sashal@kernel.org \
    --cc=aelior@marvell.com \
    --cc=davem@davemloft.net \
    --cc=dbolotin@marvell.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).