10 Jul, 2013

1 commit

  • Pull networking updates from David Miller:
    "This is a re-do of the net-next pull request for the current merge
    window. The only difference from the one I made the other day is that
    this has Eliezer's interface renames and the timeout handling changes
    made based upon your feedback, as well as a few bug fixes that have
    trickeled in.

    Highlights:

    1) Low latency device polling, eliminating the cost of interrupt
    handling and context switches. Allows direct polling of a network
    device from socket operations, such as recvmsg() and poll().

    Currently ixgbe, mlx4, and bnx2x support this feature.

    Full high level description, performance numbers, and design in
    commit 0a4db187a999 ("Merge branch 'll_poll'")

    From Eliezer Tamir.

    2) With the routing cache removed, ip_check_mc_rcu() gets exercised
    more than ever before in the case where we have lots of multicast
    addresses. Use a hash table instead of a simple linked list, from
    Eric Dumazet.

    3) Add driver for Atheros CQA98xx 802.11ac wireless devices, from
    Bartosz Markowski, Janusz Dziedzic, Kalle Valo, Marek Kwaczynski,
    Marek Puzyniak, Michal Kazior, and Sujith Manoharan.

    4) Support reporting the TUN device persist flag to userspace, from
    Pavel Emelyanov.

    5) Allow controlling network device VF link state using netlink, from
    Rony Efraim.

    6) Support GRE tunneling in openvswitch, from Pravin B Shelar.

    7) Adjust SOCK_MIN_RCVBUF and SOCK_MIN_SNDBUF for modern times, from
    Daniel Borkmann and Eric Dumazet.

    8) Allow controlling of TCP quickack behavior on a per-route basis,
    from Cong Wang.

    9) Several bug fixes and improvements to vxlan from Stephen
    Hemminger, Pravin B Shelar, and Mike Rapoport. In particular,
    support receiving on multiple UDP ports.

    10) Major cleanups, particular in the area of debugging and cookie
    lifetime handline, to the SCTP protocol code. From Daniel
    Borkmann.

    11) Allow packets to cross network namespaces when traversing tunnel
    devices. From Nicolas Dichtel.

    12) Allow monitoring netlink traffic via AF_PACKET sockets, in a
    manner akin to how we monitor real network traffic via ptype_all.
    From Daniel Borkmann.

    13) Several bug fixes and improvements for the new alx device driver,
    from Johannes Berg.

    14) Fix scalability issues in the netem packet scheduler's time queue,
    by using an rbtree. From Eric Dumazet.

    15) Several bug fixes in TCP loss recovery handling, from Yuchung
    Cheng.

    16) Add support for GSO segmentation of MPLS packets, from Simon
    Horman.

    17) Make network notifiers have a real data type for the opaque
    pointer that's passed into them. Use this to properly handle
    network device flag changes in arp_netdev_event(). From Jiri
    Pirko and Timo Teräs.

    18) Convert several drivers over to module_pci_driver(), from Peter
    Huewe.

    19) tcp_fixup_rcvbuf() can loop 500 times over loopback, just use a
    O(1) calculation instead. From Eric Dumazet.

    20) Support setting of explicit tunnel peer addresses in ipv6, just
    like ipv4. From Nicolas Dichtel.

    21) Protect x86 BPF JIT against spraying attacks, from Eric Dumazet.

    22) Prevent a single high rate flow from overruning an individual cpu
    during RX packet processing via selective flow shedding. From
    Willem de Bruijn.

    23) Don't use spinlocks in TCP md5 signing fast paths, from Eric
    Dumazet.

    24) Don't just drop GSO packets which are above the TBF scheduler's
    burst limit, chop them up so they are in-bounds instead. Also
    from Eric Dumazet.

    25) VLAN offloads are missed when configured on top of a bridge, fix
    from Vlad Yasevich.

    26) Support IPV6 in ping sockets. From Lorenzo Colitti.

    27) Receive flow steering targets should be updated at poll() time
    too, from David Majnemer.

    28) Fix several corner case regressions in PMTU/redirect handling due
    to the routing cache removal, from Timo Teräs.

    29) We have to be mindful of ipv4 mapped ipv6 sockets in
    upd_v6_push_pending_frames(). From Hannes Frederic Sowa.

    30) Fix L2TP sequence number handling bugs, from James Chapman."

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1214 commits)
    drivers/net: caif: fix wrong rtnl_is_locked() usage
    drivers/net: enic: release rtnl_lock on error-path
    vhost-net: fix use-after-free in vhost_net_flush
    net: mv643xx_eth: do not use port number as platform device id
    net: sctp: confirm route during forward progress
    virtio_net: fix race in RX VQ processing
    virtio: support unlocked queue poll
    net/cadence/macb: fix bug/typo in extracting gem_irq_read_clear bit
    Documentation: Fix references to defunct linux-net@vger.kernel.org
    net/fs: change busy poll time accounting
    net: rename low latency sockets functions to busy poll
    bridge: fix some kernel warning in multicast timer
    sfc: Fix memory leak when discarding scattered packets
    sit: fix tunnel update via netlink
    dt:net:stmmac: Add dt specific phy reset callback support.
    dt:net:stmmac: Add support to dwmac version 3.610 and 3.710
    dt:net:stmmac: Allocate platform data only if its NULL.
    net:stmmac: fix memleak in the open method
    ipv6: rt6_check_neigh should successfully verify neigh if no NUD information are available
    net: ipv6: fix wrong ping_v6_sendmsg return value
    ...

    Linus Torvalds
     

