aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
Commit message (Collapse)AuthorAge
* mac80211: clean up beacon interval settingsJohannes Berg2009-05-06
| | | | | | | | | | | | | | | | | | | | We currently have two beacon interval configuration knobs: hw.conf.beacon_int and vif.bss_info.beacon_int. This is rather confusing, even though the former is used when we beacon ourselves and the latter when we are associated to an AP. This just deprecates the hw.conf.beacon_int setting in favour of always using vif.bss_info.beacon_int. Since it touches all the beaconing IBSS code anyway, we can also add support for the cfg80211 IBSS beacon interval configuration easily. NOTE: The hw.conf.beacon_int setting is retained for now due to drivers still using it -- I couldn't untangle all drivers, some are updated in this patch. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* net: remove driver_data direct access of struct device from more driversGreg Kroah-Hartman2009-05-05
| | | | | | | | | | | In the near future, the driver core is going to not allow direct access to the driver_data pointer in struct device. Instead, the functions dev_get_drvdata() and dev_set_drvdata() should be used. These functions have been around since the beginning, so are backwards compatible with all older kernel versions. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* macb: Add support of the netpoll APIThomas Petazzoni2009-05-04
| | | | | | | | | | | | | With this patch in place, I'm successfully able to use the netconsole mechanism with the Calao USB-A9263 board, which uses the AT91SAM9263 CPU, which in terms of Ethernet controller is supported by the macb driver. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> [haavard.skinnemoen@atmel.com: disable_irq() -> local_irq_save()] [haavard.skinnemoen@atmel.com: convert to net_device_ops] Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* ne2k-pci: use dev->addr_len instead of "6"Jiri Pirko2009-05-03
| | | | | | | | | | | | Spotted a tiny ugliness in a recently posted patch. This patch cuts it out. Jirka Signed-off-by: Jiri Pirko <jpirko@redhat.com> drivers/net/ne2k-pci.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Signed-off-by: David S. Miller <davem@davemloft.net>
* Merge branch 'master' of ↵David S. Miller2009-05-03
|\ | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
| * ne2k-pci: Do not register device until initialized.Lubomir Rintel2009-05-02
| | | | | | | | | | | | | | | | | | Doing it in reverse order causes uevent to be sent before we have a MAC address, which confuses udev. Signed-off-by: Lubomir Rintel <lkundrak@v3.sk> Acked-by: Jeff Garzik <jgarzik@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | Merge branch 'master' of ↵David S. Miller2009-05-03
|\| | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
| * virtio_net: Fix function name typoAlex Williamson2009-05-02
| | | | | | | | | | Signed-off-by: Alex Williamson <alex.williamson@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * virtio_net: Cleanup command queue scatterlist usageAlex Williamson2009-05-02
| | | | | | | | | | | | | | | | | | | | We were avoiding calling sg_init* on scatterlists passed into virtnet_send_command to prevent extraneous end markers. This caused build warnings for uninitialized variables. Cleanup the code to create proper scatterlists. Signed-off-by: Alex Williamson <alex.williamson@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * bonding: correct the cleanup in bond_create()Jiri Pirko2009-05-01
| | | | | | | | | | | | | | | | This patch makes the cleanup in bond_create nicer :) Also now the forgotten free_netdev is called. Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * smsc95xx: add support for LAN9512 and LAN9514Steve Glendinning2009-05-01
| | | | | | | | | | | | | | | | | | | | | | | | LAN9512 and LAN9514 are USB hubs with an integrated 10/100 ethernet controller. Logically this looks like an ethernet controller (similar to LAN9500) permanently attached to one of the hub's downstream ports. This patch adds the usb device id of the new ethernet controller to the smsc95xx driver. This id is the same in both new devices. Signed-off-by: Steve Glendinning <steve.glendinning@smsc.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * smsc95xx: configure LED outputsSteve Glendinning2009-05-01
| | | | | | | | | | | | | | | | | | | | | | | | SMSC LAN9500 has dual purpose GPIO/LED pins, and by default at power-on these are configured as GPIOs. This means that if LEDs are fitted they won't ever light. This patch sets them to be LED outputs for speed, duplex and link/activity. Signed-off-by: Steve Glendinning <steve.glendinning@smsc.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * netconsole: take care of NETDEV_UNREGISTER eventBruno Prémont2009-05-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When netconsole is loaded and a network interface fades away (e.g. on rmmod $interface_driver_module) the rmmod remains stuck and some locks are taken that prevent any additional module loading/unloading as well as interface up/down changes. In addition kernel logs (and console) get flooded at 10s interval with [ 122.464065] unregister_netdevice: waiting for eth0 to become free. Usage count = 1 [ 132.704059] unregister_netdevice: waiting for eth0 to become free. Usage count = 1 This patch lets netconsole take NETDEV_UNREGISTER event into account and release the affected interface if it was in use. Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org> Acked-by: Matt Mackall <mpm@selenic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * bonding: bond_slave_info_query() fixEric Dumazet2009-05-01
| | | | | | | | | | | | | | | | | | bond_slave_info_query() should keep a read lock while accessing slave info, or risk accessing stale data and corruption. Signed-off-by: Eric Dumazet <dada1@cosmosbay.com> Signed-off-by: Jay Vosburgh <fubar@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * cxgb3: fixing gcc 4.4 compiler warning: suggest parentheses around operand ↵Sergey Senozhatsky2009-05-01
| | | | | | | | | | | | | | | | | | | | | | of ‘!’ Trivial: fixing gcc 4.4 compiler warning: drivers/net/cxgb3/t3_hw.c: In function ‘t3_prep_adapter’: drivers/net/cxgb3/t3_hw.c:3782: warning: suggest parentheses around operand of ‘!’ or change ‘|’ to ‘||’ or ‘!’ to ‘~’ Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@mail.by> Signed-off-by: David S. Miller <davem@davemloft.net>
* | 3c589_cs: add cis(firmware) of 3Com multifunction pcmcia cardKen Kawasaki2009-05-01
| | | | | | | | | | | | | | | | | | | | 3c589_cs,3c574_cs,serial_cs: (1)add cis(firmware) of 3Com lan&modem mulitifunction pcmcia card. (2)load correct configuration register for 3Com card Signed-off-by: Ken Kawasaki <ken_kawasaki@spring.nifty.jp> Signed-off-by: David S. Miller <davem@davemloft.net>
* | forcedeth: add clock gating feature <resend>Ayaz Abdulla2009-05-01
| | | | | | | | | | | | | | | | | | | | | | | | This patch adds new logic to support a clock gating feature found on the latest set of chipsets. The clock gating is performed on the tx/rx engines when the link is disconnected. Clock gating helps in reducing power consumption. * modified based on comments from netdev Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | net: remove driver_data direct access of struct deviceGreg Kroah-Hartman2009-05-01
| | | | | | | | | | | | | | | | | | | | | | | | In the near future, the driver core is going to not allow direct access to the driver_data pointer in struct device. Instead, the functions dev_get_drvdata() and dev_set_drvdata() should be used. These functions have been around since the beginning, so are backwards compatible with all older kernel versions. Cc: netdev@vger.kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
* | Merge branch 'master' of ↵David S. Miller2009-04-29
|\| | | | | | | | | | | | | | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 Conflicts: Documentation/isdn/00-INDEX drivers/net/wireless/iwlwifi/iwl-scan.c drivers/net/wireless/rndis_wlan.c net/mac80211/main.c
| * mv643xx_eth: 64bit mib counter read fixLennert Buytenhek2009-04-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On several mv643xx_eth hardware versions, the two 64bit mib counters for 'good octets received' and 'good octets sent' are actually 32bit counters, and reading from the upper half of the register has the same effect as reading from the lower half of the register: an atomic read-and-clear of the entire 32bit counter value. This can under heavy traffic occasionally lead to small numbers being added to the upper half of the 64bit mib counter even though no 32bit wrap has occured. Since we poll the mib counters at least every 30 seconds anyway, we might as well just skip the reads of the upper halves of the hardware counters without breaking the stats, which this patch does. Signed-off-by: Lennert Buytenhek <buytenh@marvell.com> Cc: stable@kernel.org Signed-off-by: David S. Miller <davem@davemloft.net>
| * mv643xx_eth: OOM handling fixesLennert Buytenhek2009-04-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, when OOM occurs during rx ring refill, mv643xx_eth will get into an infinite loop, due to the refill function setting the OOM bit but not clearing the 'rx refill needed' bit for this queue, while the calling function (the NAPI poll handler) will call the refill function in a loop until the 'rx refill needed' bit goes off, without checking the OOM bit. This patch fixes this by checking the OOM bit in the NAPI poll handler before attempting to do rx refill. This means that once OOM occurs, we won't try to do any memory allocations again until the next invocation of the poll handler. While we're at it, change the OOM flag to be a single bit instead of one bit per receive queue since OOM is a system state rather than a per-queue state, and cancel the OOM timer on entry to the NAPI poll handler if it's running to prevent it from firing when we've already come out of OOM. Signed-off-by: Lennert Buytenhek <buytenh@marvell.com> Cc: stable@kernel.org Signed-off-by: David S. Miller <davem@davemloft.net>
| * Merge branch 'master' of ↵David S. Miller2009-04-29
| |\ | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
| | * ath5k: fix buffer overrun in rate debug codeBob Copeland2009-04-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | char bname[5] is too small for the string "X GHz" when the null terminator is taken into account. Thus, turning on rate debugging can crash unless we have lucky stack alignment. Cc: stable@kernel.org Reported-by: Paride Legovini <legovini@spiro.fisica.unipd.it> Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
| | * iwlwifi: notify on scan completion even when shutting downJohannes Berg2009-04-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Under certain circumstances iwlwifi can get stuck and will no longer accept scan requests, because the core code (cfg80211) thinks that it's still processing one. This fixes one of the points where it can happen, but I've still seen it (although only with my radio-off-when-idle patch). Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
| | * rndis_wlan: fix initialization order for workqueue&workersJussi Kivilinna2009-04-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | rndis_wext_link_change() might be called from rndis_command() at initialization stage and priv->workqueue/priv->work have not been initialized yet. This causes invalid opcode at rndis_wext_bind on some brands of bcm4320. Fix by initializing workqueue/workers in rndis_wext_bind() before rndis_command is used. This bug has existed since 2.6.25, reported at: http://bugzilla.kernel.org/show_bug.cgi?id=12794 Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
| | * wireless: remove unneeded EXPORT_SYMBOL the tickles a powerpc compiler bugStephen Rothwell2009-04-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | drivers/net/wireless/iwlwifi/iwl3945-base.c:1415: error: __ksymtab_iwl3945_rx_queue_reset causes a section type conflict I am pretty sure that this is a compiler bug, so not to worry. However, as far as I can see, iwl-3945.o (the only user) and iwl3945-base.o are always linked into the same module, so the EXPORT_SYMBOL (which causes the problem) should not be needed. Correct? Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: John W. Linville <linville@tuxdriver.com>
| * | e100: do not go D3 in shutdown unless system is powering offThadeu Lima de Souza Cascardo2009-04-29
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After experimenting with kexec with the last merges after 2.6.29, I've had some problems when probing e100. It would not read the eeprom. After some bisects, I realized this has been like that since forever (at least 2.6.18). The problem is that shutdown is doing the same thing that suspend does and puts the device in D3 state. I couldn't find a way to get the device back to a sane state in the probe function. So, based on some similar patches from Rafael J. Wysocki for e1000, e1000e, and ixgbe, I wrote this one for e100. Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> Acked-by: "Rafael J. Wysocki" <rjw@sisk.pl> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * ixgbe: Fix WoL functionality for 82599 KX4 devicesWaskiewicz Jr, Peter P2009-04-27
| | | | | | | | | | | | | | | | | | | | | | | | | | The current code writes the PME enabled bit in PCI config space which is wrong. This was needed for pre-release hardware, and was not removed from the driver. Also, we need to clear the WUS (wake up status) after we resume. Otherwise we can't wake for the same event again since it's still asserted in the hardware. Plus, the multicast lists were being written improperly, causing multicast WoL to fail. Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * veth: prevent oops caused by netdev destructorStephen Hemminger2009-04-27
| | | | | | | | | | | | | | | | | | | | | | | | | | From: Stephen Hemminger <shemminger@vyatta.com> The veth driver will oops if sysfs hooks are open while module is removed. The net device destructor can not point to code in a module; basically there are only two possible safe values: NULL - no destructor, or free_netdev - free on last use Signed-off-by: David S. Miller <davem@davemloft.net>
| * forcedeth: tx timeout fixAyaz Abdulla2009-04-27
| | | | | | | | | | | | | | | | | | This patch fixes the tx_timeout() to properly handle the clean up of the tx ring. It also sets the tx put pointer back to the correct position to be in sync with HW. Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com> Signed-off-by: David S. Miller <davem@davemloft.net>
| * mlx4_en: Handle page allocation failure during receiveYevgeny Petrilin2009-04-27
| | | | | | | | | | | | | | | | If we failed to allocate new fragments for receive buffer, the packet should be dropped and packets should be reused. Signed-off-by: Yevgeny Petrilin <yevgenyp@mellanox.co.il> Signed-off-by: David S. Miller <davem@davemloft.net>
| * mlx4_en: Fix cleanup flow on cq activationYevgeny Petrilin2009-04-27
| | | | | | | | | | | | | | | | In case of mlx4_en_activate_cq() failure, the cleanup code would go to rx_err and try to disable unactivated rings. Signed-off-by: Yevgeny Petrilin <yevgenyp@mellanox.co.il> Signed-off-by: David S. Miller <davem@davemloft.net>
* | Revert "vxge: use max() instead of VXGE_HW_SET_LEVEL"David S. Miller2009-04-29
| | | | | | | | | | | | | | | | | | This reverts commit 011983048a120e520147361be1067dd82343038e. Causes warnings in the build as reported by Stephen Rothwell. So this change is worse than what it's curing. Signed-off-by: David S. Miller <davem@davemloft.net>
* | mii: Rewrite mii_ethtool_gset() to report mdio_support and lp_advertisingBen Hutchings2009-04-29
| | | | | | | | | | | | | | | | | | Ignore link partner advertising flags while AN is not complete. Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | ethtool/mdio: Support backplane mode negotiationBen Hutchings2009-04-29
| | | | | | | | | | | | | | Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | ethtool/mdio: Report MDIO mode support and link partner advertisingBen Hutchings2009-04-29
| | | | | | | | | | | | | | | | Add mdio_support and lp_advertising fields to ethtool_cmd. Set these in mdio45_ethtool_gset{,_npage}(). Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | sfc: Use generic MDIO flow control auto-negotiation functionsBen Hutchings2009-04-29
| | | | | | | | | | Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | mdio: Add mdio45_ethtool_spauseparam_an()Ben Hutchings2009-04-29
| | | | | | | | | | | | | | | | This implements the ETHTOOL_SPAUSEPARAM operation for MDIO (clause 45) PHYs with auto-negotiation MMDs. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | s2io: Use generic MDIO definitionsBen Hutchings2009-04-29
| | | | | | | | | | | | | | Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | ixgb: Use generic MDIO definitionsBen Hutchings2009-04-29
| | | | | | | | | | | | | | Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | ixgbe: Use generic MDIO definitions and functionsBen Hutchings2009-04-29
| | | | | | | | | | | | | | Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | cxgb3: Use generic MDIO definitions and mdio_mii_ioctl()Ben Hutchings2009-04-29
| | | | | | | | | | | | | | Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | chelsio: Use generic MDIO definitions and mdio_mii_ioctl()Ben Hutchings2009-04-29
| | | | | | | | | | | | | | Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | sfc: Use generic MDIO functions and definitionsBen Hutchings2009-04-29
| | | | | | | | | | | | | | | | | | | | | | Make use of the newly-added generic MDIO clause 45 support and remove redundant definitions. Add an 'efx_' prefix to the remaining driver-specific MDIO functions and remove arguments which are redundant with efx->mdio.prtad. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | mdio: Add generic MDIO (clause 45) support functionsBen Hutchings2009-04-29
| | | | | | | | | | | | | | | | These roughly mirror many of the MII library functions and are based on code from the sfc driver. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | pcnet32: Remove pointless memory barriersJohn Dykstra2009-04-29
| | | | | | | | | | | | | | | | | | | | | | These two memory barriers in performance-critical paths are not needed on x86. Even if some other architecture does buffer PCI I/O space writes, the existing memory-mapped I/O barriers are unlikely to be what is needed. Signed-off-by: John Dykstra <john.dykstra1@gmail.com> Acked-by: Don Fry <pcnet32@verizon.net> Signed-off-by: David S. Miller <davem@davemloft.net>
* | ixgbe: Use pci_wake_from_d3() instead of multiple pci_enable_wake()Don Skidmore2009-04-29
| | | | | | | | | | | | | | | | | | | | We were calling pci_enable_wake() twice in a row for both D3_hot and D3_cold. This replaces those calls with a call to pci_wake_from_d3() to avoid issues with PCI PM vs ordering constraints. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | netxen: fix firmware downloadDhananjay Phadke2009-04-29
| | | | | | | | | | | | | | | | | | | | o hold the firmware in memory across suspend, since filesystem may not be up after resuming. o reset the chip after requesting firmware, to minimize downtime for NC-SI. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | netxen: refactor netxen_recv_context structDhananjay Phadke2009-04-29
| | | | | | | | | | | | | | | | o move related fields into netxen_recv_context struct. o allocate rx buffer and descriptor rings dynamically. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | netxen: fix link event handlingDhananjay Phadke2009-04-29
| | | | | | | | | | | | | | | | Firmware starting 4.0.402 started supporting link events, disable it for older firmwares. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: David S. Miller <davem@davemloft.net>