Skip to content

Commit

Permalink
net/i40e: fix unchecked Tx cleanup error
Browse files Browse the repository at this point in the history
[ upstream commit ba950e6 ]

Coverity complains of unchecked return value warning of
i40e_xmit_cleanup, while this cleanup is opportunistic and will not
cause problems if it fails. So instead of checking the return value of
i40e_xmit_cleanup and return in case of cleanup failure, we directly
cast it to void function to make the Coverity happy.

Coverity issue: 353617
Fixes: 4861cde ("i40e: new poll mode driver")

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Xiaolong Ye <xiaolong.ye@intel.com>
  • Loading branch information
beileix authored and kevintraynor committed Feb 19, 2020
1 parent b0edd24 commit ef6860f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/i40e/i40e_rxtx.c
Expand Up @@ -1052,7 +1052,7 @@ i40e_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)

/* Check if the descriptor ring needs to be cleaned. */
if (txq->nb_tx_free < txq->tx_free_thresh)
i40e_xmit_cleanup(txq);
(void)i40e_xmit_cleanup(txq);

for (nb_tx = 0; nb_tx < nb_pkts; nb_tx++) {
td_cmd = 0;
Expand Down

0 comments on commit ef6860f

Please sign in to comment.