04 Jul, 2013

1 commit

  • For the workqueue creation interfaces that do not expect format strings,
    make sure they cannot accidently be parsed that way. Additionally, clean
    up calls made with a single parameter that would be handled as a format
    string. Many callers are passing potentially dynamic string content, so
    use "%s" in those cases to avoid any potential accidents.

    Signed-off-by: Kees Cook
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kees Cook
     

04 Jun, 2013

1 commit


25 May, 2013

1 commit

  • Using separate locks in cfg80211 and mac80211 has always
    caused issues, for example having to unlock in places in
    mac80211 to call cfg80211, which even needed a framework
    to make cfg80211 calls after some functions returned etc.

    Additionally, I suspect some issues people have reported
    with the cfg80211 state getting confused could be due to
    such issues, when cfg80211 is asking mac80211 to change
    state but mac80211 is in the process of telling cfg80211
    that the state changed (in another way.)

    Signed-off-by: Johannes Berg

    Johannes Berg
     

16 Apr, 2013

1 commit

  • I noticed that monitor interfaces by default would start on 5GHz
    while STA/AP ones would start 2GHZ - It stems from the fact that
    ieee80211_register_hw unnecessarily adjusts the local->monitor_chandef
    for each band.

    This avoids this and while at it uses a single dflt_chandef to initialize
    in one go local->{hw.conf.chandef,_oper_chandef,monitor_chandef}

    Signed-off-by: Karl Beldan
    Signed-off-by: Johannes Berg

    Karl Beldan
     

08 Apr, 2013

1 commit


26 Mar, 2013

1 commit


25 Mar, 2013

1 commit

  • mac80211 currently sets uAPSD parameters to have VO AC trigger-
    and delivery-enabled, with maximum service period length.

    Allow drivers to change these default settings since different
    uAPSD client implementations may handle errors differently and
    be able to recover from some errors.

    Note: some APs may not function correctly if one or all ACs are
    trigger- and delivery-enabled, see
    http://thread.gmane.org/gmane.linux.kernel.wireless.general/93577.
    We retested with this AP and later firmware doesn't have this
    bug any more.

    Signed-off-by: Alexander Bondar
    Signed-off-by: Johannes Berg

    Alexander Bondar
     

19 Mar, 2013

1 commit


11 Mar, 2013

1 commit


07 Mar, 2013

