24 Jun, 2013

1 commit

  • Callers of skb_seq_read() are currently forced to call skb_abort_seq_read()
    even when consuming all the data because the last call to skb_seq_read (the
    one that returns 0 to indicate the end) fails to unmap the last fragment page.

    With this patch callers will be allowed to traverse the SKB data by calling
    skb_prepare_seq_read() once and repeatedly calling skb_seq_read() as originally
    intended (and documented in the original commit 677e90eda), that is, only call
    skb_abort_seq_read() if the sequential read is actually aborted.

    Signed-off-by: Wedson Almeida Filho
    Signed-off-by: David S. Miller

    Wedson Almeida Filho
     

20 Jun, 2013

1 commit

  • Conflicts:
    drivers/net/wireless/ath/ath9k/Kconfig
    drivers/net/xen-netback/netback.c
    net/batman-adv/bat_iv_ogm.c
    net/wireless/nl80211.c

    The ath9k Kconfig conflict was a change of a Kconfig option name right
    next to the deletion of another option.

    The xen-netback conflict was overlapping changes involving the
    handling of the notify list in xen_netbk_rx_action().

    Batman conflict resolution provided by Antonio Quartulli, basically
    keep everything in both conflict hunks.

    The nl80211 conflict is a little more involved. In 'net' we added a
    dynamic memory allocation to nl80211_dump_wiphy() to fix a race that
    Linus reported. Meanwhile in 'net-next' the handlers were converted
    to use pre and post doit handlers which use a flag to determine
    whether to hold the RTNL mutex around the operation.

    However, the dump handlers to not use this logic. Instead they have
    to explicitly do the locking. There were apparent bugs in the
    conversion of nl80211_dump_wiphy() in that we were not dropping the
    RTNL mutex in all the return paths, and it seems we very much should
    be doing so. So I fixed that whilst handling the overlapping changes.

    To simplify the initial returns, I take the RTNL mutex after we try
    to allocate 'tb'.

    Signed-off-by: David S. Miller

    David S. Miller
     

10 Jun, 2013

3 commits

  • The bridge loop avoidance has a hook to handle address updates of the
    originator. These should not be handled when bridge loop avoidance is
    disabled - it might send some bridge loop avoidance packets which should
    not appear if bla is disabled.

    Signed-off-by: Simon Wunderlich
    Signed-off-by: Marek Lindner
    Signed-off-by: Antonio Quartulli

    Simon Wunderlich
     
  • When a packet is received from another node first and later from the
    best next hop, this packet is dropped. However the first OGM was sent
    with the BATADV_NOT_BEST_NEXT_HOP flag and thus dropped by neighbors.
    The late OGM from the best neighbor is then dropped because it is a
    duplicate.

    If this situation happens constantly, a node might end up not forwarding
    the "valid" OGMs anymore, and nodes behind will starve from not getting
    valid OGMs.

    Fix this by refining the duplicate checking behaviour: The actions
    should depend on whether it was a duplicate for a neighbor only or for
    the originator. OGMs which are not duplicates for a specific neighbor
    will now be considered in batadv_iv_ogm_forward(), but only actually
    forwarded for the best next hop. Therefore, late OGMs from the best
    next hop are forwarded now and not dropped as duplicates anymore.

    Signed-off-by: Simon Wunderlich
    Signed-off-by: Marek Lindner
    Signed-off-by: Antonio Quartulli

    Simon Wunderlich
     
  • The rtnl_lock in batadv_store_mesh_iface has been converted to a rtnl_trylock
    some time ago to avoid a possible deadlock between rtnl and s_active on removal
    of the sysfs nodes.

    The behaviour introduced by that was quite confusing as it could lead to the
    sysfs store to fail, making batman-adv setup scripts unreliable. As recently the
    sysfs removal was postponed to a worker not running with the rtnl taken, the
    deadlock can't occur any more and it is safe to change the trylock back to a
    lock to make the sysfs store reliable again.

    Signed-off-by: Matthias Schiffer
    Reviewed-by: Simon Wunderlich
    Signed-off-by: Marek Lindner
    Signed-off-by: Antonio Quartulli

    Matthias Schiffer
     

