From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-we0-f176.google.com (mail-we0-f176.google.com [74.125.82.176]) by dpdk.org (Postfix) with ESMTP id 10AA7B3A4 for ; Wed, 17 Sep 2014 15:41:44 +0200 (CEST) Received: by mail-we0-f176.google.com with SMTP id q58so1454812wes.35 for ; Wed, 17 Sep 2014 06:47:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=s0KEOaCDcfhwpkpeALu7h2ccMszG6On5Js+m+6rJJWE=; b=TcYH2gEGu4i0QcQ1n98Vc0xkAD1mvXaO30L1nJonxdDgU8xJx8iDfMkEHDPizVfG6M OR2fxAcsmDDd4JYvZoKD7EZer6+inyq5RcoM6LqcXoFZP8cLBN1ymQpxuJQueudCzlM9 s6ORxX4n2yHP5hxYFE2/QQX6T9uT3UhWorlX+HXVmgt9vnpTOjsmsc6o0I13tl8SC0bd xnM154OnHlKEikjOYRgRLniBGRnGBw7qyK2LweS3g5oLf/QNymSY1qexk+AQDNkL2XSt hAxj6MdnvpjDbOIJGdFqOhE+rPmO0VJ7gHl1ES8oOb6FwTk8MoKqgF+DhagXfg9VjvUD EacQ== X-Gm-Message-State: ALoCoQniHyw1ge5kn3M9EsLiN+1fnc9Z66OQaznq3IMxWwzcNzUmWlo5yQoUTIGBaBIczbtbG8F6 X-Received: by 10.180.183.133 with SMTP id em5mr40679172wic.72.1410961644084; Wed, 17 Sep 2014 06:47:24 -0700 (PDT) Received: from alcyon.dev.6wind.com (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by mx.google.com with ESMTPSA id fa20sm5712872wic.1.2014.09.17.06.47.22 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Sep 2014 06:47:23 -0700 (PDT) From: David Marchand To: dev@dpdk.org Date: Wed, 17 Sep 2014 15:46:45 +0200 Message-Id: <1410961612-8571-14-git-send-email-david.marchand@6wind.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1410961612-8571-1-git-send-email-david.marchand@6wind.com> References: <1410961612-8571-1-git-send-email-david.marchand@6wind.com> Subject: [dpdk-dev] [PATCH v3 13/20] i40e: add log messages when rx bulk mode is not usable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Sep 2014 13:41:44 -0000 Signed-off-by: David Marchand Acked-by: Bruce Richardson --- lib/librte_pmd_i40e/i40e_rxtx.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/lib/librte_pmd_i40e/i40e_rxtx.c b/lib/librte_pmd_i40e/i40e_rxtx.c index 22f9fd5..481ebed 100644 --- a/lib/librte_pmd_i40e/i40e_rxtx.c +++ b/lib/librte_pmd_i40e/i40e_rxtx.c @@ -537,15 +537,34 @@ check_rx_burst_bulk_alloc_preconditions(__rte_unused struct i40e_rx_queue *rxq) int ret = 0; #ifdef RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC - if (!(rxq->rx_free_thresh >= RTE_PMD_I40E_RX_MAX_BURST)) + if (!(rxq->rx_free_thresh >= RTE_PMD_I40E_RX_MAX_BURST)) { + PMD_INIT_LOG(DEBUG, "Rx Burst Bulk Alloc Preconditions: " + "rxq->rx_free_thresh=%d, " + "RTE_PMD_I40E_RX_MAX_BURST=%d", + rxq->rx_free_thresh, RTE_PMD_I40E_RX_MAX_BURST); ret = -EINVAL; - else if (!(rxq->rx_free_thresh < rxq->nb_rx_desc)) + } else if (!(rxq->rx_free_thresh < rxq->nb_rx_desc)) { + PMD_INIT_LOG(DEBUG, "Rx Burst Bulk Alloc Preconditions: " + "rxq->rx_free_thresh=%d, " + "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", + rxq->nb_rx_desc, rxq->rx_free_thresh); ret = -EINVAL; - else if (!(rxq->nb_rx_desc < (I40E_MAX_RING_DESC - - RTE_PMD_I40E_RX_MAX_BURST))) + } else if (!(rxq->nb_rx_desc < (I40E_MAX_RING_DESC - + RTE_PMD_I40E_RX_MAX_BURST))) { + PMD_INIT_LOG(DEBUG, "Rx Burst Bulk Alloc Preconditions: " + "rxq->nb_rx_desc=%d, " + "I40E_MAX_RING_DESC=%d, " + "RTE_PMD_I40E_RX_MAX_BURST=%d", + rxq->nb_rx_desc, I40E_MAX_RING_DESC, + RTE_PMD_I40E_RX_MAX_BURST); ret = -EINVAL; + } #else ret = -EINVAL; #endif -- 1.7.10.4