Received: by 2002:ab2:6309:0:b0:1fb:d597:ff75 with SMTP id s9csp848849lqt; Thu, 6 Jun 2024 23:35:57 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWzLjVNeNI9+NTT3mXhP5iHBGtc9lN9Q7XInGAVqYpVKMBNqfgy4HltN1MNbCwedj4TH4xt9BnpOEH9XHdrwZyQ0jfaTOX9JRXi4NHUFw== X-Google-Smtp-Source: AGHT+IETVnckeminvXnunAbr/DD0S7PMSf56QaCoK00dI6LPZIFLh34z4McjYeqcpHrivKtFgmyA X-Received: by 2002:a17:907:7295:b0:a69:1122:7c51 with SMTP id a640c23a62f3a-a6cdc0e7a1fmr141561566b.75.1717742157598; Thu, 06 Jun 2024 23:35:57 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717742157; cv=pass; d=google.com; s=arc-20160816; b=OYr41vGUXhll5CijT/S4lg3Cfb+naXOB4PlLteuEJoKKNl6CUcCtkqnXJCo5c+SutW 4Zmp7ybARfZWMR7s6EX3xCZga4vXlh1rE1S+oHnMnQHjhbrJCSwC45DlzBGqJmtZlWOV Mk79zdwZTgQEWddA1JDGfqN5bommVlTyXYKFX6fOACzpyi5KH/biBWZCGrvNLf4dCo5r w4ZSMUMDL0ZrSktVMJvZJ4uU6Pd7bhnfUcux2a68+ESrWj6VOBbti/Lz2V6y8cNrVHfK jPCuf87X8ztwi/qMGdfpMGCpeZFOdCDef3zWqn8JX2yW/X149KCz6brqujfmCClK2fuV 90fw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=vsF9fVM1//kd5zIx0GTtpB46iJMt9vsqNkPX4bd/w5Y=; fh=mRLY5DT8UT+hQIqU4RxbbxuLP46pwxb/BXyqE3w4Fjg=; b=F/OGj1QQM9BfqZegKlJJME0hJDYGecTZy0knVlwi+DRXw3JLdDNwMj7hZxw3w1QX/D 9FkpCJRigR4jmdplQ3z9FFCp3iEdzQJxksehu0+1SBd9fOg0aAsUU178dATmeaxVDz25 hCWVPKpzpCGYzXOlYASQB4gvYsfIeqN94GprOcM68iFNh1gHu3NI/xahNj/vYLFYm+4b TSOhI1NlSGhNOfnPWRfuggcvTr3pGLUJclvTKiEYE/3cXVQA4l220dJVqz3rSib7mE9p wtTss7Zzqpc7kAA1/6ZwTyaedldG1cG7be8MoNGhDQYP/cymbHqxxkp/XSoJNBt35MuC Fm3g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=O6Z3qebR; arc=pass (i=1 spf=pass spfdomain=google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-205457-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-205457-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id a640c23a62f3a-a6c806db067si146620466b.360.2024.06.06.23.35.57 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Jun 2024 23:35:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-205457-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=O6Z3qebR; arc=pass (i=1 spf=pass spfdomain=google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-205457-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-205457-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 524C71F236B3 for ; Fri, 7 Jun 2024 06:35:57 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 798681527BA; Fri, 7 Jun 2024 06:35:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="O6Z3qebR" Received: from mail-ed1-f44.google.com (mail-ed1-f44.google.com [209.85.208.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3A55945008 for ; Fri, 7 Jun 2024 06:35:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717742148; cv=none; b=dwBLWG7+f+tGjIQT6V85yQf4hIywKYCRYQArgzlaAKOO4ZdpgsX/b8VA2VeRXFSLDa796O5RkASEQLSdgizh0dky4Zi71PHXK2E0HxuO2R9Mqj4grOi2Q0Ln+xX/43A4ZwsqJWNmwB/VuU1p0EZGVt5FFLnEOPJ2A1QdcEQRZqY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717742148; c=relaxed/simple; bh=vsF9fVM1//kd5zIx0GTtpB46iJMt9vsqNkPX4bd/w5Y=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=ChU8Uh/sC8ct728+DRg8Zg/COd3USynhgfA3q1MXZOeVb59D8jxadC1JYSbxOCJEAfz0t5so9pEOkqFPyfbk/lL8buWpFFgx1hRCgwS/ix8uDGK41gyB2GI2EISVcYTWqzyOquK0eNCMfjn8jsGKDiJZCuHEUyv78/DVM9A7QNU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=O6Z3qebR; arc=none smtp.client-ip=209.85.208.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=google.com Received: by mail-ed1-f44.google.com with SMTP id 4fb4d7f45d1cf-5750a8737e5so9593a12.0 for ; Thu, 06 Jun 2024 23:35:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1717742146; x=1718346946; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=vsF9fVM1//kd5zIx0GTtpB46iJMt9vsqNkPX4bd/w5Y=; b=O6Z3qebRozuaXrdItPF6U/X0GkPvJTO/BwV0iHOr3HgIdH7VyQMuctWBXynllyqEUb nxcaXZ7YCGM2HmZHsYh03+U9mqnS5LAhAAo2QEFrpOjjRTYlT+gYhw5CzPnbgnWLb3WH NQ0Z1T1GVjlGxTyH3RIVPbJ2XUu2hW5QegI/PQadVWQEb7YT17S50n6I9Wy9GZS4Riqh pyFB+vEy+mY9Wtk3TlzxrbJ9v2NWI7QAJKq7Q7zgCW3IG+4LJJ27RwHOoYQoFrt5Pzyw 6c0gZ5uIuvU+PlA1/BDUhz3Gj0UH0S4bjEhKhtNFZbuaQsgX54jMfh2N2cOgCsagnieP WlXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717742146; x=1718346946; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vsF9fVM1//kd5zIx0GTtpB46iJMt9vsqNkPX4bd/w5Y=; b=a4VcFX1xtyb/zyB8ScB9GHqAB8s4CurrFRycanNyHpuzJFskUtffZjIWb1SmdhZ5n2 JptSqWlYRA3BN+zVWelH2M1MxWRxwKRKQwTG4HnWhuyGkMbeIDygSpM/R8O9Uo4YSRs6 KVAUJCHPM3pzcG/9nHhpti93IC5BEm+z+vouz8DMHEuoMQHlxsO359qdeq4C+b5TffN9 KeMVHlI2NGjAZtss2hnueeRZ5a4F7+ysLPfEFlUvXNZov0jszrrp8NSPyVIauCRSVRMg QdiqWNIEXZEa/0sLFVNriN0A+21Ld83U7SnAK+ce6mk6J1HoljvHYyzpqEFYIJpd1foQ m51g== X-Forwarded-Encrypted: i=1; AJvYcCV02cJ45K1ieyDOp/1W0dUBqYy69VX2JMgJ9QE4sacePy+jYLEI1d/dMi8ZUdD80jhMmO7Qvd3TmpQrV5DqzM+CIJ8i56JVhuNDn2j8 X-Gm-Message-State: AOJu0YwRXkW9cjKBOUc/Nte6CVTx22KiRfNjmhlZpFf7dIgyKGlbN6d5 LyJRQQaoW5laNf4c3C1v/vp3MUX5WIq8ox0g1JD65vKOyhAh8Xw4zaatV6DSV3WTzZWMhDcKMiQ eJR1sQgPstzIn42yIVJ8pY6rsGasvA0HTD8gbY7WFExkhowCpxA== X-Received: by 2002:aa7:d307:0:b0:57a:3103:9372 with SMTP id 4fb4d7f45d1cf-57aad3278f8mr374926a12.7.1717742145328; Thu, 06 Jun 2024 23:35:45 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240606192139.1872461-1-joshwash@google.com> <20240607060958.2789886-1-joshwash@google.com> In-Reply-To: <20240607060958.2789886-1-joshwash@google.com> From: Eric Dumazet Date: Fri, 7 Jun 2024 08:35:30 +0200 Message-ID: Subject: Re: [PATCH net v2] gve: ignore nonrelevant GSO type bits when processing TSO headers To: joshwash@google.com Cc: netdev@vger.kernel.org, davem@davemloft.net, kuba@kernel.org, stable@kernel.org, Praveen Kaligineedi , Harshitha Ramamurthy , Willem de Bruijn , Andrei Vagin , Jeroen de Borst , Shailend Chand , Paolo Abeni , Rushil Gupta , Bailey Forrest , Catherine Sullivan , open list Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Jun 7, 2024 at 8:10=E2=80=AFAM wrote: > > From: Joshua Washington > > TSO currently fails when the skb's gso_type field has more than one bit > set. > > TSO packets can be passed from userspace using PF_PACKET, TUNTAP and a > few others, using virtio_net_hdr (e.g., PACKET_VNET_HDR). This includes > virtualization, such as QEMU, a real use-case. > > The gso_type and gso_size fields as passed from userspace in > virtio_net_hdr are not trusted blindly by the kernel. It adds gso_type > |=3D SKB_GSO_DODGY to force the packet to enter the software GSO stack > for verification. > > This issue might similarly come up when the CWR bit is set in the TCP > header for congestion control, causing the SKB_GSO_TCP_ECN gso_type bit > to be set. > > Fixes: a57e5de476be ("gve: DQO: Add TX path") > Signed-off-by: Joshua Washington > Reviewed-by: Praveen Kaligineedi > Reviewed-by: Harshitha Ramamurthy > Reviewed-by: Willem de Bruijn > Suggested-by: Eric Dumazet > Acked-by: Andrei Vagin Reviewed-by: Eric Dumazet