aboutsummaryrefslogtreecommitdiffstats
path: root/drivers (follow)
AgeCommit message (Collapse)AuthorFilesLines
2011-11-26airo: Fix array bounds warning when moving packet payload.David S. Miller1-2/+2
drivers/net/wireless/airo.c: In function ‘encapsulate’: drivers/net/wireless/airo.c:1421:15: warning: array subscript is above array bounds [-Warray-bounds] drivers/net/wireless/airo.c: In function ‘decapsulate’: drivers/net/wireless/airo.c:1509:16: warning: array subscript is above array bounds [-Warray-bounds] Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26KSZ8851-SNL: Add ethtool support for EEPROM via eeprom_93cx6Ben Dooks3-320/+120
Add ethtool EEPROM read/write support using the eeprom_93cx6 library instead of open-coding the functions. Depends on eeprom_93cx6 driver getting EEPROM write support. Signed-off-by: Ben Dooks <ben@simtec.co.uk> Signed-off-by: Simtec Linux Team <linux@simtec.co.uk> [sboyd@codeaurora.org: Removed previous eeprom implementation] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26KSZ8851-SNL: Fix MAC address change problemTristram Ha2-21/+28
When device is off it is under power saving mode. Changing the MAC address in that situation will result in the device not communicating as the first write to the MAC address register is not executed. Signed-off-by: Tristram Ha <Tristram.Ha@micrel.com> [ben@simtec.co.uk: cleaned up header] Signed-off-by: Ben Dooks <ben@simtec.co.uk> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26KSZ8851-SNL: Add support for EEPROM MAC addressBen Dooks1-7/+34
Add support for reading the MAC address from the system registers if there is an EEPROM present. This involves caching the KS_CCR register for later use (will also be useful for ETHTOOL support) and adding a print to say that there is an EEPROM present. Signed-off-by: Ben Dooks <ben@simtec.co.uk> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26eeprom_93cx6: Add write supportBen Dooks1-0/+85
Add support for writing data to EEPROM. Signed-off-by: Ben Dooks <ben@simtec.co.uk> Cc: Wolfram Sang <w.sang@pengutronix.de> Cc: Jean Delvare <khali@linux-fr.org> Cc: Linux Kernel <linux-kernel@vger.kernel.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26eeprom_93cx6: Add data direction control.Ben Dooks1-0/+3
Some devices need to know if the data is to be output or read, so add a data direction into the eeprom structure to tell the driver whether the data line should be driven. The user in this case is the Micrel KS8851 which has a direction control for the EEPROM data line and thus needs to know whether to drive it (writing) or to tristate it for receiving. Signed-off-by: Ben Dooks <ben@simtec.co.uk> Cc: Wolfram Sang <w.sang@pengutronix.de> Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26be2net: Fix non utilization of RX queuesPadmanabh Ratnakar1-6/+10
When non power of two MSIX vectors are given to driver, some RX queues are not utilized. Program RSS table in such a way that all queues are utilized. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26be2net: Use new hash keyPadmanabh Ratnakar1-2/+3
This new hash key gives better distribution of packets across RX queues. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26be2net: Add error handling for LancerPadmanabh Ratnakar1-49/+106
Detect error in Lancer by polling a HW register and recover from this error if it is recoverable. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26be2net: Fix error recovery pathsPadmanabh Ratnakar1-1/+4
When TX queues are created again after error recovery, netif_set_real_num_tx_queues() is invoked to update number of real TX queues created. rtnl lock needs to be held when invoking this routine. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26be2net: Move to new SR-IOV implementation in LancerPadmanabh Ratnakar3-25/+200
SR-IOV implementation is Lancer has changed in following ways - 1)PF driver assigns one MAC addresses for VF using COMMON_SET_IFACE_MAC_LIST. 2)VF driver queries its MAC address using COMMON_GET_IFACE_MAC_LIST command and assigns it to its interface. Signed-off-by: Mammatha Edhala <mammatha.edhala@emulex.com> Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26bonding: Remove obsolete source file 'bond_ipv6.c'Ben Hutchings1-223/+0
This file is now unused and should have been removed by commit 7c89943236750537d26421d9bbb6f6575e2d1e1b ("bonding, ipv4, ipv6, vlan: Handle NETDEV_BONDING_FAILOVER like NETDEV_NOTIFY_PEERS"). Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-26Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller15-25/+67
Conflicts: net/ipv4/inet_diag.c
2011-11-26net: Revert ARCNET and PHYLIB to tristate optionsBen Hutchings2-2/+2
commit 88491d8103498a6166f70d5999902fec70924314 ("drivers/net: Kconfig & Makefile cleanup") changed the type of these options to bool, but they select code that could (and still can) be built as modules. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-24net: mv643xx_eth: fix build errorAxel Lin1-4/+5
Fix below build error: CC drivers/net/ethernet/marvell/mv643xx_eth.o drivers/net/ethernet/marvell/mv643xx_eth.c: In function 'mv643xx_eth_get_drvinfo': drivers/net/ethernet/marvell/mv643xx_eth.c:1505: error: 'info' undeclared (first use in this function) drivers/net/ethernet/marvell/mv643xx_eth.c:1505: error: (Each undeclared identifier is reported only once drivers/net/ethernet/marvell/mv643xx_eth.c:1505: error: for each function it appears in.) make[4]: *** [drivers/net/ethernet/marvell/mv643xx_eth.o] Error 1 Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-23ehea: Use round_jiffies_relative to align workqueueAnton Blanchard1-2/+4
Use round_jiffies_relative to align the ehea workqueue and avoid extra wakeups. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-23ehea: Reduce memory usage in buffer poolsAnton Blanchard1-2/+2
Now that we enable multiqueue by default the ehea driver is using quite a lot of memory for its buffer pools. With 4 queues we consume 64MB in the jumbo packet ring, 16MB in the medium packet ring and 16MB in the tiny packet ring. We should only fill the jumbo ring once the MTU is increased but for now halve it's size so it consumes 32MB. Also reduce the tiny packet ring, with 4 queues we had 16k entries which is overkill. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-23qlge: fix size of external list for TX address descriptorsThadeu Lima de Souza Cascardo1-5/+3
When transmiting a fragmented skb, qlge fills a descriptor with the fragment addresses, after DMA-mapping them. If there are more than eight fragments, it will use the eighth descriptor as a pointer to an external list. After mapping this external list, called OAL to a structure containing more descriptors, it fills it with the extra fragments. However, considering that systems with pages larger than 8KiB would have less than 8 fragments, which was true before commit a715dea3c8e, it defined a macro for the OAL size as 0 in those cases. Now, if a skb with more than 8 fragments (counting skb->data as one fragment), this would start overwriting the list of addresses already mapped and would make the driver fail to properly unmap the right addresses on architectures with pages larger than 8KiB. Besides that, the list of mappings was one size too small, since it must have a mapping for the maxinum number of skb fragments plus one for skb->data and another for the OAL. So, even on architectures with page sizes 4KiB and 8KiB, a skb with the maximum number of fragments would make the driver overwrite its counter for the number of mappings, which, again, would make it fail to unmap the mapped DMA addresses. Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-23bnx2x: Fix 5461x LEDYaniv Rosner2-1/+39
Fix port identify test on 5461x PHY by driving LEDs through MDIO. Signed-off-by: Yaniv Rosner <yanivr@broadcom.com> Signed-off-by: Eilon Greenstein <eilong@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-23net: treewide use of RCU_INIT_POINTEREric Dumazet8-19/+19
rcu_assign_pointer(ptr, NULL) can be safely replaced by RCU_INIT_POINTER(ptr, NULL) (old rcu_assign_pointer() macro was testing the NULL value and could omit the smp_wmb(), but this had to be removed because of compiler warnings) Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-23b44: Use dev_kfree_skb_irq() in b44_tx()Xander Hover1-1/+1
Reported issues when using dev_kfree_skb() on UP systems and systems with low numbers of cores. dev_kfree_skb_irq() will properly save IRQ state before freeing the skb. Tested on 3.1.1 and 3.2_rc2 Example of reproducible trace of kernel 3.1.1 ------------[ cut here ]------------ WARNING: at kernel/softirq.c:159 local_bh_enable+0x32/0x79() ... Pid: 0, comm: swapper Not tainted 3.1.1-gentoo #1 Call Trace: [<c1022970>] warn_slowpath_common+0x65/0x7a [<c102699e>] ? local_bh_enable+0x32/0x79 [<c1022994>] warn_slowpath_null+0xf/0x13 [<c102699e>] local_bh_enable+0x32/0x79 [<c134bfd8>] destroy_conntrack+0x7c/0x9b [<c134890b>] nf_conntrack_destroy+0x1f/0x26 [<c132e3a6>] skb_release_head_state+0x74/0x83 [<c132e286>] __kfree_skb+0xb/0x6b [<c132e30a>] consume_skb+0x24/0x26 [<c127c925>] b44_poll+0xaa/0x449 [<c1333ca1>] net_rx_action+0x3f/0xea [<c1026a44>] __do_softirq+0x5f/0xd5 [<c10269e5>] ? local_bh_enable+0x79/0x79 <IRQ> [<c1026c32>] ? irq_exit+0x34/0x8d [<c1003628>] ? do_IRQ+0x74/0x87 [<c13f5329>] ? common_interrupt+0x29/0x30 [<c1006e18>] ? default_idle+0x29/0x3e [<c10015a7>] ? cpu_idle+0x2f/0x5d [<c13e91c5>] ? rest_init+0x79/0x7b [<c15c66a9>] ? start_kernel+0x297/0x29c [<c15c60b0>] ? i386_start_kernel+0xb0/0xb7 ---[ end trace 583f33bb1aa207a9 ]--- Signed-off-by: Xander Hover <LKML@hover.be> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless into for-davemJohn W. Linville3-4/+5
2011-11-22net: remove netdev_alloc_page and use __GFP_COLDEric Dumazet7-20/+18
Given we dont use anymore the struct net_device *dev argument, and this interface brings litle benefit, remove netdev_{alloc|free}_page(), to debloat include/linux/skbuff.h a bit. (Some drivers used a mix of these interfaces and alloc_pages()) When allocating a page given to device for DMA transfer (device to memory), it makes sense to use a cold one (__GFP_COLD) Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com> CC: Dimitris Michailidis <dm@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22Sweep away N/A fw_version dustbunnies from the .get_drvinfo routine of a number of driversRick Jones17-31/+7
Per discussion with Ben Hutchings and David Miller, go through and remove assignments of "N/A" to fw_version in various drivers' .get_drvinfo routines. While there clean-up some use of bare constants and such. Signed-off-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22net: remove ipv6_addr_copy()Alexey Dobriyan4-13/+11
C assignment can handle struct in6_addr copying. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22Revert "rt2800pci: handle spurious interrupts"John W. Linville1-6/+1
This reverts commit 4ba7d9997869d25bd223dea7536fc1ce9fab3b3b. The original patch was a misguided attempt to improve performance on some hardware that is apparently prone to spurious interrupt generation. Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-22Revert "rt2x00: handle spurious pci interrupts"John W. Linville3-3/+3
This reverts commit 23085d5796561625db4143a671f1de081f66ef08. The original patch was a misguided attempt to improve performance on some hardware that is apparently prone to spurious interrupt generation. Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-22tg3: Add MDI-X reportingMatt Carlson2-1/+28
This patch adds MDI-X state reporting. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22tg3: Restrict large prod ring cap devicesMatt Carlson1-5/+4
Future devices may or may not be capable of supporting larger rx producer rings. This patch changes the code so that this flag is set on an ASIC rev to ASIC rev basis. Also, this patch changes a place where the LRG_PROD_RING_CAP flag was not controlling how the rx standard producer ring size was set. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22tg3: Adjust BD replenish thresholdsMatt Carlson1-5/+3
The BD replenish thresholds for the 57765 and newer ASIC revs are a little strict. They were tuned for a mode that is currently unused. This patch relaxes the thresholds so that they are set to values more inline with the resources available. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22tg3: Make 1000Base-X FC resolution look like 1000TMatt Carlson1-12/+6
This patch changes tg3's 1000Base-X flow control resolution to look like the 1000Base-T flow control resolution code. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22CDC NCM: Use kzalloc rather than kmalloc followed by memset with 0Thomas Meyer1-3/+1
This considers some simple cases that are common and easy to validate Note in particular that there are no ...s in the rule, so all of the matched code has to be contiguous The semantic patch that makes this change is available in scripts/coccinelle/api/alloc/kzalloc-simple.cocci. Signed-off-by: Thomas Meyer <thomas@m3y3r.de> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22tg3: Fix advertisement handlingHiroaki SHIMODA1-4/+3
Commit 28011cf19b (net: Add ethtool to mii advertisment conversion helpers) added a helper function ethtool_adv_to_mii_100bt() and tg3_copper_is_advertising_all(), tg3_phy_autoneg_cfg() were modified to use this. Before that commit, ethtool to mii advertisement conversion was done wrt speed, but now pause operation is also taken account. So, in tg3_copper_is_advertising_all(), below condition becomes true and this makes link up fails. if ((adv_reg & ADVERTISE_ALL) != all_mask) return 0; To fix this add ADVERTISE_ALL bit and operation to cap speed, and change default advertisement not including ADVERTISED_Pause. Reported-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Hiroaki SHIMODA <shimoda.hiroaki@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-22rtlwifi: squash warning in _usb_read_syncJohn W. Linville1-2/+3
drivers/net/wireless/rtlwifi/usb.c: In function ‘_usb_read_sync’: drivers/net/wireless/rtlwifi/usb.c:102:6: warning: ‘status’ may be used uninitialized in this function drivers/net/wireless/rtlwifi/usb.c:102:6: note: ‘status’ was declared here My compiler is dumb, but better to eliminate the warning than to have anyone waste time evaluating this again... Signed-off-by: John W. Linville <linville@tuxdriver.com> Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
2011-11-22Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linuxJohn W. Linville2752-49333/+149769
Conflicts: drivers/net/wireless/iwlegacy/iwl-debugfs.c drivers/net/wireless/iwlegacy/iwl-rx.c drivers/net/wireless/iwlegacy/iwl-scan.c drivers/net/wireless/iwlegacy/iwl-tx.c include/net/bluetooth/bluetooth.h
2011-11-21net, sja1000: Don't include version.h in peak_pci.c when not neededJesper Juhl1-1/+0
It was pointed out by "make versioncheck" that we do not need to include version.h in drivers/net/can/sja1000/peak_pci.c This patch removes the unneeded include. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Acked-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-21carl9170: use ieee80211_free_txskbChristian Lamparter1-2/+2
In the past, it was fine to simply call dev_kfree_skb when it was impossible to transmit a skb. However, with the new tx status API: "mac80211: implement wifi TX status" Every loose skb needs to be handed back to mac80211. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21p54: use ieee80211_free_txskbChristian Lamparter1-2/+2
In the past, it was fine to simply call dev_kfree_skb when it was impossible to transmit a skb. However, with the new tx status API: "mac80211: implement wifi TX status" Every loose skb needs to be handed back to mac80211. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21rndis_wlan: remove unused macroJussi Kivilinna1-2/+0
NET_TYPE_11FB actually has never been used. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21rndis_wlan: add reporting of PMKSA candidate eventsJussi Kivilinna1-17/+9
Convert old WEXT reporting to use new cfg80211_pmksa_candidate_notify(). Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21rndis_wlan: add missing __packedJussi Kivilinna1-2/+2
Some structures were missing __packed. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21rndis_wlan: pass channel info to cfg80211_roamed()Jussi Kivilinna1-2/+3
cfg80211_roamed() now has channel parameter so add passing current channel info. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21rndis_wlan: split getting current channel to separate functionJussi Kivilinna1-18/+31
Split getting current channel channel from hardware to separate function as this function will be needed later in patch 'pass channel info to cfg80211_roamed()'. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21cfg80211: add flags for off-channel capabilitiesJohannes Berg1-1/+2
Currently mac80211 implements these for all devices, but given restrictions of some devices that isn't really true, so prepare for being able to remove the capability for some mac80211 devices. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Acked-by: Kalle Valo <kvalo@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21iwl-debug: Shrink object by using dev_err and deduplicating formatsJoe Perches1-16/+21
Using dev_err instead of dev_printk(KERN_ERR uses fewer arguments and is a bit smaller. Deduplicating formats used by IWL_DEBUG_QUIET_RFKILL also makes the object a bit smaller. Neatened the macros, used ##__VA_ARGS__. $ size drivers/net/wireless/iwlwifi/built-in.o* text data bss dec hex filename 462652 8646 92576 563874 89aa2 drivers/net/wireless/iwlwifi/built-in.o.new 467557 8646 92592 568795 8addb drivers/net/wireless/iwlwifi/built-in.o.old Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21iwlwifi: remove redundancyWey-Yi Guy1-1/+1
just use iwl_bus, remove the redundancy Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21iwlwifi: tid_data is taken twice in iwl_trans_pcie_tx_agg_allocEmmanuel Grumbach1-1/+0
Remove this redundancy. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21iwlwifi: fix endianity issues in debug printsEmmanuel Grumbach1-4/+2
Use the CPUed version of the variables when printing data from the BA notification. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21iwlwifi: improve the prints in the reclaim pathEmmanuel Grumbach4-6/+9
Some information was redundation, other was missing. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-21iwlwifi: check the HW when a queue is stuckEmmanuel Grumbach1-1/+5
Add more information when a queue is stuck and actually get information from the scheduler instead of looking at internal variables. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>