18 Oct, 2016

1 commit

  • Remove the unused but set variable master_dev in check_local_dest to fix
    the following GCC warning when building with 'W=1':

    net/hsr/hsr_forward.c: In function ‘check_local_dest’:
    net/hsr/hsr_forward.c:303:21: warning: variable ‘master_dev’ set but not used [-Wunused-but-set-variable]

    Signed-off-by: Tobias Klauser
    Signed-off-by: David S. Miller

    Tobias Klauser
     

17 May, 2016

1 commit

  • The function setup_timer combines the initialization of a timer with the
    initialization of the timer's function and data fields. The mulitiline
    code for timer initialization is now replaced with function setup_timer.

    Also, quoting the mod_timer() function comment:
    -> mod_timer() is a more efficient way to update the expire field of an
    active timer (if the timer is inactive it will be activated).

    Use setup_timer() and mod_timer() to setup and arm a timer, making the
    code compact and aid readablity.

    Signed-off-by: Muhammad Falak R Wani
    Signed-off-by: David S. Miller

    Muhammad Falak R Wani
     

22 Apr, 2016

1 commit


16 Apr, 2016

1 commit

  • This patch adds support for the newer version 1 of the HSR
    networking standard. Version 0 is still default and the new
    version has to be selected via iproute2.

    Main changes are in the supervision frame handling and its
    ethertype field.

    Signed-off-by: Peter Heise
    Signed-off-by: David S. Miller

    Peter Heise
     

24 Nov, 2015

1 commit


19 Aug, 2015

1 commit


02 Mar, 2015

1 commit

  • To repeat:

    $ sudo ip link del hsr0
    BUG: unable to handle kernel NULL pointer dereference at 0000000000000018
    IP: [] hsr_del_port+0x15/0xa0
    etc...

    Bug description:

    As part of the hsr master device destruction, hsr_del_port() is called for each of
    the hsr ports. At each such call, the master device is updated regarding features
    and mtu. When the master device is freed before the slave interfaces, master will
    be NULL in hsr_del_port(), which led to a NULL pointer dereference.

    Additionally, dev_put() was called on the master device itself in hsr_del_port(),
    causing a refcnt error.

    A third bug in the same code path was that the rtnl lock was not taken before
    hsr_del_port() was called as part of hsr_dev_destroy().

    The reporter (Nicolas Dichtel) also said: "hsr_netdev_notify() supposes that the
    port will always be available when the notification is for an hsr interface. It's
    wrong. For example, netdev_wait_allrefs() may resend NETDEV_UNREGISTER.". As a
    precaution against this, a check for port == NULL was added in hsr_dev_notify().

    Reported-by: Nicolas Dichtel
    Fixes: 51f3c605318b056a ("net/hsr: Move slave init to hsr_slave.c.")
    Signed-off-by: Arvid Brodin
    Signed-off-by: David S. Miller

    Arvid Brodin
     

12 Jul, 2014

1 commit


09 Jul, 2014

10 commits


28 Mar, 2014

1 commit

  • Use del_timer_sync to ensure that the timer is stopped on all CPUs before
    the driver exists.

    This change was suggested by Thomas Gleixner.

    The semantic patch that makes this change is as follows:
    (http://coccinelle.lip6.fr/)

    //
    @r@
    declarer name module_exit;
    identifier ex;
    @@

    module_exit(ex);

    @@
    identifier r.ex;
    @@

    ex(...) {

    }
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: David S. Miller

    Julia Lawall
     

06 Mar, 2014

1 commit

  • Conflicts:
    drivers/net/wireless/ath/ath9k/recv.c
    drivers/net/wireless/mwifiex/pcie.c
    net/ipv6/sit.c

    The SIT driver conflict consists of a bug fix being done by hand
    in 'net' (missing u64_stats_init()) whilst in 'net-next' a helper
    was created (netdev_alloc_pcpu_stats()) which takes care of this.

    The two wireless conflicts were overlapping changes.

    Signed-off-by: David S. Miller

    David S. Miller
     

04 Mar, 2014

1 commit


19 Feb, 2014

1 commit


18 Dec, 2013

1 commit


01 Dec, 2013

2 commits


20 Nov, 2013

4 commits

  • Register generic netlink multicast groups as an array with
    the family and give them contiguous group IDs. Then instead
    of passing the global group ID to the various functions that
    send messages, pass the ID relative to the family - for most
    families that's just 0 because the only have one group.

    This avoids the list_head and ID in each group, adding a new
    field for the mcast group ID offset to the family.

    At the same time, this allows us to prevent abusing groups
    again like the quota and dropmon code did, since we can now
    check that a family only uses a group it owns.

    Signed-off-by: Johannes Berg
    Signed-off-by: David S. Miller

    Johannes Berg
     
  • This doesn't really change anything, but prepares for the
    next patch that will change the APIs to pass the group ID
    within the family, rather than the global group ID.

    Signed-off-by: Johannes Berg
    Signed-off-by: David S. Miller

    Johannes Berg
     
  • There's no need to unregister the multicast group if the
    generic netlink family is registered immediately after.

    Signed-off-by: Johannes Berg
    Signed-off-by: David S. Miller

    Johannes Berg
     
  • As suggested by David Miller, make genl_register_family_with_ops()
    a macro and pass only the array, evaluating ARRAY_SIZE() in the
    macro, this is a little safer.

    The openvswitch has some indirection, assing ops/n_ops directly in
    that code. This might ultimately just assign the pointers in the
    family initializations, saving the struct genl_family_and_ops and
    code (once mcast groups are handled differently.)

    Signed-off-by: Johannes Berg
    Signed-off-by: David S. Miller

    Johannes Berg
     

15 Nov, 2013

3 commits


04 Nov, 2013

1 commit

  • High-availability Seamless Redundancy ("HSR") provides instant failover
    redundancy for Ethernet networks. It requires a special network topology where
    all nodes are connected in a ring (each node having two physical network
    interfaces). It is suited for applications that demand high availability and
    very short reaction time.

    HSR acts on the Ethernet layer, using a registered Ethernet protocol type to
    send special HSR frames in both directions over the ring. The driver creates
    virtual network interfaces that can be used just like any ordinary Linux
    network interface, for IP/TCP/UDP traffic etc. All nodes in the network ring
    must be HSR capable.

    This code is a "best effort" to comply with the HSR standard as described in
    IEC 62439-3:2010 (HSRv0).

    Signed-off-by: Arvid Brodin
    Signed-off-by: David S. Miller

    Arvid Brodin