aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-07-26ath9k: fix dma direction for map/unmap in ath_rx_taskletMing Lei1-2/+2
For edma, we should use DMA_BIDIRECTIONAL, or else use DMA_FROM_DEVICE. This is found to address "BUG at arch/x86/mm/physaddr.c:5" as described here: http://lkml.org/lkml/2010/7/14/21 Signed-off-by: Ming Lei <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2010-07-25net: dev_forward_skb should call nf_resetBen Greear1-0/+1
With conn-track zones and probably with different network namespaces, the netfilter logic needs to be re-calculated on packet receive. If the netfilter logic is not reset, it will not be recalculated properly. This patch adds the nf_reset logic to dev_forward_skb. Signed-off-by: Ben Greear <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-25forcedeth: Fix different hardware statistics versions.Mike Ditto1-29/+31
The macros for the values of the bit field describing the four different versions of statistics supported by different hardware variants were being misused. Where the code was trying to test if the hardware implements V3, it was actually testing whether it implements any of V1, V2, or V3, causing the driver to report statistics that don't really exist in the hardware, with bogus values. Signed-off-by: Mike Ditto <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-25net-next: Fix an overflow bug in vmxnet3 Tx descriptorBhavesh Davda2-6/+11
Fix an overflow bug in vmxnet3 Tx descriptor This patch fixes a bug where a 16K buffer on a Tx descriptor was overflowing into the 'gen' bit in the descriptor thereby corrupting the descriptor and stalling the transmit ring. Signed-off-by: Bhavesh Davda <[email protected]> Signed-off-by: Shreyas Bhatewara <[email protected]> Signed-off-by: Matthew Delco <[email protected]> Signed-off-by: Ronghua Zhang <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-253c59x: Add ethtool WOL supportAndrew O. Shadoura1-0/+32
This patch adds wrappers for ethtool to get or set wake-on-LAN setting without re-inserting the kernel module. Signed-off-by: Andrew O. Shadoura <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-25qlcnic: fix diag resource allocationSony Chacko1-0/+1
netif_device_attach missing from error path in qlcnic_diag_alloc_res Signed-off-by: Sony Chacko <[email protected]> Signed-off-by: Amit Kumar Salecha <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-25qlcnic: fix loopback testAmit Kumar Salecha3-22/+8
o Loopback not supported for virtual function. Signed-off-by: Amit Kumar Salecha <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24net: pskb_expand_head() optimizationEric Dumazet2-2/+3
Move frags[] at the end of struct skb_shared_info, and make pskb_expand_head() copy only the used part of it instead of whole array. This should avoid kmemcheck warnings and speedup pskb_expand_head() as well, avoiding a lot of cache misses. Signed-off-by: Eric Dumazet <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24net sched: fix race in mirred device removalstephen hemminger2-3/+41
This fixes hang when target device of mirred packet classifier action is removed. If a mirror or redirection action is configured to cause packets to go to another device, the classifier holds a ref count, but was assuming the adminstrator cleaned up all redirections before removing. The fix is to add a notifier and cleanup during unregister. The new list is implicitly protected by RTNL mutex because it is held during filter add/delete as well as notifier. Signed-off-by: Stephen Hemminger <[email protected]> Acked-by: Jamal Hadi Salim <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24Merge branch 'wimax-2.6.35.y' of ↵David S. Miller2-0/+3
git://git.kernel.org/pub/scm/linux/kernel/git/inaky/wimax
2010-07-24sysfs: add attribute to indicate hw address assignment typeStefan Assmann3-0/+22
Add addr_assign_type to struct net_device and expose it via sysfs. This new attribute has the purpose of giving user-space the ability to distinguish between different assignment types of MAC addresses. For example user-space can treat NICs with randomly generated MAC addresses differently than NICs that have permanent (locally assigned) MAC addresses. For the former udev could write a persistent net rule by matching the device path instead of the MAC address. There's also the case of devices that 'steal' MAC addresses from slave devices. In which it is also be beneficial for user-space to be aware of the fact. This patch also introduces a helper function to assist adoption of drivers that generate MAC addresses randomly. Signed-off-by: Stefan Assmann <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24tun: avoid BUG, dump packet on GSO errorsMichael S. Tsirkin1-2/+12
There are still some LRO cards that cause GSO errors in tun, and BUG on this is an unfriendly way to tell the admin to disable LRO. Further, experience shows we might have more GSO bugs lurking. See https://bugzilla.kernel.org/show_bug.cgi?id=16413 as a recent example. dumping a packet will make it easier to figure it out. Replace BUG with warning+dump+drop the packet to make GSO errors in tun less critical and easier to debug. Signed-off-by: Michael S. Tsirkin <[email protected]> Tested-by: Alex Unigovsky <[email protected]> Acked-by: Herbert Xu <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24ixgbe: fix ethtool statsEric Dumazet1-21/+21
In latest changes about 64bit stats on 32bit arches, [commit 28172739f0a276eb8 (net: fix 64 bit counters on 32 bit arches)], I missed ixgbe uses a bit of magic in its ixgbe_gstrings_stats definition. IXGBE_NETDEV_STAT() must now assume offsets relative to rtnl_link_stats64, not relative do dev->stats. As a bonus, we also get 64bit stats on ethtool -S Signed-off-by: Eric Dumazet <[email protected]> Tested-by: Stephen Ko <[email protected]> Signed-off-by: Jeff Kirsher <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24qlcnic: fix bandwidth checkRajesh Borundia1-4/+3
Fix maximum and minmum bandwith value. Signed-off-by: Rajesh Borundia <[email protected]> Signed-off-by: Amit Kumar Salecha <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-24bonding: set device in RLB ARP packet handlerGreg Edwards1-1/+1
After: commit 6146b1a4da98377e4abddc91ba5856bef8f23f1e Author: Jay Vosburgh <[email protected]> Date: Tue Nov 4 17:51:15 2008 -0800 bonding: Fix ALB mode to balance traffic on VLANs the dev field in the RLB ARP packet handler was set to NULL to wildcard and accommodate balancing VLANs on top of bonds. This has the side-effect of the packet handler being called against other, non RLB-enabled bonds, and a kernel oops results when it tries to dereference rx_hashtbl in rlb_update_entry_from_arp(), which won't be set for those bonds, e.g. active-backup. With the __netif_receive_skb() changes from: commit 1f3c8804acba841b5573b953f5560d2683d2db0d Author: Andy Gospodarek <[email protected]> Date: Mon Dec 14 10:48:58 2009 +0000 bonding: allow arp_ip_targets on separate vlans to use arp validation frames received on VLANs correctly make their way to the bond's handler, so we no longer need to wildcard the device. The oops can be reproduced by: modprobe bonding echo active-backup > /sys/class/net/bond0/bonding/mode echo 100 > /sys/class/net/bond0/bonding/miimon ifconfig bond0 xxx.xxx.xxx.xxx netmask xxx.xxx.xxx.xxx echo +eth0 > /sys/class/net/bond0/bonding/slaves echo +eth1 > /sys/class/net/bond0/bonding/slaves echo +bond1 > /sys/class/net/bonding_masters echo balance-alb > /sys/class/net/bond1/bonding/mode echo 100 > /sys/class/net/bond1/bonding/miimon ifconfig bond1 xxx.xxx.xxx.xxx netmask xxx.xxx.xxx.xxx echo +eth2 > /sys/class/net/bond1/bonding/slaves echo +eth3 > /sys/class/net/bond1/bonding/slaves Pass some traffic on bond0. Boom. [ Tested, behaves as advertised. I do not believe a test of the bonding mode is necessary, as there is no race between the packet handler and the bonding mode changing (the mode can only change when the device is closed). Also updated the log message to include the reproduction and full commit ids. -J ] Signed-off-by: Greg Edwards <[email protected]> Signed-off-by: Jay Vosburgh <[email protected]> Acked-by: Andy Gospodarek <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23Merge branch 'master' of ↵David S. Miller52-2897/+315
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 Conflicts: drivers/net/wireless/iwlwifi/iwl-commands.h
2010-07-233c59x: Fix call to mdio_sync() with the wrong argumentBen Hutchings1-1/+1
commit a095cfc40ec7ebe63e9532383c5b5c2a27b14075 "3c59x: Specify window explicitly for access to windowed registers" changed the first parameter to mdio_sync(), from a pointer to the register mapping, to a pointer to the vortex_private structure, and changed all but one of the call sites. Fix that last one. Reported-by: Luca Falavigna <[email protected]> Signed-off-by: Ben Hutchings <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23net: s2io: fix buffer overflowKulikov Vasiliy1-10/+18
vpd_data[] is allocated as kmalloc(256, GFP_KERNEL), so if cnt = 255 then (cnt + 3) overflows 256. memset() is executed without checking. vpd_data[cnt+2] must be less than 256-cnt-2 as the latter is number of vpd_data[] elements to copy. Do not fill with zero the beginning of nic->serial_num as it will be filled with vpd_data[]. String in product_name[] should be terminated by '\0'. Signed-off-by: Kulikov Vasiliy <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23mv643xx_eth: potential null dereferenceDan Carpenter1-1/+2
We assume that "pd" can be null on the previous line, and throughout the function so we should check it here as well. This was introduced by 9b2c2ff7a1c0 "mv643xx_eth: use sw csum for big packets" Signed-off-by: Dan Carpenter <[email protected]> Acked-by: Lennert Buytenhek <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23net: 3c59x: fix leak of iomapsKulikov Vasiliy1-0/+1
If vortex_probe1() fails we should unmap ioaddr mapped earlier. Signed-off-by: Kulikov Vasiliy <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23net: core: don't use own hex_to_bin() methodAndy Shevchenko1-24/+12
Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23wireless: use newly introduced hex_to_bin()Andy Shevchenko1-21/+2
Signed-off-by: Andy Shevchenko <[email protected]> Cc: Corey Thomas <[email protected]> Cc: "John W. Linville" <[email protected]> Cc: [email protected] Signed-off-by: David S. Miller <[email protected]>
2010-07-23usb: usbnet: use newly introduced hex_to_bin()Andy Shevchenko1-11/+2
Signed-off-by: Andy Shevchenko <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Cc: [email protected] Signed-off-by: David S. Miller <[email protected]>
2010-07-23drivers: net: use newly introduced hex_to_bin()Andy Shevchenko1-6/+5
Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23drivers: atm: don't use private copy of hex_to_bin()Andy Shevchenko1-13/+2
Signed-off-by: Andy Shevchenko <[email protected]> Cc: Chas Williams <[email protected]> Cc: [email protected] Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: bump the driver version numberAjit Khaparde1-1/+1
Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: variable name changesAjit Khaparde4-8/+8
This patch changes names of some variables. Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: supress printing error when mac query fails for VFAjit Khaparde1-1/+2
When a virtual function driver in initialized, the network mac query command can fail. Skip display of error message in that case. Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: code to support tx rate configuration on virtual functionsAjit Khaparde4-1/+78
Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: add vlan support for sriov virtual functionsAjit Khaparde2-8/+47
Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: add support to get vf configAjit Khaparde2-13/+47
Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23be2net: change to call pmac_del only if necessaryAjit Khaparde2-2/+5
If a mac address has not been configured for a VF, there is no need to call be_cmd_pmac_del. Signed-off-by: Ajit Khaparde <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: avoid useless removal of multicast addressesUrsula Braun1-2/+0
Function qeth_l2_remove_device invokes qeth_l2_del_all_mc at the end. This is needless, because it is already called in the offline function. And even more this is invalid, because multicast addresses cannot be removed in DOWN state. Thus this patch deletes invocation of qeth_l2_del_all_mc in function qeth_l2_remove_device. Signed-off-by: Ursula Braun <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: Use memdup_user when user data is immediately copied into the ↵Julia Lawall1-8/+3
allocated region. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression from,to,size,flag; position p; identifier l1,l2; @@ - to = \(kmalloc@p\|kzalloc@p\)(size,flag); + to = memdup_user(from,size); if ( - to==NULL + IS_ERR(to) || ...) { <+... when != goto l1; - -ENOMEM + PTR_ERR(to) ...+> } - if (copy_from_user(to, from, size) != 0) { - <+... when != goto l2; - -EFAULT - ...+> - } // </smpl> Signed-off-by: Julia Lawall <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: return zero from reply callback functionsUrsula Braun1-8/+2
Reply callback functions in qeth should return zero if command response consists of one part only, otherwise qeth continues waiting for further parts of the command response. Signed-off-by: Ursula Braun <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23claw: A claw device is a group of just 2 ccw devicesUrsula Braun1-1/+1
When creating a claw device, just 2 subchannels have to be grouped. Signed-off-by: Ursula Braun <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: avoid loop if ipa command response is missingUrsula Braun2-0/+16
If qeth issues an ipa command, but for some reasons the response never comes back, qeth reaches a timeout. Reset the irq_pending flag of the write channel in timeout handling code and trigger a recovery to avoid endless looping for the following ipa command. Signed-off-by: Ursula Braun <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: serialize sysfs-triggered device configurationsUrsula Braun5-7/+22
This patch serializes device removal and other sysfs-triggered configurations by moving removal of sysfs-attributes to the beginning of the remove functions. And it serializes online/offline setting and discipline-switching (causing reestablishing of the net_device) by making use of a new discipline mutex. Signed-off-by: Ursula Braun <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: Clear mac_bits field when switching between Layer 2 and Layer 3Carsten Otte1-0/+1
This patch fixes a problem that occurs when switching from layer 3 to layer 2 mode. Resetting this mac_bits makes sure that we retrieve our mac address from the card, otherwise the interface simply would'nt work. Signed-off-by: Carsten Otte <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23qeth: IP address takeover flag settingKlaus-Dieter Wacker5-9/+18
The qeth IP address flag setting is possible when device is offline. When setting device online afterwards the current set IP addresses have to be correctly registered with the device regarding the IP address takeover attribute. Signed-off-by: Klaus-Dieter Wacker <[email protected]> Signed-off-by: Frank Blaschka <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-07-23iwlwifi: remove spurious semicolonsJohannes Berg1-2/+2
defines shouldn't be terminated with a semicolon, the code using them should supply it. Luckily these are not used in a context where it matters. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlwifi: reduce beacon fill conditionsJohannes Berg2-6/+2
Since the ibss_beacon variable will only be filled in the appropriate modes, there's no reason to be checking the mode again. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlwifi: read multiple MAC addressesWey-Yi Guy3-5/+16
Some devices may have multiple MAC addresses in their EEPROM, read them and advertise them to cfg80211. Signed-off-by: Wey-Yi Guy <[email protected]> Signed-off-by: Johannes Berg <[email protected]>
2010-07-23iwlwifi: make iwl_mac_beacon_update staticJohannes Berg2-33/+31
This function is only needed in the same file it is defined in, i.e. iwl-core.c Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlagn: fix firmware loading TLV error pathJohannes Berg1-44/+35
gcc complains about the firmware loading: iwl-agn.c: In function ‘iwlagn_load_firmware’: iwl-agn.c:1860: warning: ‘tlv_len’ may be used uninitialized in this function iwl-agn.c:1861: warning: ‘tlv_type’ may be used uninitialized in this function iwl-agn.c:1862: warning: ‘tlv_data’ may be used uninitialized in this function This is almost correct but we do do break out of the TLV parsing loop when setting ret. However, the code is hard to follow, and clearly even the compiler is having issues with it too. Additionally, however, the current code is wrong. If there is a TLV length check error, the code will report invalid TLV after parsing: ... because "len" will still be non-zero as we broke out of the loop. So to remove the warning and fix that issue, make the code easier to read by doing length checking with an error label. As a result, we can completely remove the "ret" variable. Also, while at it, remove the "fixed_tlv_size" variable since each TLV type has its own specified length, it just happens that we have only variable length, flags (0 length) and u32 TLVs right now. It should still be checked with more explicit length checks to make it easier to understand. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlwifi: add TLV to specify the size of phy calibration tableWey-Yi Guy4-4/+37
Different devices have different size of phy calibration table; add new TLV to specify the size. If the TLV is not part of uCode header, the default table size will be used to make sure the backward compatibilities. Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlagn: add bluetooth stats to debugfsWey-Yi Guy8-0/+113
For WiFi/BT combo devices, add bluetooth statistics counter read function to debugfs. Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlagn: Add support for bluetooth statistics notificationWey-Yi Guy7-119/+271
WiFi/BT combo devices has different statistics notification structure, adding the support here to make sure the structure align correctly. Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlagn: add .cfg flag to idenfity the need for bt statisticsWey-Yi Guy2-0/+7
Only WiFi/BT combo devices need to use bluetooth version of statistics notification; adding the flag in .cfg file to indicate the need for using different data structure. Signed-off-by: Wey-Yi Guy <[email protected]>
2010-07-23iwlagn: add statistic notification structure for WiFi/BT devicesWey-Yi Guy6-27/+71
If its WiFi/BT combo device, the statistics notification sent by uCode will include the additional BT related statistics counters. Adding new data structure to support the new layout. Signed-off-by: Wey-Yi Guy <[email protected]>