Skip to content
  • Eric Dumazet's avatar
    mlx5: support napi_complete_done() · 44fb6fbb
    Eric Dumazet authored
    
    
    A NAPI poll handler should return number of RX packets processed,
    instead of 0 / budget.
    
    This allows proper busy poll accounting through LINUX_MIB_BUSYPOLLRXPACKETS
    SNMP counter.
    
    napi_complete_done() allows /sys/class/net/ethX/gro_flush_timeout
    to be used for finer GRO aggregation control.
    
    Tested:
    
    Enabled busy polling, and checked TcpExtBusyPollRxPackets counter is increasing.
    
    echo 70 >/proc/sys/net/core/busy_read
    nstat >/dev/null
    netperf -H target -t TCP_RR >/dev/null
    nstat | grep TcpExtBusyPollRxPackets
    TcpExtBusyPollRxPackets         490958             0.0
    
    Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
    Cc: Eli Cohen <eli@mellanox.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    44fb6fbb