27 Jul, 2010

1 commit

  • commit 1dacc76d0014
    (net/compat/wext: send different messages to compat tasks)
    introduced a race condition on netlink, in case MSG_PEEK is used.

    An skb given by skb_recv_datagram() might be shared, we must copy it
    before any modification, or risk fatal corruption.

    Signed-off-by: Eric Dumazet
    Signed-off-by: David S. Miller

    Eric Dumazet
     

26 Jul, 2010

5 commits

  • 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
    Signed-off-by: David S. Miller

    Mike Ditto
     
  • 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
    Signed-off-by: Shreyas Bhatewara
    Signed-off-by: Matthew Delco
    Signed-off-by: Ronghua Zhang
    Signed-off-by: David S. Miller

    Bhavesh Davda
     
  • 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
    Signed-off-by: David S. Miller

    Andrew O. Shadoura
     
  • netif_device_attach missing from error path in qlcnic_diag_alloc_res

    Signed-off-by: Sony Chacko
    Signed-off-by: Amit Kumar Salecha
    Signed-off-by: David S. Miller

    Sony Chacko
     
  • o Loopback not supported for virtual function.

    Signed-off-by: Amit Kumar Salecha
    Signed-off-by: David S. Miller

    Amit Kumar Salecha
     

25 Jul, 2010

4 commits

  • 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
    Signed-off-by: David S. Miller

    Eric Dumazet
     
  • 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
    Signed-off-by: David S. Miller

    Stefan Assmann
     
  • 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
    Tested-by: Stephen Ko
    Signed-off-by: Jeff Kirsher
    Signed-off-by: David S. Miller

    Eric Dumazet
     
  • Fix maximum and minmum bandwith value.

    Signed-off-by: Rajesh Borundia
    Signed-off-by: Amit Kumar Salecha
    Signed-off-by: David S. Miller

    Rajesh Borundia
     

24 Jul, 2010

25 commits


23 Jul, 2010

5 commits

  • If the allocations fail in either dwmac1000_setup() or dwmac100_setup()
    then return NULL. These are called from stmmac_mac_device_setup(). The
    check for NULL returns in stmmac_mac_device_setup() needed to be moved
    forward a couple lines.

    Signed-off-by: Dan Carpenter
    Signed-off-by: David S. Miller

    Dan Carpenter
     
  • Negate has precedence over comparison so the original assert only
    checked that "rfml->fragment_size" was larger than 1 or 0.

    Signed-off-by: Dan Carpenter
    Signed-off-by: David S. Miller

    Dan Carpenter
     
  • When copying VLAN information to or removing from a slave
    during slave addition or removal, the bonding code currently holds
    the bond->lock for write to prevent concurrent modification of the
    vlan_list / vlgrp.

    This is unnecessary, as all of these operations occur under
    RTNL. Holding the bond->lock also caused might_sleep issues for
    some drivers' ndo_vlan_* functions. This patch removes the extra
    locking.

    Problem reported by Michael Chan

    Signed-off-by: Jay Vosburgh
    Cc: Michael Chan
    Signed-off-by: David S. Miller

    Jay Vosburgh
     
  • After commit ad1afb00393915a51c21b1ae8704562bf036855f
    ("vlan_dev: VLAN 0 should be treated as "no vlan tag" (802.1p packet)")
    it is now regular practice for a VLAN "add vid" for VLAN 0 to
    arrive prior to any VLAN registration or creation of a vlan_group.

    This patch updates the bonding code that tests for the presence
    of VLANs configured above bonding. The new logic tests for bond->vlgrp
    to determine if a registration has occured, instead of testing that
    bonding's internal vlan_list is empty.

    The old code would panic when vlan_list was not empty, but
    vlgrp was still NULL (because only an "add vid" for VLAN 0 had occured).

    Bonding still adds VLAN 0 to its internal list so that 802.1p
    frames are handled correctly on transmit when non-VLAN accelerated
    slaves are members of the bond. The test against bond->vlan_list
    remains in bond_dev_queue_xmit for this reason.

    Modification to the bond->vlgrp now occurs under lock (in
    addition to RTNL), because not all inspections of it occur under RTNL.

    Additionally, because 8021q will never issue a "kill vid" for
    VLAN 0, there is now logic in bond_uninit to release any remaining
    entries from vlan_list.

    Signed-off-by: Jay Vosburgh
    Cc: Pedro Garcia
    Cc: Patrick McHardy
    Signed-off-by: David S. Miller

    Jay Vosburgh
     
  • After the change from mdio polling to irq, it became necessary to
    restore the interrupt mask after resetting the chip in fec_stop().
    Otherwise, with all irqs disabled, no communication with the PHY will be
    possible after e.g. un-/replugging the cable and the device gets
    stalled.

    Signed-off-by: Wolfram Sang
    Signed-off-by: David S. Miller

    Wolfram Sang