Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp131081pxb; Mon, 31 Jan 2022 17:17:11 -0800 (PST) X-Google-Smtp-Source: ABdhPJzRBOj6C8EaPBznKzdwseEYcK0R0plO5Sl9pUAryMCR/Z1pOCrru+hV/uzuIiakzn8N4T/v X-Received: by 2002:a17:907:a089:: with SMTP id hu9mr19505873ejc.680.1643678231326; Mon, 31 Jan 2022 17:17:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643678231; cv=none; d=google.com; s=arc-20160816; b=hvuPpK6RrZAXNbUlDL6MjWVdqYVHvQWd6RPGCuBsUA2bOmeim6c/InovwdSUBMfwrq 8zjqKIhmyR1CiBTmpcHPdmE3GJMBuFo3GMrKg+C6PJbEgeI6HKtTlUKsT66se+2Tdymp TbVQ8Iq7LnNyRgO7ClViXhrAfcNKlBhl/DhdaRhOI7a6CBlG20hDiiAKcyZsIxgkB8Hw a9eI4vfNa1doqYyHdF/Yg7UjAFPO9JilCQU1k34rHSZOTW7/j3tcx3RKY7bxp/3tRkrm I+YD8LQ3zcab5nfdJRDdX3elWKm2bvFwK9VMrRPe/E7j89psoKYlLHohfO57CtvxVZj1 qDcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=xn/qJjrrzAvXyxtE1CdQaJrstqcp2JmG2KjRcr5IUNk=; b=U6d/LpjCuHNRIfjnogMqp/VdDrLZubQxndRsOqAA1fCkF5Ec+3uGxljehx2iL7QlZ9 CvbHkZBOdSHiRdV5Zsk5S7rirZFDnUTYs8ZuQcKRAlFeSkLyAz35lM1twedz3RBt/Krd q2V2uZ3Dbl9g5z/+ARuz6sJ9Sys0BbBGz/9uzC3yEJNjFvCT4IaWMm+eVYqz4cs2Y75l YI/bGx+o0bXLBD1EmC4TqDalShXv6epqXYcwK4PWvt/0WIild6L2oHvS1ul8UH2ttQq3 GI8ml1dJMmdJ8L2QfTrEcgacLp6WEZKbvjxN7BzT3m0NUsWzGNBHpo7WSDjcufI1nZiz XrYQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=S0kRGrUd; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m4si9500152edc.421.2022.01.31.17.16.46; Mon, 31 Jan 2022 17:17:11 -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=@gmail.com header.s=20210112 header.b=S0kRGrUd; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229905AbiA2I4j (ORCPT + 99 others); Sat, 29 Jan 2022 03:56:39 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229505AbiA2I4d (ORCPT ); Sat, 29 Jan 2022 03:56:33 -0500 Received: from mail-pj1-x1036.google.com (mail-pj1-x1036.google.com [IPv6:2607:f8b0:4864:20::1036]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 15802C061714; Sat, 29 Jan 2022 00:56:33 -0800 (PST) Received: by mail-pj1-x1036.google.com with SMTP id qe6-20020a17090b4f8600b001b7aaad65b9so2531282pjb.2; Sat, 29 Jan 2022 00:56:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=xn/qJjrrzAvXyxtE1CdQaJrstqcp2JmG2KjRcr5IUNk=; b=S0kRGrUdtb6+O2XoqCMR9FNw3hpDGFKxPXATSEXGU+XfskCh8+j9ORGhSHIMzKMMtv Li0Lg7IMCesd4TLZsMs5JILyAwj0FHEotg4MmdUU5n7ZqDrRNiw5DETsMuVqyDOUnLWM Xdzy6k+Y2koQXMZfQ0h7IfCVIii5m7QVX5cAiqGAiu24MeDRn8xSMRLm/EN0YFhtO18x BgEHDJGC4uwZ8OD4N6EXdrAqH5rJkSUnsAQhz5BuHCAZ5cb8pV1V+mERuU5Tb990wgq3 cs5mq+U27oZ0vr6zsrh8j/TGNvRmxr0StAYbsmw40lMB+OahKrA50E183izk5cL176O+ mY3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=xn/qJjrrzAvXyxtE1CdQaJrstqcp2JmG2KjRcr5IUNk=; b=qDF1OGO3iyiCHA6+eQGc0R7bt8IURYsq8s3+qLGUXiFx0t5j3H0BM/P1NF4CO7UIYv s5+JqaFfS1slG+gNzSNvMt0xCvJ+r26napIM7sKvGOoGTE2yul/aIT9AMNIzAX/6T3rm ap8Vq1vhe3BBvbllw2a0a1LNw4pOOstuQW5ZzFmi4jBWGXULbtwSPILPsCnoBYWaSl5j LC/CEj+a2BT0kujAnsabvMcHT5S2fI+NQTQiHA91WMHYJtJyRf8yBOTxe+A8anjpKt9M feslXbY0fjCQIQs3ul0iOXKYwD50m9K8mt0n0C0Kulsa4FqHl6w933ipDyblSxk0FW0I cw2A== X-Gm-Message-State: AOAM533owZKP69em4qDSiq498fQ8/Kg7EVOFVYFwyossiXvwfxo4YD0k SFPwGsmLZ9eAYtepZZ72dnY= X-Received: by 2002:a17:90a:d58d:: with SMTP id v13mr14098494pju.210.1643446592611; Sat, 29 Jan 2022 00:56:32 -0800 (PST) Received: from ip-172-31-19-208.ap-northeast-1.compute.internal (ec2-18-181-137-102.ap-northeast-1.compute.amazonaws.com. [18.181.137.102]) by smtp.gmail.com with ESMTPSA id d9sm11830687pfl.69.2022.01.29.00.56.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Jan 2022 00:56:32 -0800 (PST) Date: Sat, 29 Jan 2022 08:56:27 +0000 From: Hyeonggon Yoo <42.hyeyoo@gmail.com> To: Julian Wiedmann Cc: Shay Agroskin , netdev@vger.kernel.org, Arthur Kiyanovski , David Arinzon , Noam Dagan , Saeed Bishara , "David S . Miller" , Jakub Kicinski , Daniel Borkmann , Wei Yongjun , Lorenzo Bianconi , linux-kernel@vger.kernel.org Subject: Re: [PATCH] net: ena: Do not waste napi skb cache Message-ID: References: <20220123115623.94843-1-42.hyeyoo@gmail.com> <5cca8bdd-bed0-f26a-6c96-d18947d3a50b@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 25, 2022 at 03:50:30PM +0200, Julian Wiedmann wrote: > On 25.01.22 11:34, Hyeonggon Yoo wrote: > > On Mon, Jan 24, 2022 at 10:50:05PM +0200, Shay Agroskin wrote: > >> > > [...] > > >> > >> I agree that the netdev_alloc_skb_ip_align() can become napi_alloc_skb(). > >> Hyeonggon Yoo, can you please apply this change as well to this patch? > >> > > > > Okay. I'll update and test it again. > > > > BTW, It seems netdev_alloc_skb_ip_align() is used to make some fields > > be aligned. It's okay to just ignore this? > > > > napi_alloc_skb() adds NET_IP_ALIGN internally, so you end up with the same alignment as before. > Oh I was missing that. I updated the patch and tested again. Thank you! > > > Thanks, > > Hyeonggon. > > > >> Thanks, > >> Shay > >> > >> > >>>>> else > >>>>> - skb = build_skb(first_frag, ENA_PAGE_SIZE); > >>>>> + skb = napi_build_skb(first_frag, ENA_PAGE_SIZE); > >>>>> if (unlikely(!skb)) { > >>>>> ena_increase_stat(&rx_ring->rx_stats.skb_alloc_fail, 1, > >>>> >