• Eric Dumazet's avatar
    neigh: reduce arp latency · cd28ca0a
    Eric Dumazet authored
    Remove the artificial HZ latency on arp resolution.
    
    Instead of firing a timer in one jiffy (up to 10 ms if HZ=100), lets
    send the ARP message immediately.
    
    Before patch :
    
    # arp -d 192.168.20.108 ; ping -c 3 192.168.20.108
    PING 192.168.20.108 (192.168.20.108) 56(84) bytes of data.
    64 bytes from 192.168.20.108: icmp_seq=1 ttl=64 time=9.91 ms
    64 bytes from 192.168.20.108: icmp_seq=2 ttl=64 time=0.065 ms
    64 bytes from 192.168.20.108: icmp_seq=3 ttl=64 time=0.061 ms
    
    After patch :
    
    $ arp -d 192.168.20.108 ; ping -c 3 192.168.20.108
    PING 192.168.20.108 (192.168.20.108) 56(84) bytes of data.
    64 bytes from 192.168.20.108: icmp_seq=1 ttl=64 time=0.152 ms
    64 bytes from 192.168.20.108: icmp_seq=2 ttl=64 time=0.064 ms
    64 bytes from 192.168.20.108: icmp_seq=3 ttl=64 time=0.074 ms
    Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    cd28ca0a
neighbour.c 67.9 KB