From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-f171.google.com (mail-wi0-f171.google.com [209.85.212.171]) by dpdk.org (Postfix) with ESMTP id 9AE15C3C2 for ; Sun, 26 Apr 2015 16:46:22 +0200 (CEST) Received: by widdi4 with SMTP id di4so71852412wid.0 for ; Sun, 26 Apr 2015 07:46:22 -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=qkf48JtgnqN6P7BWDfBg7KBxx705Ayr9mqeVMdOVAfY=; b=FAV4EJEnXpca2LivF733kZauH4Wd1B0S+SKt1lTyzDH5ZMdGOWp3oKwuA5zWyK0Xme NtQt9dDHvSKHM1w9NYvdESahMd5+GZp8Mj+i7TJLLALxO5+POY2MfNDdJLzx47GJuWyU zemxSqx2WG6Xi3NVfzVI85Uez/aL2ImtsB/mbM8Nt+OWUkMXQCHr5h2Mh3LQ9KROrQSy ETZzPesr1ge+AxI9t38jJ7yuroq8ogSuduSkztrklveR1xkQ8phSDMK2BZ7XoMUSNKve u/dUG6JJ3Z0DsRxvscchH5oAdKbWNLWg5V1iV7u+Bj8Nq17iBMlu7JRgsEOwvmXWH33N 6RFg== X-Gm-Message-State: ALoCoQlk11x8D+HYJi61/w1iPV93HWtKWeAEmfVz0IBJ5OMZuH8ikf5HVdTG18mYhMWk4MyPjzZR X-Received: by 10.180.88.72 with SMTP id be8mr13148731wib.45.1430059582551; Sun, 26 Apr 2015 07:46:22 -0700 (PDT) Received: from vladz-laptop.cloudius-systems.com. ([212.143.139.214]) by mx.google.com with ESMTPSA id gy8sm7595913wib.13.2015.04.26.07.46.21 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 26 Apr 2015 07:46:22 -0700 (PDT) From: Vlad Zolotarov To: dev@dpdk.org Date: Sun, 26 Apr 2015 17:46:11 +0300 Message-Id: <1430059571-20843-5-git-send-email-vladz@cloudius-systems.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1430059571-20843-1-git-send-email-vladz@cloudius-systems.com> References: <1430059571-20843-1-git-send-email-vladz@cloudius-systems.com> Subject: [dpdk-dev] [PATCH v1 4/4] ixgbe: Add support for scattered Rx with bulk allocation. 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: Sun, 26 Apr 2015 14:46:22 -0000 Simply initialze rx_pkt_burst callback to ixgbe_recv_pkts_lro_bulk_alloc() if the conditions are right. This is possible because work against HW in LRO and scattered cases is exactly the same and LRO callback already supports the bulk allocation. Signed-off-by: Vlad Zolotarov --- lib/librte_pmd_ixgbe/ixgbe_rxtx.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c index c23e20f..6addc41 100644 --- a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c +++ b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c @@ -3783,6 +3783,11 @@ void ixgbe_set_rx_function(struct rte_eth_dev *dev) dev->data->port_id); dev->rx_pkt_burst = ixgbe_recv_scattered_pkts_vec; + } else if (adapter->rx_bulk_alloc_allowed) { + PMD_INIT_LOG(INFO, "Using a Scattered with bulk " + "allocation callback (port=%d).", + dev->data->port_id); + dev->rx_pkt_burst = ixgbe_recv_pkts_lro_bulk_alloc; } else { PMD_INIT_LOG(DEBUG, "Using Regualr (non-vector, " "single allocation) " -- 2.1.0