• Tariq Toukan's avatar
    net/mlx4_en: Refactor mlx4_en_free_tx_desc · 4c07c132
    Tariq Toukan authored
    Some code re-ordering, functionally equivalent.
    
    - The !tx_info->inl check is evaluated anyway in both flows
      (common case/end case). Run it first, this might finish
      the flows earlier.
    - dma_unmap calls are identical in both flows, get it out
      of the if block into the common area.
    
    Performance tests:
    Tested on ConnectX3Pro, Intel(R) Xeon(R) CPU E5-2680 v3 @ 2.50GHz
    
    Gain is too small to be measurable, no degradation sensed.
    Results are similar for IPv4 and IPv6.
    Signed-off-by: default avatarTariq Toukan <tariqt@mellanox.com>
    Reviewed-by: default avatarSaeed Mahameed <saeedm@mellanox.com>
    Cc: kernel-team@fb.com
    Cc: Eric Dumazet <edumazet@google.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    4c07c132
en_tx.c 31.4 KB