[dpdk-dev] [PATCH v2] i40e: fix build with gcc 5
Ananyev, Konstantin
konstantin.ananyev at intel.com
Thu Feb 19 12:41:11 CET 2015
> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Panu Matilainen
> Sent: Thursday, February 19, 2015 11:21 AM
> To: dev at dpdk.org
> Subject: [dpdk-dev] [PATCH v2] i40e: fix build with gcc 5
>
> Eliminate ambiguity in the condition which trips up a "logical not
> is only applied to the left..." warning from gcc 5, causing build
> failure with -Werror. Besides non-ambiguous, the condition is
> far more obvious this way.
>
> Signed-off-by: Panu Matilainen <pmatilai at redhat.com>
> ---
> lib/librte_pmd_i40e/i40e_rxtx.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lib/librte_pmd_i40e/i40e_rxtx.c b/lib/librte_pmd_i40e/i40e_rxtx.c
> index c9f1026..12c0831 100644
> --- a/lib/librte_pmd_i40e/i40e_rxtx.c
> +++ b/lib/librte_pmd_i40e/i40e_rxtx.c
> @@ -613,7 +613,7 @@ check_rx_burst_bulk_alloc_preconditions(__rte_unused struct i40e_rx_queue *rxq)
> "rxq->nb_rx_desc=%d",
> rxq->rx_free_thresh, rxq->nb_rx_desc);
> ret = -EINVAL;
> - } else if (!(rxq->nb_rx_desc % rxq->rx_free_thresh) == 0) {
> + } else if (rxq->nb_rx_desc % rxq->rx_free_thresh != 0) {
> PMD_INIT_LOG(DEBUG, "Rx Burst Bulk Alloc Preconditions: "
> "rxq->nb_rx_desc=%d, "
> "rxq->rx_free_thresh=%d",
> --
Acked-by: Konstantin Ananyev <konstantin.ananyev at intel.com>
> 2.1.0
More information about the dev
mailing list