29 May, 2013

22 commits


22 May, 2013

1 commit

  • On errors in batadv_mesh_init(), bat_counters will be freed in both
    batadv_mesh_free() and batadv_softif_init_late(). This patch fixes this
    by returning earlier from batadv_softif_init_late() in case of errors in
    batadv_mesh_init() and by setting bat_counters to NULL after freeing.

    Signed-off-by: Martin Hundebøll
    Signed-off-by: Marek Lindner
    Signed-off-by: Antonio Quartulli

    Martin Hundebøll
     

17 May, 2013

1 commit

  • rcu_barrier() only waits for the currently scheduled rcu functions
    to finish - it won't wait for any function scheduled via another
    call_rcu() within an rcu scheduled function.

    Unfortunately our batadv_tt_orig_list_entry_free_ref() does just that,
    via a batadv_orig_node_free_ref() call, leading to our rcu_barrier()
    call potentially missing such a batadv_orig_node_free_ref().

    This patch fixes this issue by calling the batadv_orig_node_free_rcu()
    directly from the rcu callback, removing the unnecessary, additional
    call_rcu() layer here.

    Signed-off-by: Linus Lüssing
    Signed-off-by: Marek Lindner
    Acked-by: Antonio Quartulli

    Linus Lüssing
     

09 May, 2013

4 commits


30 Apr, 2013

1 commit


23 Apr, 2013

2 commits

  • batadv_mesh_free() schedules some RCU callbacks which need the bat_priv struct
    to do their jobs, while free_netdev(), which is called immediately after, is
    destroying the private data.

    Put an rcu_barrier() in the middle so that free_netdev() is invoked only after
    all the callbacks returned.

    This bug has been introduced by ab8f433dd39be94e8617cff2dfe9f7eca162eb15
    ("batman-adv: Move deinitialization of soft-interface to destructor")

    Signed-off-by: Antonio Quartulli
    Signed-off-by: Marek Lindner
    Signed-off-by: David S. Miller

    Antonio Quartulli
     
  • Conflicts:
    drivers/net/ethernet/emulex/benet/be_main.c
    drivers/net/ethernet/intel/igb/igb_main.c
    drivers/net/wireless/brcm80211/brcmsmac/mac80211_if.c
    include/net/scm.h
    net/batman-adv/routing.c
    net/ipv4/tcp_input.c

    The e{uid,gid} --> {uid,gid} credentials fix conflicted with the
    cleanup in net-next to now pass cred structs around.

    The be2net driver had a bug fix in 'net' that overlapped with the VLAN
    interface changes by Patrick McHardy in net-next.

    An IGB conflict existed because in 'net' the build_skb() support was
    reverted, and in 'net-next' there was a comment style fix within that
    code.

    Several batman-adv conflicts were resolved by making sure that all
    calls to batadv_is_my_mac() are changed to have a new bat_priv first
    argument.

    Eric Dumazet's TS ECR fix in TCP in 'net' conflicted with the F-RTO
    rewrite in 'net-next', mostly overlapping changes.

    Thanks to Stephen Rothwell and Antonio Quartulli for help with several
    of these merge resolutions.

    Signed-off-by: David S. Miller

    David S. Miller
     

22 Apr, 2013

1 commit

  • Unicast packet might be of type either UNICAST or
    UNICAST4ADDR.
    In the two cases the header size is different, but the
    mechanism checking the TTVN field was assuming it to be
    always of the same type (UNICAST), so failing to access the
    inner Ethernet header in case of UNICAST4ADDR.

    Fix this by passing the real header length as argument.

    Signed-off-by: Antonio Quartulli
    Signed-off-by: Marek Lindner

    Antonio Quartulli
     

20 Apr, 2013

1 commit


18 Apr, 2013

1 commit


27 Mar, 2013

1 commit