netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/5] net: sh_eth: fix cache coherency issue
@ 2009-05-25  9:52 Yoshihiro Shimoda
  2009-05-26  5:50 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Yoshihiro Shimoda @ 2009-05-25  9:52 UTC (permalink / raw)
  To: netdev; +Cc: SH-Linux, Nobuhiro Iwamatsu

Fix the problem that may not work receive process by cache coherency issue.

Signed-off-by: Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu.nobuhiro@renesas.com>
---
 drivers/net/sh_eth.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/net/sh_eth.c b/drivers/net/sh_eth.c
index 3ab28bb..a742297 100644
--- a/drivers/net/sh_eth.c
+++ b/drivers/net/sh_eth.c
@@ -250,6 +250,8 @@ static void sh_eth_ring_format(struct net_device *ndev)
 		mdp->rx_skbuff[i] = skb;
 		if (skb == NULL)
 			break;
+		dma_map_single(&ndev->dev, skb->tail, mdp->rx_buf_sz,
+				DMA_FROM_DEVICE);
 		skb->dev = ndev; /* Mark as being used by this device. */
 #if defined(CONFIG_CPU_SUBTYPE_SH7763)
 		reserve = SH7763_SKB_ALIGN
@@ -559,6 +561,8 @@ static int sh_eth_rx(struct net_device *ndev)
 			mdp->rx_skbuff[entry] = skb;
 			if (skb == NULL)
 				break;	/* Better luck next round. */
+			dma_map_single(&ndev->dev, skb->tail, mdp->rx_buf_sz,
+					DMA_FROM_DEVICE);
 			skb->dev = ndev;
 #if defined(CONFIG_CPU_SUBTYPE_SH7763)
 			reserve = SH7763_SKB_ALIGN
-- 
1.5.5


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

* Re: [PATCH 1/5] net: sh_eth: fix cache coherency issue
  2009-05-25  9:52 [PATCH 1/5] net: sh_eth: fix cache coherency issue Yoshihiro Shimoda
@ 2009-05-26  5:50 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2009-05-26  5:50 UTC (permalink / raw)
  To: shimoda.yoshihiro; +Cc: netdev, linux-sh, iwamatsu.nobuhiro


All 5 patches applied to net-next-2.6

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

end of thread, other threads:[~2009-05-26  5:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-25  9:52 [PATCH 1/5] net: sh_eth: fix cache coherency issue Yoshihiro Shimoda
2009-05-26  5:50 ` David Miller

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