1. 05 Jun, 2014 33 commits
  2. 04 Jun, 2014 7 commits
    • David S. Miller's avatar
      Merge branch 'bonding-macvlan' · 6579867c
      David S. Miller authored
      Vlad Yasevich says:
      
      ====================
      Fix support for macvlan devices on top bonding
      
      Currently, macvlan devices do not work well over bond interfaces.
      Everything works well, untill a failover is triggered in the bond
      device and then macvlan becomes unreachble untill arp entries
      are flushed.   This series adds needed functionality to
      handle correct notifications and update switches with mac addresses
      assigned to macvlans.
      
      The first patch simply addes IFF_UNICAST_FLT flag to bonds since they
      already correctly manage the unicast filter list of the slaves, so
      we might as well prevent the bond from needlessly going into promiscuous
      mode.
      
      The second patch adds notifier handler to macvlan to trigger correct
      ARP notifications.
      
      The third patch adds handling for TLB and RLB modes that use special
      ETH_P_LOOPBACK type packets to teach switch about mac addresses.
      It also allow ARPs for the macvlan mac addresses to be handled by
      RLB mode.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6579867c
    • Vlad Yasevich's avatar
      bonding: Support macvlans on top of tlb/rlb mode bonds · 14af9963
      Vlad Yasevich authored
      To make TLB mode work, the patch allows learning packets
      to be sent using mac addresses assigned to macvlan devices,
      also taking into an account vlans that may be between the
      bond and macvlan device.
      
      To make RLB work, all we have to do is accept ARP packets
      for addresses added to the bond dev->uc list.  Since RLB
      mode will take care to update the peers directly with
      correct mac addresses, learning packets for these addresses
      do not have be send to switch.
      Signed-off-by: default avatarVlad Yasevich <vyasevic@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      14af9963
    • Vlad Yasevich's avatar
      macvlan: Support bonding events · 4c991255
      Vlad Yasevich authored
      Bonding and team drivers generate specific events during failover
      that trigger switch updates.  When a macvlan device is configured
      on top of bonding, we want switches to learn about the macvlan
      devices as well.   This patch adds a handler to macvlan driver to
      propagate these events to all macvlan devices.  We let the generic
      inetdev event handler do the work.
      
      This allows macvlan to operated correctly over active-backup
      mode bond.
      Signed-off-by: default avatarVlad Yasevich <vyasevic@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4c991255
    • Vlad Yasevich's avatar
      bonding: Turn on IFF_UNICAST_FLT on bond devices · c565b488
      Vlad Yasevich authored
      Bonding devices manage the unicast filters of the underlying
      interfaces, but do not turn on IFF_UNICAST_FLT flag.  Thus
      anytime a unicast address is added to the bond, the bond is
      places in promiscuous mode.
      
      Turn on IFF_UNICAST_FLT on the bond device so that the bond does
      not go into promiscuous mode needlesly.  If an underlying device
      does not support unicast filtering, that device will automaticall
      enter promiscuous mode already.
      Signed-off-by: default avatarVlad Yasevich <vyasevic@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c565b488
    • Sasha Levin's avatar
      net: Revert "fib_trie: use seq_file_net rather than seq->private" · f830b022
      Sasha Levin authored
      This reverts commit 30f38d2f.
      
      fib_triestat is surrounded by a big lie: while it claims that it's a
      seq_file (fib_triestat_seq_open, fib_triestat_seq_show), it isn't:
      
      	static const struct file_operations fib_triestat_fops = {
      	        .owner  = THIS_MODULE,
      	        .open   = fib_triestat_seq_open,
      	        .read   = seq_read,
      	        .llseek = seq_lseek,
      	        .release = single_release_net,
      	};
      
      Yes, fib_triestat is just a regular file.
      
      A small detail (assuming CONFIG_NET_NS=y) is that while for seq_files
      you could do seq_file_net() to get the net ptr, doing so for a regular
      file would be wrong and would dereference an invalid pointer.
      
      The fib_triestat lie claimed a victim, and trying to show the file would
      be bad for the kernel. This patch just reverts the issue and fixes
      fib_triestat, which still needs a rewrite to either be a seq_file or
      stop claiming it is.
      Signed-off-by: default avatarSasha Levin <sasha.levin@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f830b022
    • Antonio Ospite's avatar
      trivial: drivers/net/ethernet/nvidia/forcedeth.c: fix typo s/SUBSTRACT1/SUBTRACT1/ · cef33c81
      Antonio Ospite authored
      Signed-off-by: default avatarAntonio Ospite <ao2@ao2.it>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Alexander Gordeev <agordeev@redhat.com>
      Cc: netdev@vger.kernel.org
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      cef33c81
    • Xiubo Li's avatar
      gianfar: Fix the section mismatch warnings. · 898157ed
      Xiubo Li authored
      Building with CONFIG_DEBUG_SECTION_MISMATCH enabled, the following
      WARNING is occured:
      
        LD      drivers/net/built-in.o
      WARNING: drivers/net/built-in.o(.text+0xcd4c): Section mismatch in
      reference from the function gfar_probe() to the function
      .init.text:gfar_init_addr_hash_table()
      The function gfar_probe() references
      the function __init gfar_init_addr_hash_table().
      This is often because gfar_probe lacks a __init
      annotation or the annotation of gfar_init_addr_hash_table is wrong.
      Signed-off-by: default avatarXiubo Li <Li.Xiubo@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      898157ed