Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp5525660pxb; Wed, 26 Jan 2022 14:08:58 -0800 (PST) X-Google-Smtp-Source: ABdhPJwPVVQjR7+BHXQs0LjQlrIi6cL73r9wLZHnY/Zr3+3YASSZ4bIA5ie+wNG8Me/sNNMxLka8 X-Received: by 2002:a05:6402:5189:: with SMTP id q9mr1009817edd.314.1643234938352; Wed, 26 Jan 2022 14:08:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643234938; cv=none; d=google.com; s=arc-20160816; b=EgQtXZtctBmXnXxwLHbajD6K+C7r4hMtZrlcnahhG2nkmyYLElkDaMu4DsaC5vMTzS 6/2FIc+W2SqUEgTB4PeVyb+w7tFkSJ5PXnXRl8HYFyXvBArwo2a6rsOKNw6jXeUdvAPo nBh2jp0/FgLHJsqymrUWdKXNISbUzze45QrExhtFmmMU+3QTY/jps6n7KSHqt5mAtCdN l6d/FkSLuHsUt8Jf2pV3tfALkoTB0umLaMu6v5RES8gwNamqJKvWSaGSpiGilK5Vttbm BQpQEg1+jzXg6sPpua2CHGYVZ/kHWK+qMEshKeR//+dzEHdAx3MC/wii+tgn994uyh/M 1Z/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=66NhHqGSNwIr598usgnbVzBkRmjRxt7Ri2BGDgf0n4E=; b=rM1GQyYXGNMzWD7RSc85WUZ4944HKwuRjUZQp+sr2KtNXKyD8b+YJFqJXfu+EFne6W uIOJpn7Pd8l/PjehAj8rFumPq6P7QGn5YM4DnBp52QNvut1TjH/gFYa/I5I4EJmqEsyZ o/mk2R53LkcKdDOAjtTzsCVzIA+38fIhsN8q6ktnvD6C6qFF2FJpPJLLHa9enBph5lKh Dfw6w9Nf2Rqt8tDGd0J84leQbUz4RYspgDmtELMBsJRM4YmJQptj0GVweWAKp75gmeuF L1NBDh/+YVoT6hNJfShOZwt4fN4Hjm/ghcxk0mXzN+wctU+OrdqjRbq9f2tLNrG1+l5F 1HhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=kHwxw5x5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e1si227763ejm.628.2022.01.26.14.08.32; Wed, 26 Jan 2022 14:08:58 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=kHwxw5x5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229929AbiAZPwX (ORCPT + 99 others); Wed, 26 Jan 2022 10:52:23 -0500 Received: from dfw.source.kernel.org ([139.178.84.217]:35384 "EHLO dfw.source.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229645AbiAZPwW (ORCPT ); Wed, 26 Jan 2022 10:52:22 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0F7D061927 for ; Wed, 26 Jan 2022 15:52:22 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 072AEC340E3; Wed, 26 Jan 2022 15:52:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1643212341; bh=pDJ1n2o3tA01FOf1seMcoBl990OFnzTSM1jb7kUBkmA=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=kHwxw5x54kqArq5LM7anF8uiy/fNXEnjfAb89CRrPUn6hJeoCu94e34Js1XjBmZw1 Zcr6ObjuOPHWuqO/nuFZd0IKde8MTHqv6uUgm1fsvU7s+tmTXZx8RcjGgEBfZ2ZIEz Yk+IKeR2PbHBzU754oIf9qifEPI8x6MFOqrhDsR7HBPVScPLEL9IQgJbaV3wYC6iEG 5/6F8XDQ2J6vVTLRGU1u9Yj7zmG/tQ9VX/DMPuzObiQ7ftKu346cWX5+zPCYIDEOHF LxQmrHRhQYOWpY6LC+entG4YjvbqUIzaIC4y05Xevc5y+m7ys7ltNciNOuFPdbn45a Or76eHkBXm2RQ== Date: Wed, 26 Jan 2022 07:52:20 -0800 From: Jakub Kicinski To: Hyeonggon Yoo <42.hyeyoo@gmail.com> Cc: jwiedmann.dev@gmail.com, Shay Agroskin , Arthur Kiyanovski , David Arinzon , Noam Dagan , Saeed Bishara , "David S . Miller" , Daniel Borkmann , Sameeh Jubran , Wei Yongjun , Lorenzo Bianconi , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] net: ena: Do not waste napi skb cache Message-ID: <20220126075220.3d60981f@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net> In-Reply-To: References: <20220123115623.94843-1-42.hyeyoo@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 26 Jan 2022 13:16:41 +0000 Hyeonggon Yoo wrote: > By profiling, discovered that ena device driver allocates skb by > build_skb() and frees by napi_skb_cache_put(). Because the driver > does not use napi skb cache in allocation path, napi skb cache is > periodically filled and flushed. This is waste of napi skb cache. > > As ena_alloc_skb() is called only in napi, Use napi_build_skb() > and napi_alloc_skb() when allocating skb. > > This patch was tested on aws a1.metal instance. > > [ jwiedmann.dev@gmail.com: Use napi_alloc_skb() instead of > netdev_alloc_skb_ip_align() to keep things consistent. ] > > Signed-off-by: Hyeonggon Yoo <42.hyeyoo@gmail.com> It seems you missed CCing netdev@, you'll need to repost. You can keep the ack from Shay.