From patchwork Thu Feb 3 15:48:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Abeni X-Patchwork-Id: 12734294 X-Patchwork-Delegate: kuba@kernel.org 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 9208DC433F5 for ; Thu, 3 Feb 2022 15:48:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351967AbiBCPsp (ORCPT ); Thu, 3 Feb 2022 10:48:45 -0500 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:57877 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351951AbiBCPsm (ORCPT ); Thu, 3 Feb 2022 10:48:42 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1643903322; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EIjAmUx69A5OyubPPVEtpS/29f9h1we0607QgH7kyVM=; b=eZ8WNL8+q6Et+e8raMvaPuVDFxfGKAJvFdIEn1gPwr0X71GRtp2KcpuuGKF/ugWgfQzoCG 67zRvLkI82IF+jNTuwVjbvZEcPshND/1sotC6Z196YdMqlGYMb7y7K0UZfBzyunYL6Qq6y mWsAb+SNJKFMWtUjXOgs41rT7obr+Co= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-296-oktbuJHFPNyQLTJOcTRXdg-1; Thu, 03 Feb 2022 10:48:38 -0500 X-MC-Unique: oktbuJHFPNyQLTJOcTRXdg-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id A0500190B2A0; Thu, 3 Feb 2022 15:48:36 +0000 (UTC) Received: from gerbillo.redhat.com (unknown [10.39.193.191]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0CE0C10841E4; Thu, 3 Feb 2022 15:48:34 +0000 (UTC) From: Paolo Abeni To: netdev@vger.kernel.org Cc: "David S. Miller" , Jakub Kicinski , Alexander Lobakin , Eric Dumazet Subject: [PATCH net-next 1/3] net: gro: avoid re-computing truesize twice on recycle Date: Thu, 3 Feb 2022 16:48:21 +0100 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org After commit 5e10da5385d2 ("skbuff: allow 'slow_gro' for skb carring sock reference") and commit af352460b465 ("net: fix GRO skb truesize update") the truesize of freed skb is properly updated by the GRO engine, we don't need anymore resetting it at recycle time. Signed-off-by: Paolo Abeni --- net/core/gro.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/core/gro.c b/net/core/gro.c index a11b286d1495..d43d42215bdb 100644 --- a/net/core/gro.c +++ b/net/core/gro.c @@ -634,7 +634,6 @@ static void napi_reuse_skb(struct napi_struct *napi, struct sk_buff *skb) skb->encapsulation = 0; skb_shinfo(skb)->gso_type = 0; - skb->truesize = SKB_TRUESIZE(skb_end_offset(skb)); if (unlikely(skb->slow_gro)) { skb_orphan(skb); skb_ext_reset(skb);