From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f47.google.com (mail-wm0-f47.google.com [74.125.82.47]) by dpdk.org (Postfix) with ESMTP id 408C81B5F2 for ; Tue, 7 Nov 2017 09:43:40 +0100 (CET) Received: by mail-wm0-f47.google.com with SMTP id r68so1977367wmr.1 for ; Tue, 07 Nov 2017 00:43:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=MQ/baLu01uiWQNRAAyiH/1kADnjuwQ02CcnZVke+Lc0=; b=UL1B0x8+9B+4g82Ea+BjRK6SzUnsxv8xnTRQXvYhcemXzvsCgcsAfjgNZz4x6jhFnm qSrBN2IZ70hTUshP/jDe9wm4IPc0Lh2GGElZfZ+nFWovfaPmQejwpjm3ULAx7Z24hQQP 33OG4AGd+Om/ELJQa3SalWv8ZiOg3FmGDlsQtkVoCmmztPrQfjqPjbC6OCMo8ge9KbkT WIvoYjHLPgvHmdu6L4LSoRAjGsM124qnMtnCZFHAFPp30vSSAvJy6XaRvy82msXy0DJT Z9ueiUq3OoOKpK6iRVjql5+hLYaO0gIqlSEMhBZfdl03Iv9ALYH0Ko7/Q/VjsFB5kWbC URSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=MQ/baLu01uiWQNRAAyiH/1kADnjuwQ02CcnZVke+Lc0=; b=TEPIrsWuXgt6HAUUgd36JTCkcJNm4IX4rhnjg48A527N5rZvvg48V1FNPm3EKs/TKr 75JKpwxqFr2ZCHxOSelIgCgshtfk/4dwnSr1SsBEyMhc6WITC4DJZPdkXrnMVS8PzZgg fZC/ySZrkW1FHmW2uAIctjgHf5N4w8GSf+dQmOVe2rLNffZY+c6ziDh+ACuQEqfmeD0B a2qpZEDfNk6S6VgcGkUCzF1reHbfks27ws2gc2inNQ4PE6bb/OqhCYk2zkD4CemqVqIB iesQ4IXWeHqDpbwxRFbGDK5EeusHCiMCal+e1vZD6WxJSA9d1jud/qaMy5ha070MFcsi 9Gcw== X-Gm-Message-State: AMCzsaVg6ee4fGVZAFaZWnH0czwu0jxLYsDqeTR1n9l47ZPXfvk3R1t0 QmPXoGZf34a9Hd+ufL/ph8QZVw== X-Google-Smtp-Source: ABhQp+SFiZ1jGBQ2BMmACORIiaWhIvOkN8EjpGwsJiLAZM0LczbXz+VHTpBx9i4xxInUekRWG3LZsg== X-Received: by 10.80.148.44 with SMTP id p41mr23624832eda.171.1510044219951; Tue, 07 Nov 2017 00:43:39 -0800 (PST) Received: from 6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id m8sm790907edl.74.2017.11.07.00.43.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 07 Nov 2017 00:43:39 -0800 (PST) Date: Tue, 7 Nov 2017 09:43:27 +0100 From: Adrien Mazarguil To: Moti Haimovsky Cc: dev@dpdk.org Message-ID: <20171107084327.GC24849@6wind.com> References: <1509902816-26299-1-git-send-email-motih@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1509902816-26299-1-git-send-email-motih@mellanox.com> Subject: Re: [dpdk-dev] [PATCH v4] net/mlx4: enhance Rx packet type offloads X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Nov 2017 08:43:40 -0000 On Sun, Nov 05, 2017 at 07:26:56PM +0200, Moti Haimovsky wrote: > This patch enhances the Rx packet type offload to also report the L4 > protocol information in the hw ptype filled by the PMD for each received > packet. > > Signed-off-by: Moti Haimovsky Patch looks fine therefore: Acked-by: Adrien Mazarguil Although in the end you didn't initialize mlx4_ptype_table[] using a loop (went all the way back to static array initialization) and I'm still wondering why since you never replied on that topic. Another comment: please remember to send patch updates as replies to their previous iteration. If you search for "enhance Rx packet type offloads" in [1], you notice they're not part of the same thread. While minor this doesn't help the review process. Regarding your previous reply about mlx4_dev_supported_ptypes_get(): [...] > > > + > > > + if (dev->rx_pkt_burst == mlx4_rx_burst) > > > + return ptypes; > > > + return NULL; > > > > How about just returning the array regardless? > > From DPDK documentation (and as done in other drivers): > http://dpdk.org/doc/api/rte__ethdev_8h.html#aa63202d322632467f9cc5fc460e04ea4 > Note > Better to invoke this API after the device is already started or rx burst > function is decided, to obtain correct supported ptypes. > if a given PMD does not report what ptypes it supports, then the supported > ptype count is reported as 0. > > In our case rx_pkt_burst can also point to mlx4_rx_burst_removed Right, and it doesn't hurt. My point was that mlx4_rx_burst_removed() is set as a safety when closing/stopping the device, no more Rx in that case. The mlx4 PMD currently exposes a single Rx function which does support everything, not multiple optimized ones with fewer capabilities, which is the actual reason behind checking the current Rx function. [1] http://dpdk.org/ml/archives/dev/2017-November/ -- Adrien Mazarguil 6WIND