netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] ibmvnic: substitute mb() with dma_wmb() for send_*crq* functions
@ 2021-02-13  2:36 Lijun Pan
  2021-02-15 23:20 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Lijun Pan @ 2021-02-13  2:36 UTC (permalink / raw)
  To: netdev; +Cc: sukadev, drt, Lijun Pan, Thomas Falcon

The CRQ and subCRQ descriptors are DMA mapped, so dma_wmb(),
though weaker, is good enough to protect the data structures.

Signed-off-by: Lijun Pan <ljp@linux.ibm.com>
Acked-by: Thomas Falcon <tlfalcon@linux.ibm.com>
---
 drivers/net/ethernet/ibm/ibmvnic.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c
index 7a5e589e7223..927d5f36d308 100644
--- a/drivers/net/ethernet/ibm/ibmvnic.c
+++ b/drivers/net/ethernet/ibm/ibmvnic.c
@@ -3599,7 +3599,7 @@ static int send_subcrq_indirect(struct ibmvnic_adapter *adapter,
 	int rc;
 
 	/* Make sure the hypervisor sees the complete request */
-	mb();
+	dma_wmb();
 	rc = plpar_hcall_norets(H_SEND_SUB_CRQ_INDIRECT, ua,
 				cpu_to_be64(remote_handle),
 				ioba, num_entries);
@@ -3629,7 +3629,7 @@ static int ibmvnic_send_crq(struct ibmvnic_adapter *adapter,
 	}
 
 	/* Make sure the hypervisor sees the complete request */
-	mb();
+	dma_wmb();
 
 	rc = plpar_hcall_norets(H_SEND_CRQ, ua,
 				cpu_to_be64(u64_crq[0]),
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net-next] ibmvnic: substitute mb() with dma_wmb() for send_*crq* functions
  2021-02-13  2:36 [PATCH net-next] ibmvnic: substitute mb() with dma_wmb() for send_*crq* functions Lijun Pan
@ 2021-02-15 23:20 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-02-15 23:20 UTC (permalink / raw)
  To: Lijun Pan; +Cc: netdev, sukadev, drt, tlfalcon

Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

On Fri, 12 Feb 2021 20:36:46 -0600 you wrote:
> The CRQ and subCRQ descriptors are DMA mapped, so dma_wmb(),
> though weaker, is good enough to protect the data structures.
> 
> Signed-off-by: Lijun Pan <ljp@linux.ibm.com>
> Acked-by: Thomas Falcon <tlfalcon@linux.ibm.com>
> ---
>  drivers/net/ethernet/ibm/ibmvnic.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Here is the summary with links:
  - [net-next] ibmvnic: substitute mb() with dma_wmb() for send_*crq* functions
    https://git.kernel.org/netdev/net-next/c/1a42156f52bd

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-02-15 23:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-13  2:36 [PATCH net-next] ibmvnic: substitute mb() with dma_wmb() for send_*crq* functions Lijun Pan
2021-02-15 23:20 ` patchwork-bot+netdevbpf

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).