1 commit

  • The irqsafe version ieee80211_sta_eosp_irqsafe() exists, but
    drivers must not mix calls to any irqsafe/non-irqsafe function.
    Both ath9k and iwlwifi, the likely first users of this interface,
    use non-irqsafe RX/TX/TX status so must also use a non-irqsafe
    version of this function. Since no driver uses the _irqsafe()
    version, remove that.

    Signed-off-by: Johannes Berg

    Johannes Berg
     

06 Mar, 2013

3 commits


28 Feb, 2013

1 commit


15 Feb, 2013

4 commits

  • There's various code with strange indentation,
    questionable loop and locking constructs, etc.

    The bigger change is moving the "sdata" argument
    to the first argument of all functions, like all
    other mac80211 functions that have one.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • Adding the flag to mac80211 already without testing was
    clearly a mistake, one that we now pay for by having to
    reserve bit 13 forever. The problem is cfg80211 doesn't
    allow capability/rate changes for station entries that
    were added unassociated, so the station entries cannot
    be set up properly when marked associated.

    Change the NL80211_FEATURE_FULL_AP_CLIENT_STATE value
    to make it clear to userspace implementations that all
    current kernels don't actually support it, even though
    the previous bit is set, and of course also remove the
    flag from mac80211 until we test and fix the issues.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • Use the new extended capabilities advertising to advertise
    the fact that operating mode notification is supported.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • Add command to trigger radar detection in the driver/FW.
    Once radar detection is started it should continuously
    monitor for radars as long as the channel active.
    If radar is detected usermode notified with 'radar
    detected' event.

    Scanning and remain on channel functionality must be disabled
    while doing radar detection/scanning, and vice versa.

    Based on original patch by Victor Goldenshtein

    Signed-off-by: Simon Wunderlich
    Signed-off-by: Johannes Berg

    Simon Wunderlich
     

12 Feb, 2013

2 commits

  • There are only a few drivers that use HW scan, and
    all of those don't need a non-idle transition before
    starting the scan -- some don't even care about idle
    at all. Remove the flag and code associated with it.

    The only driver that really actually needed this is
    wl1251 and it can just do it itself in the hw_scan
    callback -- implement that.

    Acked-by: Luciano Coelho
    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • This patch fixes the problem which was discussed in
    "mac80211: Fix PN corruption in case of multiple
    virtual interface" [1].

    Amit Shakya reported a serious issue with my patch:
    mac80211: serialize rx path workers" [2]:

    In case, ieee80211_rx_handlers processing is going on
    for skbs received on one vif and at the same time, rx
    aggregation reorder timer expires on another vif then
    sta_rx_agg_reorder_timer_expired is invoked and it will
    push skbs into the single queue (local->rx_skb_queue).

    ieee80211_rx_handlers in the while loop assumes that
    the skbs are for the same sdata and sta. This assumption
    doesn't hold good in this scenario and the PN gets
    corrupted by PN received in other vif's skb, causing
    traffic to stop due to PN mismatch."

    [1] Message-Id: http://mid.gmane.org/201302041844.44436.chunkeey@googlemail.com
    [2] Commit-Id: 24a8fdad35835e8d71f7

    Reported-by: Amit Shakya
    Signed-off-by: Christian Lamparter
    Signed-off-by: Johannes Berg

    Christian Lamparter
     

19 Jan, 2013

2 commits

  • To be able to implement NS response offloading (in
    regular operation or while in WoWLAN) drivers need
    to know the IPv6 addresses assigned to interfaces.
    Implement an IPv6 notifier in mac80211 to call the
    driver when addresses change.

    Unlike for IPv4, implement it as a callback rather
    than as a list in the BSS configuration, that is
    more flexible.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • Depending on the driver, having ARP filtering for
    some addresses may be possible. Remove the logic
    that tracks whether ARP filter is enabled or not
    and give the driver the total number of addresses
    instead of the length of the list so it can make
    its own decision.

    Reviewed-by: Luciano Coelho
    Signed-off-by: Johannes Berg

    Johannes Berg
     

03 Jan, 2013

