Thread (15 messages) 15 messages, 3 authors, 2018-03-24

[PATCH v5 3/5] bnx2x: Eliminate duplicate barriers on weakly-ordered archs

From: davem@davemloft.net (David Miller)
Date: 2018-03-23 16:43:30
Also in: linux-arm-msm, lkml, netdev

From: Sinan Kaya <redacted>
Date: Fri, 23 Mar 2018 12:31:12 -0400
Sorry, you got me confused now.

If you look at the code closer, you'll see this.

	wmb();

	txdata->tx_db.data.prod += nbd;
	barrier();

	DOORBELL(bp, txdata->cid, txdata->tx_db.raw);

and you also asked me to rename DOORBELL to DOORBELL_RELAXED() to make
it obvious that we have a relaxed operator inside the macro.
This still doesn't match the stated pattern.

	wmb();
	/* no other memory or I/O or IOMEM operation */
	writel();

There is a write to a producer index there and then no non-compiler
barrier or any kind before the writel().

So, in fact, it might really need that implicit writel() barrier here!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help