From patchwork Fri Oct 20 05:32:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yan Zhai X-Patchwork-Id: 155814 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:2010:b0:403:3b70:6f57 with SMTP id fe16csp839006vqb; Thu, 19 Oct 2023 22:33:09 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFRfyJLuZzO0SHbTj/znjNrUi3kxNt34zy6IzT6N+Af+d+YXfShd+Z7RQ+V+sygffrc9JPl X-Received: by 2002:a05:6358:5384:b0:166:c004:f657 with SMTP id z4-20020a056358538400b00166c004f657mr773969rwe.14.1697779989553; Thu, 19 Oct 2023 22:33:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697779989; cv=none; d=google.com; s=arc-20160816; b=vM8+8nTptLgvyAhWPoYFN3jzSnAtKqZOGYDnrrrtbttjQEjuzisgakJztkA7V9cPTe Yb3uFPf5WptH8cN56aSuTG1TepxmzMFbvJkC3Fo/2Uhk2loBgL2nd6ffYnrTXWARmJLW Q1Of7ud1gEn2VD9CWFhTe9Ee8ztJiA31UdYyClzJaqK+CaaCUG/UsHkx0xdb/3Lh1+sZ p7iKQuVmUudrGn16WnnDw63xuQD+YoWw7oOoaVwzyc5XXTuLZcNbxgRG0B1QMOwngDMb eiUeu1cFLc9z2nHDCTE+/LEQl4Lbq2sol8Pzw7UwMbIqvQkfdlgldTSHf0IQNP02Th2n VjOQ== 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=KV869UUQKRDRmnZ80A1/n7z6+idYBNckQF54inYjS5g=; fh=pcqFZQYW2ZOvrJzL6iYbdBSsYjMBR+cDRZVlzaRzt/k=; b=ndFdR14dUKkq+8h6smBTY3wgwc9rqS8ZJgfj6JpQj/EK6IGKQYSZ+9wdifpLXMl1Mu kjT1l3XAQCtZ78UM67gvahGtOJBFhDMxAsly8QMO0h0Foc/piWQysUZ5bNoN44lhliyx UyfT0/8+KZ+t9f5GmcaRafyJdBIt2yZk4OU4JIXkZs2/LPN4Vk4BKG2GpRapfgKuUKt9 T8nH95WIMFI1CCiCD4RdldqGEhqXKbuFZMWvPG8gVgtWDedl2ZQMjEh9Dtpsr500hlR/ G0tQp36n+m6mgyvJGw+LYErvAnYAuzi7g+GfMnV4evVTNdaEWb7RMXZxvW/Kosi3aS6K CElQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cloudflare.com header.s=google09082023 header.b=HzbvMgu0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=cloudflare.com Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id a28-20020aa7971c000000b006bd3ba8e610si1149010pfg.133.2023.10.19.22.33.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 22:33:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@cloudflare.com header.s=google09082023 header.b=HzbvMgu0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=cloudflare.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 3A09981D0B75; Thu, 19 Oct 2023 22:33:07 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346301AbjJTFcx (ORCPT + 25 others); Fri, 20 Oct 2023 01:32:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345460AbjJTFcv (ORCPT ); Fri, 20 Oct 2023 01:32:51 -0400 Received: from mail-qk1-x729.google.com (mail-qk1-x729.google.com [IPv6:2607:f8b0:4864:20::729]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 67E20119 for ; Thu, 19 Oct 2023 22:32:50 -0700 (PDT) Received: by mail-qk1-x729.google.com with SMTP id af79cd13be357-7781bc3783fso28481585a.1 for ; Thu, 19 Oct 2023 22:32:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cloudflare.com; s=google09082023; t=1697779969; x=1698384769; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=KV869UUQKRDRmnZ80A1/n7z6+idYBNckQF54inYjS5g=; b=HzbvMgu0lCF6faIChfXVinjI8bdH8kCWR2utK3tXvu34fwxKuN+u7vQC/G26UceGv+ SzAlBbmmwoyVsMMJDSYTFzUfmx4HYcSpKW17SlKRor46zKxpjr6mwSaGGbxtPh0q8TgV yFKM4Ca7zSRagheV0IgDbFz4qAx4bITuix1XYKvWn7fxL9oGRbvNwfXRzE8OlLpwFzQo ypWPvQR5Vq97WzVambzsJJY1rCxxp6gIoMAoPfLEWaABiCZp25xVa0DQyTSr5qstDPcT 5/t822WT84u42eN7Th3pb3hEGHGm5n+IjmmX95weEKhR59aX+AtSUMlj/PwMdXA9gR5B QijA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697779969; x=1698384769; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=KV869UUQKRDRmnZ80A1/n7z6+idYBNckQF54inYjS5g=; b=InDf4XvD41ZbSPhNdaEm3e4Boi0Hzj6IYf+Anot8dUrsuXNTVEwr6lcvzimQ1DKg3R 8ah+ooL6i1yrqtqHvjuq6rgyiLheQbBm1m4SFyoBw1pxHbw/C//cqppNX5HD/3H+HAWa EUGEBd/zLHS6IviRztucY3i+kaRZNDXHNI7wfidOTRvltcwYJX3ZqVXdseB69LjlqJ1R ksWyijcKlH1b2gObv7wseYtbmMDll0Td7Zk8EyWOlrKq+ul3shyb4KTuEVEEznzxoGnU rXJL2gdSbZ6rkkDPsndmNaHeAvSvQpywp0CT96u5tIMikNFjotT7Dg72y9bX0YH251BI 8ceA== X-Gm-Message-State: AOJu0YzOeXToSj8dBFkB7bqqaN0w1moI0iSFF27n9lFJDQspxMtuhVoP yJjHEoF5v56vZ61h48yOeUvD0Q== X-Received: by 2002:a05:6214:d66:b0:66d:1e25:9774 with SMTP id 6-20020a0562140d6600b0066d1e259774mr916666qvs.61.1697779969555; Thu, 19 Oct 2023 22:32:49 -0700 (PDT) Received: from debian.debian ([140.141.197.139]) by smtp.gmail.com with ESMTPSA id g20-20020ad457b4000000b0065d0dcc28e3sm421513qvx.73.2023.10.19.22.32.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 22:32:49 -0700 (PDT) Date: Thu, 19 Oct 2023 22:32:47 -0700 From: Yan Zhai To: netdev@vger.kernel.org Cc: "David S. Miller" , David Ahern , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Aya Levin , Tariq Toukan , linux-kernel@vger.kernel.org, kernel-team@cloudflare.com, Florian Westphal , Willem de Bruijn , Alexander H Duyck Subject: [PATCH v3 net-next 1/3] ipv6: remove dst_allfrag test on ipv6 output Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Thu, 19 Oct 2023 22:33:07 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1780251350486325310 X-GMAIL-MSGID: 1780251350486325310 dst_allfrag was added before the first git commit: https://www.mail-archive.com/bk-commits-head@vger.kernel.org/msg03399.html The feature would send packets to the fragmentation path if a box receives a PMTU value with less than 1280 byte. However, since commit 9d289715eb5c ("ipv6: stop sending PTB packets for MTU < 1280"), such message would be simply discarded. The feature flag is neither supported in iproute2 utility. In theory one can still manipulate it with direct netlink message, but it is not ideal because it was based on obsoleted guidance of RFC-2460 (replaced by RFC-8200). The feature test would always return false at the moment, so remove it from the output path. Signed-off-by: Yan Zhai --- net/ipv6/ip6_output.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c index a471c7e91761..ae87a3817d4a 100644 --- a/net/ipv6/ip6_output.c +++ b/net/ipv6/ip6_output.c @@ -189,7 +189,6 @@ static int __ip6_finish_output(struct net *net, struct sock *sk, struct sk_buff return ip6_finish_output_gso_slowpath_drop(net, sk, skb, mtu); if ((skb->len > mtu && !skb_is_gso(skb)) || - dst_allfrag(skb_dst(skb)) || (IP6CB(skb)->frag_max_size && skb->len > IP6CB(skb)->frag_max_size)) return ip6_fragment(net, sk, skb, ip6_finish_output2); else