aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2010-05-12 03:05:35 -0400
committerDavid S. Miller <davem@davemloft.net>2010-05-12 03:05:35 -0400
commit278554bd6579206921f5d8a523649a7a57f8850d (patch)
tree4e6c527daf0910e455b3aa72e2c96b0479e430be /drivers/net
parent5a147e8bf982f9dd414c1dd751fe02c1942506b2 (diff)
parentcea0d767c29669bf89f86e4aee46ef462d2ebae8 (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: Documentation/feature-removal-schedule.txt drivers/net/wireless/ath/ar9170/usb.c drivers/scsi/iscsi_tcp.c net/ipv4/ipmr.c
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/arm/ep93xx_eth.c10
-rw-r--r--drivers/net/fec.c2
-rw-r--r--drivers/net/gianfar.c2
-rw-r--r--drivers/net/phy/mdio-octeon.c10
-rw-r--r--drivers/net/phy/micrel.c1
-rw-r--r--drivers/net/veth.c1
-rw-r--r--drivers/net/wireless/ath/ar9170/usb.c11
-rw-r--r--drivers/net/wireless/ath/ar9170/usb.h1
8 files changed, 30 insertions, 8 deletions
diff --git a/drivers/net/arm/ep93xx_eth.c b/drivers/net/arm/ep93xx_eth.c
index c5f6736b7d69..4a5ec9470aa1 100644
--- a/drivers/net/arm/ep93xx_eth.c
+++ b/drivers/net/arm/ep93xx_eth.c
@@ -311,11 +311,6 @@ err:
311 processed++; 311 processed++;
312 } 312 }
313 313
314 if (processed) {
315 wrw(ep, REG_RXDENQ, processed);
316 wrw(ep, REG_RXSTSENQ, processed);
317 }
318
319 return processed; 314 return processed;
320} 315}
321 316
@@ -350,6 +345,11 @@ poll_some_more:
350 goto poll_some_more; 345 goto poll_some_more;
351 } 346 }
352 347
348 if (rx) {
349 wrw(ep, REG_RXDENQ, rx);
350 wrw(ep, REG_RXSTSENQ, rx);
351 }
352
353 return rx; 353 return rx;
354} 354}
355 355
diff --git a/drivers/net/fec.c b/drivers/net/fec.c
index 47da51957803..42d9ac9ba395 100644
--- a/drivers/net/fec.c
+++ b/drivers/net/fec.c
@@ -1031,7 +1031,7 @@ fec_set_mac_address(struct net_device *dev, void *p)
1031 (dev->dev_addr[1] << 16) | (dev->dev_addr[0] << 24), 1031 (dev->dev_addr[1] << 16) | (dev->dev_addr[0] << 24),
1032 fep->hwp + FEC_ADDR_LOW); 1032 fep->hwp + FEC_ADDR_LOW);
1033 writel((dev->dev_addr[5] << 16) | (dev->dev_addr[4] << 24), 1033 writel((dev->dev_addr[5] << 16) | (dev->dev_addr[4] << 24),
1034 fep + FEC_ADDR_HIGH); 1034 fep->hwp + FEC_ADDR_HIGH);
1035 return 0; 1035 return 0;
1036} 1036}
1037 1037
diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c
index 11d8cae415e5..ea7d5ddb7760 100644
--- a/drivers/net/gianfar.c
+++ b/drivers/net/gianfar.c
@@ -1705,6 +1705,7 @@ static void free_skb_resources(struct gfar_private *priv)
1705 sizeof(struct rxbd8) * priv->total_rx_ring_size, 1705 sizeof(struct rxbd8) * priv->total_rx_ring_size,
1706 priv->tx_queue[0]->tx_bd_base, 1706 priv->tx_queue[0]->tx_bd_base,
1707 priv->tx_queue[0]->tx_bd_dma_base); 1707 priv->tx_queue[0]->tx_bd_dma_base);
1708 skb_queue_purge(&priv->rx_recycle);
1708} 1709}
1709 1710
1710void gfar_start(struct net_device *dev) 1711void gfar_start(struct net_device *dev)
@@ -2185,7 +2186,6 @@ static int gfar_close(struct net_device *dev)
2185 2186
2186 disable_napi(priv); 2187 disable_napi(priv);
2187 2188
2188 skb_queue_purge(&priv->rx_recycle);
2189 cancel_work_sync(&priv->reset_task); 2189 cancel_work_sync(&priv->reset_task);
2190 stop_gfar(dev); 2190 stop_gfar(dev);
2191 2191
diff --git a/drivers/net/phy/mdio-octeon.c b/drivers/net/phy/mdio-octeon.c
index a872aea4ed74..f443d43edd80 100644
--- a/drivers/net/phy/mdio-octeon.c
+++ b/drivers/net/phy/mdio-octeon.c
@@ -88,6 +88,7 @@ static int octeon_mdiobus_write(struct mii_bus *bus, int phy_id,
88static int __init octeon_mdiobus_probe(struct platform_device *pdev) 88static int __init octeon_mdiobus_probe(struct platform_device *pdev)
89{ 89{
90 struct octeon_mdiobus *bus; 90 struct octeon_mdiobus *bus;
91 union cvmx_smix_en smi_en;
91 int i; 92 int i;
92 int err = -ENOENT; 93 int err = -ENOENT;
93 94
@@ -103,6 +104,10 @@ static int __init octeon_mdiobus_probe(struct platform_device *pdev)
103 if (!bus->mii_bus) 104 if (!bus->mii_bus)
104 goto err; 105 goto err;
105 106
107 smi_en.u64 = 0;
108 smi_en.s.en = 1;
109 cvmx_write_csr(CVMX_SMIX_EN(bus->unit), smi_en.u64);
110
106 /* 111 /*
107 * Standard Octeon evaluation boards don't support phy 112 * Standard Octeon evaluation boards don't support phy
108 * interrupts, we need to poll. 113 * interrupts, we need to poll.
@@ -133,17 +138,22 @@ err_register:
133 138
134err: 139err:
135 devm_kfree(&pdev->dev, bus); 140 devm_kfree(&pdev->dev, bus);
141 smi_en.u64 = 0;
142 cvmx_write_csr(CVMX_SMIX_EN(bus->unit), smi_en.u64);
136 return err; 143 return err;
137} 144}
138 145
139static int __exit octeon_mdiobus_remove(struct platform_device *pdev) 146static int __exit octeon_mdiobus_remove(struct platform_device *pdev)
140{ 147{
141 struct octeon_mdiobus *bus; 148 struct octeon_mdiobus *bus;
149 union cvmx_smix_en smi_en;
142 150
143 bus = dev_get_drvdata(&pdev->dev); 151 bus = dev_get_drvdata(&pdev->dev);
144 152
145 mdiobus_unregister(bus->mii_bus); 153 mdiobus_unregister(bus->mii_bus);
146 mdiobus_free(bus->mii_bus); 154 mdiobus_free(bus->mii_bus);
155 smi_en.u64 = 0;
156 cvmx_write_csr(CVMX_SMIX_EN(bus->unit), smi_en.u64);
147 return 0; 157 return 0;
148} 158}
149 159
diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c
index 68dd107bad24..0692f750c404 100644
--- a/drivers/net/phy/micrel.c
+++ b/drivers/net/phy/micrel.c
@@ -32,6 +32,7 @@ static int kszphy_config_init(struct phy_device *phydev)
32 32
33static struct phy_driver ks8001_driver = { 33static struct phy_driver ks8001_driver = {
34 .phy_id = PHY_ID_KS8001, 34 .phy_id = PHY_ID_KS8001,
35 .name = "Micrel KS8001",
35 .phy_id_mask = 0x00fffff0, 36 .phy_id_mask = 0x00fffff0,
36 .features = PHY_BASIC_FEATURES, 37 .features = PHY_BASIC_FEATURES,
37 .flags = PHY_POLL, 38 .flags = PHY_POLL,
diff --git a/drivers/net/veth.c b/drivers/net/veth.c
index f9f0730b53d5..5ec542dd5b50 100644
--- a/drivers/net/veth.c
+++ b/drivers/net/veth.c
@@ -187,7 +187,6 @@ tx_drop:
187 return NETDEV_TX_OK; 187 return NETDEV_TX_OK;
188 188
189rx_drop: 189rx_drop:
190 kfree_skb(skb);
191 rcv_stats->rx_dropped++; 190 rcv_stats->rx_dropped++;
192 return NETDEV_TX_OK; 191 return NETDEV_TX_OK;
193} 192}
diff --git a/drivers/net/wireless/ath/ar9170/usb.c b/drivers/net/wireless/ath/ar9170/usb.c
index c8121a6a9d3a..8663660ea4c6 100644
--- a/drivers/net/wireless/ath/ar9170/usb.c
+++ b/drivers/net/wireless/ath/ar9170/usb.c
@@ -738,12 +738,16 @@ static void ar9170_usb_firmware_failed(struct ar9170_usb *aru)
738{ 738{
739 struct device *parent = aru->udev->dev.parent; 739 struct device *parent = aru->udev->dev.parent;
740 740
741 complete(&aru->firmware_loading_complete);
742
741 /* unbind anything failed */ 743 /* unbind anything failed */
742 if (parent) 744 if (parent)
743 device_lock(parent); 745 device_lock(parent);
744 device_release_driver(&aru->udev->dev); 746 device_release_driver(&aru->udev->dev);
745 if (parent) 747 if (parent)
746 device_unlock(parent); 748 device_unlock(parent);
749
750 usb_put_dev(aru->udev);
747} 751}
748 752
749static void ar9170_usb_firmware_finish(const struct firmware *fw, void *context) 753static void ar9170_usb_firmware_finish(const struct firmware *fw, void *context)
@@ -772,6 +776,8 @@ static void ar9170_usb_firmware_finish(const struct firmware *fw, void *context)
772 if (err) 776 if (err)
773 goto err_unrx; 777 goto err_unrx;
774 778
779 complete(&aru->firmware_loading_complete);
780 usb_put_dev(aru->udev);
775 return; 781 return;
776 782
777 err_unrx: 783 err_unrx:
@@ -869,6 +875,7 @@ static int ar9170_usb_probe(struct usb_interface *intf,
869 init_usb_anchor(&aru->tx_pending); 875 init_usb_anchor(&aru->tx_pending);
870 init_usb_anchor(&aru->tx_submitted); 876 init_usb_anchor(&aru->tx_submitted);
871 init_completion(&aru->cmd_wait); 877 init_completion(&aru->cmd_wait);
878 init_completion(&aru->firmware_loading_complete);
872 spin_lock_init(&aru->tx_urb_lock); 879 spin_lock_init(&aru->tx_urb_lock);
873 880
874 aru->tx_pending_urbs = 0; 881 aru->tx_pending_urbs = 0;
@@ -888,6 +895,7 @@ static int ar9170_usb_probe(struct usb_interface *intf,
888 if (err) 895 if (err)
889 goto err_freehw; 896 goto err_freehw;
890 897
898 usb_get_dev(aru->udev);
891 return request_firmware_nowait(THIS_MODULE, 1, "ar9170.fw", 899 return request_firmware_nowait(THIS_MODULE, 1, "ar9170.fw",
892 &aru->udev->dev, GFP_KERNEL, aru, 900 &aru->udev->dev, GFP_KERNEL, aru,
893 ar9170_usb_firmware_step2); 901 ar9170_usb_firmware_step2);
@@ -907,6 +915,9 @@ static void ar9170_usb_disconnect(struct usb_interface *intf)
907 return; 915 return;
908 916
909 aru->common.state = AR9170_IDLE; 917 aru->common.state = AR9170_IDLE;
918
919 wait_for_completion(&aru->firmware_loading_complete);
920
910 ar9170_unregister(&aru->common); 921 ar9170_unregister(&aru->common);
911 ar9170_usb_cancel_urbs(aru); 922 ar9170_usb_cancel_urbs(aru);
912 923
diff --git a/drivers/net/wireless/ath/ar9170/usb.h b/drivers/net/wireless/ath/ar9170/usb.h
index a2ce3b169ceb..919b06046eb3 100644
--- a/drivers/net/wireless/ath/ar9170/usb.h
+++ b/drivers/net/wireless/ath/ar9170/usb.h
@@ -71,6 +71,7 @@ struct ar9170_usb {
71 unsigned int tx_pending_urbs; 71 unsigned int tx_pending_urbs;
72 72
73 struct completion cmd_wait; 73 struct completion cmd_wait;
74 struct completion firmware_loading_complete;
74 int readlen; 75 int readlen;
75 u8 *readbuf; 76 u8 *readbuf;
76 77