5 commits

  • Today, stations are added already associated. That is
    inefficient if, for example, the driver has no room
    for stations any more because then the station will
    go through the entire auth/assoc handshake, only to
    be kicked out afterwards.

    To address this a bit better, at least with drivers
    using the new station state callback, allow hostapd
    to add stations in unauthenticated mode, just after
    receiving the AUTH frame, before even replying. Thus
    if there's no more space at that point, it can send
    a negative auth frame back. It still needs to handle
    later state transition errors though, of course.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • Instead of checking every time bss_info_changed is called,
    assign the pointer once depending on the interface type
    and then leave it untouched until the interface type is
    changed. This makes the ieee80211_bss_info_change_notify()
    now a simple wrapper to call the driver only.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • The special case in the function isn't really needed,
    instead make the suspend code a bit better and also
    easier to understand and move the warning into the
    driver op wrapper inline.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • Instead of calculating in ieee80211_bss_info_change_notify()
    whether beaconing should be enabled or not, set it in the
    correct places in the callers. This simplifies the logic in
    this function at the expense of offchannel, but is also more
    robust.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • This allows user-space (wpa_supplicant) to disable
    short guard interval (SGI) for 20Mhz. The SGI-40
    disable option is already handled.

    Signed-off-by: Ben Greear
    Signed-off-by: Johannes Berg

    Ben Greear
     

07 Dec, 2012

1 commit


30 Nov, 2012

1 commit


27 Nov, 2012

2 commits


26 Nov, 2012

2 commits

  • Convert mac80211 (and where necessary, some drivers a
    little bit) to the new channel definition struct.

    This will allow extending mac80211 for VHT, which is
    currently restricted to channel contexts since there
    are no drivers using that which makes it easier. As
    I also don't care about VHT for drivers not using the
    channel context API, I won't convert the previous API
    to VHT support.

    Signed-off-by: Johannes Berg

    Johannes Berg
     
  • As mwifiex (and mac80211 in the software case) are the
    only drivers actually implementing remain-on-channel
    with channel type, userspace can't be relying on it.
    This is the case, as it's used only for P2P operations
    right now.

    Rather than adding a flag to tell userspace whether or
    not it can actually rely on it, simplify all the code
    by removing the ability to use different channel types.
    Leave only the validation of the attribute, so that if
    we extend it again later (with the needed capability
    flag), it can't break userspace sending invalid data.

    Signed-off-by: Johannes Berg

    Johannes Berg
     

22 Nov, 2012

1 commit


09 Nov, 2012

1 commit


30 Oct, 2012

1 commit

  • Even before channel contexts/multi-channel, having a
    single global TX power limit was already problematic,
    in particular if two managed interfaces connected to
    two APs with different power constraints. The channel
    context introduction completely broke this though and
    in fact I had disabled TX power configuration there
    for drivers using channel contexts.

    Change everything to track TX power per interface so
    that different user settings and different channel
    maxima are treated correctly. Also continue tracking
    the global TX power though for compatibility with
    applications that attempt to configure the wiphy's
    TX power globally.

    Signed-off-by: Johannes Berg

    Johannes Berg
     

22 Oct, 2012

1 commit


18 Oct, 2012

2 commits

  • If the user wants to scan using a vif configured as AP,
    cfg80211 must give him a chance to do it, even if this
    will disrupt the stations performance due to off-channel
    scanning. To do so, this patch adds a 'force' flag to the
    SCAN_TRIGGER command which tells cfg80211 to perform the
    scanning operation even if the vif is an AP and the
    beaconing has already started.

    Signed-off-by: Antonio Quartulli
    Signed-off-by: Johannes Berg

    Antonio Quartulli
     
  • Use NL80211_SCAN_FLAG_LOW_PRIORITY flag in mac80211's scan state
    machine to prematurely terminate scan operations if outbound
    traffic collides. This is useful for marking background scans so
    they don't affect throughput.

    Signed-off-by: Sam Leffler
    Signed-off-by: Amitkumar Karwar
    Signed-off-by: Bing Zhao
    [set feature flag only if software scan is used]
    Signed-off-by: Johannes Berg

    Sam Leffler