aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/renesas
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2013-09-05 14:58:52 -0400
committerDavid S. Miller <davem@davemloft.net>2013-09-05 14:58:52 -0400
commit06c54055bebf919249aa1eb68312887c3cfe77b4 (patch)
tree223a49c09e5d26516ed0161b8a52d08454ae028e /drivers/net/ethernet/renesas
parent1a5bbfc3d6b700178b75743a2ba1fd2e58a8f36f (diff)
parente2e5c4c07caf810d7849658dca42f598b3938e21 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts: drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c net/bridge/br_multicast.c net/ipv6/sit.c The conflicts were minor: 1) sit.c changes overlap with change to ip_tunnel_xmit() signature. 2) br_multicast.c had an overlap between computing max_delay using msecs_to_jiffies and turning MLDV2_MRC() into an inline function with a name using lowercase instead of uppercase letters. 3) stmmac had two overlapping changes, one which conditionally allocated and hooked up a dma_cfg based upon the presence of the pbl OF property, and another one handling store-and-forward DMA made. The latter of which should not go into the new of_find_property() basic block. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/renesas')
-rw-r--r--drivers/net/ethernet/renesas/sh_eth.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/net/ethernet/renesas/sh_eth.c b/drivers/net/ethernet/renesas/sh_eth.c
index 474c8a86a2af..5cd831ebfa83 100644
--- a/drivers/net/ethernet/renesas/sh_eth.c
+++ b/drivers/net/ethernet/renesas/sh_eth.c
@@ -1348,7 +1348,7 @@ static int sh_eth_rx(struct net_device *ndev, u32 intr_status, int *quota)
1348 DMA_FROM_DEVICE); 1348 DMA_FROM_DEVICE);
1349 skb_put(skb, pkt_len); 1349 skb_put(skb, pkt_len);
1350 skb->protocol = eth_type_trans(skb, ndev); 1350 skb->protocol = eth_type_trans(skb, ndev);
1351 netif_rx(skb); 1351 netif_receive_skb(skb);
1352 ndev->stats.rx_packets++; 1352 ndev->stats.rx_packets++;
1353 ndev->stats.rx_bytes += pkt_len; 1353 ndev->stats.rx_bytes += pkt_len;
1354 } 1354 }
@@ -1906,11 +1906,13 @@ static int sh_eth_open(struct net_device *ndev)
1906 1906
1907 pm_runtime_get_sync(&mdp->pdev->dev); 1907 pm_runtime_get_sync(&mdp->pdev->dev);
1908 1908
1909 napi_enable(&mdp->napi);
1910
1909 ret = request_irq(ndev->irq, sh_eth_interrupt, 1911 ret = request_irq(ndev->irq, sh_eth_interrupt,
1910 mdp->cd->irq_flags, ndev->name, ndev); 1912 mdp->cd->irq_flags, ndev->name, ndev);
1911 if (ret) { 1913 if (ret) {
1912 dev_err(&ndev->dev, "Can not assign IRQ number\n"); 1914 dev_err(&ndev->dev, "Can not assign IRQ number\n");
1913 return ret; 1915 goto out_napi_off;
1914 } 1916 }
1915 1917
1916 /* Descriptor set */ 1918 /* Descriptor set */
@@ -1928,12 +1930,12 @@ static int sh_eth_open(struct net_device *ndev)
1928 if (ret) 1930 if (ret)
1929 goto out_free_irq; 1931 goto out_free_irq;
1930 1932
1931 napi_enable(&mdp->napi);
1932
1933 return ret; 1933 return ret;
1934 1934
1935out_free_irq: 1935out_free_irq:
1936 free_irq(ndev->irq, ndev); 1936 free_irq(ndev->irq, ndev);
1937out_napi_off:
1938 napi_disable(&mdp->napi);
1937 pm_runtime_put_sync(&mdp->pdev->dev); 1939 pm_runtime_put_sync(&mdp->pdev->dev);
1938 return ret; 1940 return ret;
1939} 1941}
@@ -2025,8 +2027,6 @@ static int sh_eth_close(struct net_device *ndev)
2025{ 2027{
2026 struct sh_eth_private *mdp = netdev_priv(ndev); 2028 struct sh_eth_private *mdp = netdev_priv(ndev);
2027 2029
2028 napi_disable(&mdp->napi);
2029
2030 netif_stop_queue(ndev); 2030 netif_stop_queue(ndev);
2031 2031
2032 /* Disable interrupts by clearing the interrupt mask. */ 2032 /* Disable interrupts by clearing the interrupt mask. */
@@ -2044,6 +2044,8 @@ static int sh_eth_close(struct net_device *ndev)
2044 2044
2045 free_irq(ndev->irq, ndev); 2045 free_irq(ndev->irq, ndev);
2046 2046
2047 napi_disable(&mdp->napi);
2048
2047 /* Free all the skbuffs in the Rx queue. */ 2049 /* Free all the skbuffs in the Rx queue. */
2048 sh_eth_ring_free(ndev); 2050 sh_eth_ring_free(ndev);
2049 2051