Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E2D56C27C76 for ; Sat, 28 Jan 2023 05:27:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231354AbjA1F0x (ORCPT ); Sat, 28 Jan 2023 00:26:53 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54742 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229464AbjA1F0w (ORCPT ); Sat, 28 Jan 2023 00:26:52 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DB7F47BE4D; Fri, 27 Jan 2023 21:26:50 -0800 (PST) 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 ams.source.kernel.org (Postfix) with ESMTPS id 76736B82200; Sat, 28 Jan 2023 05:26:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 85A9FC433EF; Sat, 28 Jan 2023 05:26:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1674883608; bh=Zv9RYztzmfeeUXtmsnWulZnltlTkGNR6OGOCm8FP0jg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=n+M/AtV17Yiuy8gEBnc+AbZE4OI6aigKaysU85tGqrvwFObicWiE/jusChPOJHB36 jmWtdvagYJKUgMYmbxsTmzB50YvCHy9vsRQgACVUHzBi+7H0EG5yiTymtWHsqEfryd pApEc5ncBKs2mz85wBCqlBFYk8rpXipN5ZfCo8Lll/3TXpZg64lBC7iG3xE4vhojVN cQtV1ppNv0CKiFgrv2j25pN6te4x9WHheI6UVMn/zoON8gA2ETwYX5x632B1xoBG2p tm+fv8RqhhQ7+ECY1npFh5kHEUYr0bbqwXOpGvq5nMuIap6etPlDte3VtYnN5YVuVJ phX2/m+HwdPWg== Date: Fri, 27 Jan 2023 21:26:46 -0800 From: Jakub Kicinski To: Yunsheng Lin Cc: Alexander Duyck , , , , , , , , , Subject: Re: [net PATCH] skb: Do mix page pool and page referenced frags in GRO Message-ID: <20230127212646.4cfeb475@kernel.org> In-Reply-To: References: <04e27096-9ace-07eb-aa51-1663714a586d@nbd.name> <167475990764.1934330.11960904198087757911.stgit@localhost.localdomain> 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 Sat, 28 Jan 2023 10:37:47 +0800 Yunsheng Lin wrote: > If we are not allowing gro for the above case, setting NAPI_GRO_CB(p)->flush > to 1 in gro_list_prepare() seems to be making more sense so that the above > case has the same handling as skb_has_frag_list() handling? > https://elixir.bootlin.com/linux/v6.2-rc4/source/net/core/gro.c#L503 > > As it seems to avoid some unnecessary operation according to comment > in tcp4_gro_receive(): > https://elixir.bootlin.com/linux/v6.2-rc4/source/net/ipv4/tcp_offload.c#L322 The frag_list case can be determined with just the input skb. For pp_recycle we need to compare input skb's pp_recycle with the pp_recycle of the skb already held by GRO. I'll hold off with applying a bit longer tho, in case Eric wants to chime in with an ack or opinion.