aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net (follow)
AgeCommit message (Collapse)AuthorFilesLines
2010-12-08Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6David S. Miller49-378/+632
Conflicts: drivers/net/wireless/ath/ath9k/ar9003_eeprom.c net/llc/af_llc.c
2010-12-08ehea: Fixing LRO configurationBreno Leitao2-2/+14
In order to set LRO on ehea, the user must set a module parameter, which is not the standard way to do so. This patch adds a way to set LRO using the ethtool tool. Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08driver/net/benet: fix be_cmd_multicast_set() memcpy bugJoe Jin1-1/+1
Regarding benet be_cmd_multicast_set() function, now using netdev_for_each_mc_addr() helper for mac address copy, but when copying to req->mac[] did not increase of the index. Cc: Sathya Perla <sathyap@serverengines.com> Cc: Subbu Seetharaman <subbus@serverengines.com> Cc: Sarveshwar Bandi <sarveshwarb@serverengines.com> Cc: Ajit Khaparde <ajitk@serverengines.com> Signed-off-by: Joe Jin <joe.jin@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08Merge branch 'sfc-2.6.37' of git://git.kernel.org/pub/scm/linux/kernel/git/bwh/sfc-2.6David S. Miller3-14/+37
2010-12-08via-rhine: hardware VLAN supportRoger Luethi1-14/+312
This patch adds VLAN hardware support for Rhine chips. The driver uses up to 3 additional bytes of buffer space when extracting 802.1Q headers; PKT_BUF_SZ should still be sufficient. The initial code was provided by David Lv. I reworked it to use standard kernel facilities. Coding style clean up mostly follows via-velocity. Adapted to new interface for VLAN acceleration (per request of Jesse Gross). Signed-off-by: David Lv <DavidLv@viatech.com.cn> Signed-off-by: Roger Luethi <rl@hellgate.ch> drivers/net/via-rhine.c | 326 +++++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 312 insertions(+), 14 deletions(-) Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08ifb: goto resched directly if error happens and dp->tq isn't emptyChangli Gao1-0/+2
If we break the loop when there are still skbs in tq and no skb in rq, the skbs will be left in txq until new skbs are enqueued into rq. In rare cases, no new skb is queued, then these skbs will stay in rq forever. After this patch, if tq isn't empty when we break the loop, we goto resched directly. Signed-off-by: Changli Gao <xiaosuo@gmail.com> Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08cxgb4: fix MAC address hash filterDimitris Michailidis1-1/+1
Fix the calculation of the inexact hash-based MAC address filter. It's 64 bits but current code is missing a ULL. Results in filtering out some legitimate packets. Signed-off-by: Dimitris Michailidis <dm@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08can: add slcan driver for serial/USB-serial CAN adaptersOliver Hartkopp3-0/+777
This patch adds support for serial/USB-serial CAN adapters implementing the LAWICEL ASCII protocol for CAN frame transport over serial lines. The driver implements the SLCAN line discipline and is heavily based on the slip.c driver. Therefore the code style remains similar to slip.c to be able to apply changes of the SLIP driver to the SLCAN driver easily. For more details see the slcan Kconfig entry. Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08CAIF: Fix U5500 compile error for shared memory driverKim Lilliestierna XX2-2/+2
Rearrange pr_fmt so it compiles. Signed-off-by: Sjur Braendeland <sjur.brandeland@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-08Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6David S. Miller19-90/+107
2010-12-07sfc: Fix NAPI list corruption during ring reallocationBen Hutchings1-12/+19
Call netif_napi_{add,del}() on the NAPI contexts in the new and old channels, respectively. Since efx_init_napi() cannot fail, make its return type void. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-07sfc: Fix crash in legacy onterrupt handler during ring reallocationBen Hutchings3-2/+18
If we are using a legacy interrupt, our IRQ may be shared and our interrupt handler may be called even though interrupts are disabled on the NIC. When we change ring sizes, we reallocate the event queue and the interrupt handler may use an invalid pointer when called for another device's interrupt. Maintain a legacy_irq_enabled flag and test that at the top of the interrupt handler. Note that this problem results from the need to work around broken INT_ISR0 reads, and does not affect the legacy interrupt handler for Falcon A1. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-07sfc: Generalise filter spec initialisationBen Hutchings3-191/+248
Move search_depth arrays into per-table state. Define initialisation function efx_filter_init_rx() which sets everything apart from the match fields. Define efx_filter_set_{ipv4_local,ipv4_full,eth_local}() to set the match fields. This allows some simplification of callers and later support for additional protocols and more flexible matching using multiple calls to these functions. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-07sfc: Remove filter table IDs from filter functionsBen Hutchings4-25/+34
The separation between filter tables is largely an internal detail and it may be removed in future hardware. To prepare for that: - Merge table ID with filter index to make an opaque filter ID - Wrap efx_filter_table_clear() with a function that clears filters from both RX tables, which is all that the current caller requires Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-07sfc: Log start and end of ethtool self-test at INFO levelBen Hutchings1-3/+6
Add message at start of self-test and increase log level of message at end of self-test, so that any other messages produced during the test are clearly associated with it. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06Revert "ehea: Use the standard logging functions"David S. Miller5-274/+293
This reverts commit 539995d18649023199986424d140f1d620372ce5. As reported by Stephen Rothwell, this breaks the build. Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06sfc: Use TX push whenever adding descriptors to an empty queueBen Hutchings3-2/+68
Whenever we add DMA descriptors to a TX ring and update the ring pointer, the TX DMA engine must first read the new DMA descriptors and then start reading packet data. However, all released Solarflare 10G controllers have a 'TX push' feature that allows us to reduce latency by writing the first new DMA descriptor along with the pointer update. This is only useful when the queue is empty. The hardware should ignore the pushed descriptor if the queue is not empty, but this check is buggy, so we must do it in software. In order to tell whether a TX queue is empty, we need to compare the previous transmission count (write_count) and completion count (read_count). However, if we do that every time we update the ring pointer then read_count may ping-pong between the caches of two CPUs running the transmission and completion paths for the queue. Therefore, we split the check for an empty queue between the completion path and the transmission path: - Add an empty_read_count field representing a point at which the completion path saw the TX queue as empty. - Add an old_write_count field for use on the completion path. - On the completion path, whenever read_count reaches or passes old_write_count the TX queue may be empty. We then read write_count, set empty_read_count if read_count == write_count, and update old_write_count. - On the transmission path, we read empty_read_count. If it's set, we compare it with the value of write_count before the current set of descriptors was added. If they match, the queue really is empty and we can use TX push. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06sfc: Remove locking from implementation of efx_writeo_paged()Ben Hutchings1-1/+14
It is not necessary to serialise writes to the paged 128-bit registers. However, if we don't then we must always write the last dword separately, not as part of a qword write. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06sfc: Add compile-time checks for correctness of paged register writesBen Hutchings1-8/+23
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06sfc: Remove redundant memory barriers between MMIOsBen Hutchings1-5/+0
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06sfc: Expand/correct comments on collector behaviour and function usageBen Hutchings1-49/+49
Document exactly which registers and functions have special behaviour, and why races on writes to descriptor pointers are safe. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06sfc: Use ACCESS_ONCE when copying efx_tx_queue::read_countBen Hutchings1-3/+2
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06sfc: Reorder struct efx_nic to separate fields by volatilityBen Hutchings1-18/+23
Place the regularly updated fields (locks, MAC stats, etc.) on a separate cache-line from fields which are mostly constant. This should reduce cache misses for access to the latter on the data path. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
2010-12-06net: cris/eth_v10: Use net_device_stats from struct net_device_statsTobias Klauser1-19/+15
struct net_device has its own struct net_device_stats member, so use this one instead of a private copy in struct net_local. Note: This patch was not even compile tested. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06net: emaclite: Omit private ndo_get_stats functionTobias Klauser1-16/+0
xemaclite_get_stats() just returns dev->stats so we can leave it out alltogether and let dev_get_stats() do the job. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06net: am79c961a: Omit private ndo_get_stats functionTobias Klauser1-9/+0
am79c961_getstats() just returns dev->stats so we can leave it out alltogether and let dev_get_stats() do the job. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06ixgbe: fix enum type mismatch on disable laserDon Skidmore1-3/+3
Fixes a recent bug on the patch (c6ecf39a10ceec3e97096e2a8d3eadcecd593422) that disabled the laser on ifconfig down. Compilers were seeing a enum mismatch. 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>
2010-12-06ixgbe: fix for link failure on SFP+ DA cablesDon Skidmore2-3/+28
This patch helps prevent FW/SW semaphore collision from leading to link establishment failure. The collision might mess up the PHY registers so we reset the PHY. However there are SFI/KR areas in the PHY that are not reset with a Reset_AN so we need to change LMS to reset it. Also wait until AN state machine is AN_GOOD Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06ixgbe: fix possible NULL pointer deference in shutdown pathDon Skidmore1-0/+3
After freeing the rings we were not zeroing out the ring count values. This patch now clears these counts correctly. Reported-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06be2net: Handle out of buffer completions for lancerSathya Perla2-21/+38
If Lancer chip does not have posted RX buffers, it posts an RX completion entry with the same frag_index as the last valid completion. The Error bit is also set. In BE, a flush completion is indicated with a zero value for num_rcvd in the completion. Such completions don't carry any data and are not processed. This patch refactors code to handle both cases with the same code. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06be2net: FW init cmd fix for lancerSathya Perla1-19/+8
Lancer can use the same pattern as BE to indicate a driver load to the FW. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06be2net: Fix be_dev_family_check() return value checkSathya Perla1-1/+1
Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06ehea: Use the standard logging functionsJoe Perches5-293/+274
Remove ehea_error, ehea_info and ehea_debug macros. Use pr_fmt, pr_<level>, netdev_<level> and netif_<level> as appropriate. Fix messages to use trailing "\n", some messages had an extra one as the old ehea_<level> macros added a trailing "\n". Coalesced long format strings. Uncompiled/untested. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Breno Leitao<leitao@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06net: Fix too optimistic NETIF_F_HW_CSUM featuresMichał Mirosław10-48/+27
NETIF_F_HW_CSUM is a superset of NETIF_F_IP_CSUM+NETIF_F_IPV6_CSUM, but some drivers miss the difference. Fix this and also fix UFO dependency on checksumming offload as it makes the same mistake in assumptions. Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl> Acked-by: Jon Mason <jon.mason@exar.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06USB CDC NCM host driverAlexey Orishko3-0/+1233
The patch provides USB CDC NCM host driver support in the Linux Kernel. Changes: drivers/net/usb/cdc_ncm.c: - initial submission of the CDC NCM host driver; - verified on Intel 32/64 bit, Intel Atom, ST-Ericsson U8500 (ARM) - throughput measured over 100 Mbits duplex; - driver supports 16-bit NTB format only, but it is more than enough for transfers up to 64K; - driver can handle up to 32 datagrams in received NTB; - timer is used to collect several packets in Tx direction drivers/net/usb/Kconfig: - a new entry to compile CDC NCM host driver drivers/net/usb/Makefile: - a new entry to compile CDC NCM host driver Signed-off-by: Alexey Orishko <alexey.orishko@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06usbnet: changes for upcoming cdc_ncm driverAlexey Orishko1-14/+31
Changes: include/linux/usb/usbnet.h: - a new flag to indicate driver's capability to accumulate IP packets in Tx direction and extract several packets from single skb in Rx direction. drivers/net/usb/usbnet.c: - the procedure of counting packets in usbnet was updated due to the accumulating of IP packets in the driver - no short packets are sent if indicated by the flag in driver_info structure Signed-off-by: Alexey Orishko <alexey.orishko@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davemJohn W. Linville77-3624/+4710
2010-12-06tg3: Update version to 3.116Matt Carlson1-2/+2
This patch updates the tg3 version to 3.116. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06tg3: Relax EEE thresholdsMatt Carlson2-12/+33
The hardware defaults to fairly aggressive EEE thresholds. While there appear to be no ill effects, this patch relaxes them, just as a precaution. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06tg3: Minor EEE code tweaksMatt Carlson1-7/+10
The first hunk of this patch makes sure that the driver checks for the appropriate preconditions before checking if EEE negotiation succeeded. More specifically the link needs to be full duplex for EEE to be enabled. The second and third hunks of this patch fix a bug where the eee advertisement register would be programmed with extra bits set. The fourth hunk of this patch makes sure the EEE capability flag is not set for 5718 A0 devices and that the device is not a serdes device. None of these modifications are strictly necessary. The driver / hardware still does the right thing. They are submitted primarily for correctness. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06tg3: Fix 57765 EEE supportMatt Carlson1-16/+16
EEE support in the 57765 internal phy will not enable after a phy reset unless it sees that EEE is supported in the MAC. This patch moves the code that programs the CPMU EEE registers to a place before the phy reset. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06tg3: Move EEE definitions into mdio.hMatt Carlson2-11/+8
In commit 52b02d04c801fff51ca49ad033210846d1713253 entitled "tg3: Add EEE support", Ben Hutchings had commented that the EEE advertisement register will be in a standard location. This patch moves that definition into mdio.h and changes the code to use it. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-06tg3: Raise the jumbo frame BD flag thresholdMatt Carlson1-2/+2
The current transmit routines set the jumbo frame BD flag too aggressively. This can reduce performance for common cases. This patch raises the jumbo flag threshold to 1518, up from 1500. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03ixgbe: add support for new format of PBA numbersDon Skidmore4-16/+105
The new PBA format is stored as a string. This patch allows the driver to support both the old and new format. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03ixgbe: add support for 82599 FCoE SKUDon Skidmore3-0/+8
Add both NIC and backplane support for FCoE enabled devices IDs. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03ixgbe: add WOL support for SFP+ subdeviceDon Skidmore3-5/+22
This patch will add wake on LAN support to the dev/sub_dev 10FB 11A9. This will also include ixgbe ethtool support for this device. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03ixgbe: fix link behavior for SFP+ when driver is brought downDon Skidmore2-11/+27
We have had several requests to have ifconfig down command disable the SFP+ laser and thus make link go down. Likewise on ifconfig up the laser would be enabled and link would come up. This patch enables that behavior. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03qlcnic: Updated driver version to 5.0.13Anirban Chakraborty1-2/+2
Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03qlcnic: LICENSE file for qlcnicSritej Velaga7-140/+21
Signed-off-by: Sritej Velaga <sritej.velaga@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-12-03qlcnic: validate eswitch config values for PFAmit Kumar Salecha1-3/+6
Currently driver set default eswitch configuration values for PF function, instead of validating values sent by application. Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>