Skip to content
  • Ihar Hrachyshka's avatar
    arp: always override existing neigh entries with gratuitous ARP · 7d472a59
    Ihar Hrachyshka authored
    
    
    Currently, when arp_accept is 1, we always override existing neigh
    entries with incoming gratuitous ARP replies. Otherwise, we override
    them only if new replies satisfy _locktime_ conditional (packets arrive
    not earlier than _locktime_ seconds since the last update to the neigh
    entry).
    
    The idea behind locktime is to pick the very first (=> close) reply
    received in a unicast burst when ARP proxies are used. This helps to
    avoid ARP thrashing where Linux would switch back and forth from one
    proxy to another.
    
    This logic has nothing to do with gratuitous ARP replies that are
    generally not aligned in time when multiple IP address carriers send
    them into network.
    
    This patch enforces overriding of existing neigh entries by all incoming
    gratuitous ARP packets, irrespective of their time of arrival. This will
    make the kernel honour all incoming gratuitous ARP packets.
    
    Signed-off-by: default avatarIhar Hrachyshka <ihrachys@redhat.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    7d472a59