git: if_bridge - Fix a broadcast issue, cleanup

Matthew Dillon dillon at crater.dragonflybsd.org
Sun Jul 24 17:32:19 PDT 2022


commit e672052697ff1ad625d860d54a17b2fdda12fb62
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Sun Jul 24 17:19:58 2022 -0700

    if_bridge - Fix a broadcast issue, cleanup
    
    * Fix a broadcast issue in bridge_output().  This routine takes packets
      originated on the machine that are sent to an interface that is part
      of the bridge.  These are NOT forwarded packets, but packets originated
      on the machine.
    
      For all intents and purposes, these packets are being sent to the bridge
      and the interface on the bridge that the system looked-up should not be
      treated specially.
    
    * This should fix issues with ARPs sometimes going into the bit-bucket.
    
    * Distinguish between interfaces that are part of the same bonded set
      (i.e. go to the same place) from round-robin vs backup mode.
    
      Previously there was some confusion as to whether the interfaces were
      distinct or not.  All interfaces on the bridge with the same MAC are
      considered to be bonded for the purposes of packet rejection when
      forwarding and masking when broadcasting.  i.e. the multiple end-points
      go between the same two end-points.  The mode is then determined by
      the ifpriority of the highest-priority interfaces.  If the ifpriority
      is different, backup mode is assumed.  If the ifpriority for the highest
      priority bonded set is the same, round-robin mode is assumed.
    
    * Clean-up documentation and adjust the syntax for multi-line if()
      statements for readability.
    
    * These fixes do not address potential issues with loops in the
      spanning tree yet.

Summary of changes:
 sbin/ifconfig/ifconfig.8   |  23 +-
 share/man/man4/bridge.4    |   6 +-
 sys/net/bridge/if_bridge.c | 543 +++++++++++++++++++++++++++------------------
 3 files changed, 348 insertions(+), 224 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/e672052697ff1ad625d860d54a17b2fdda12fb62


-- 
DragonFly BSD source repository


More information about the Commits mailing list