Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp5146250rwr; Mon, 8 May 2023 19:18:19 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5PMXqt0jPv55GT8m43gl0rcyPwy+S/X06T6u+opyxOfYGZWKMiZxAQW3ytU9/j/Rplx1vo X-Received: by 2002:a05:6a00:2e9b:b0:642:ffef:1d03 with SMTP id fd27-20020a056a002e9b00b00642ffef1d03mr18294621pfb.32.1683598699515; Mon, 08 May 2023 19:18:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683598699; cv=none; d=google.com; s=arc-20160816; b=NST3kRll/59UwMzz2iL6G6pem3TnoypugycR6PGyO+QHPigWQPG1G4D/qZNFBZ3IaT Pz6AKfXy2yv6pAJ2PT4RzvL7JY5Y/j8PxvxmV+4dZNHrvO2KVe7heIb6o5+k9D6VUJgx htMNFZjGZ821sfKZW5GNcYg8Zcge76mG3Csnozfkr9OdgTXEjTBOaQx0iUOk1FP1lMqH 3WYmxShI3CNpzBM1LEq5IWMePXtAt7cRHw4jiuO1IXx/iz6TIp83L8+9Z7T/LxCa6xYw LxviPNzhPAM3KUJPo/Q+ZIe2SM+mjN5FaNcMxeC1TEVGWlayABWGzRX2gojt25begftr bsdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:references:cc:to:from:date:subject :message-id; bh=IQetGuxzkuGxp2AYHkFjJJyszaOo3UsuUuCsooPskPg=; b=0jQ+Y9RJLQxVHb1R4DRXCFwkRaryqhiuD4qohtQg+eXz6vnTDfy6QGbIxtsS7IBg4p PGgHAn8/QDVZywBosy0ZbHqZMF/H+WoHzGYCHpHs4E7JFc4Kumjas1xnCINkH4xzQCv1 Kk48o4GOyXhwJ2Ptnl0C7TntCChDvjo7Ut5aKpwiv4xESn6DDnemVHtbbgSjA7zrz7AT LN7tm1fqpLHwcnUHrjevCiBdOwbHAq5aoZ5Y2L1wD4bYqjnH7+4SAVznQawyIacZ2Htg MvvopfKZgTK4pCXuwvbXCTjzHUh0Q8guxmQVWeTp4G+2UHAphJVhAZwmgsmef+GLBks1 nC3g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i30-20020a056a00005e00b0063b87656fd6si1304071pfk.203.2023.05.08.19.18.05; Mon, 08 May 2023 19:18:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233043AbjEIByw (ORCPT + 99 others); Mon, 8 May 2023 21:54:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48622 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229455AbjEIByv (ORCPT ); Mon, 8 May 2023 21:54:51 -0400 Received: from out30-111.freemail.mail.aliyun.com (out30-111.freemail.mail.aliyun.com [115.124.30.111]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B773D2D2; Mon, 8 May 2023 18:54:30 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R151e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018045170;MF=xuanzhuo@linux.alibaba.com;NM=1;PH=DS;RN=14;SR=0;TI=SMTPD_---0Vi8pzhn_1683597247; Received: from localhost(mailfrom:xuanzhuo@linux.alibaba.com fp:SMTPD_---0Vi8pzhn_1683597247) by smtp.aliyun-inc.com; Tue, 09 May 2023 09:54:08 +0800 Message-ID: <1683597099.3423615-2-xuanzhuo@linux.alibaba.com> Subject: Re: [PATCH] virtio_net: set default mtu to 1500 when 'Device maximum MTU' bigger than 1500 Date: Tue, 9 May 2023 09:51:39 +0800 From: Xuan Zhuo To: "Michael S. Tsirkin" Cc: huangml@yusur.tech, zy@yusur.tech, Jason Wang , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , "open list:VIRTIO CORE AND NET DRIVERS" , "open list:NETWORKING DRIVERS" , open list , Hao Chen , hengqi@linux.alibaba.com, Stephen Hemminger References: <20230506021529.396812-1-chenh@yusur.tech> <1683341417.0965195-4-xuanzhuo@linux.alibaba.com> <07b6b325-9a15-222f-e618-d149b57cbac2@yusur.tech> <20230507045627-mutt-send-email-mst@kernel.org> <1683511319.099806-2-xuanzhuo@linux.alibaba.com> <20230508020953-mutt-send-email-mst@kernel.org> <1683526688.7492425-1-xuanzhuo@linux.alibaba.com> <20230508024147-mutt-send-email-mst@kernel.org> <1683531716.238961-1-xuanzhuo@linux.alibaba.com> <20230508062928-mutt-send-email-mst@kernel.org> <20230508092548.5fc8f078@hermes.local> <20230508140640-mutt-send-email-mst@kernel.org> In-Reply-To: <20230508140640-mutt-send-email-mst@kernel.org> X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY, USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 8 May 2023 14:10:07 -0400, "Michael S. Tsirkin" wrote: > On Mon, May 08, 2023 at 09:25:48AM -0700, Stephen Hemminger wrote: > > On Mon, 8 May 2023 06:30:07 -0400 > > "Michael S. Tsirkin" wrote: > > > > > > > > I don't know, in any scenario, when the hardware supports a large mtu, but we do > > > > > > not want the user to use it by default. > > > > > > > > > > When other devices on the same LAN have mtu set to 1500 and > > > > > won't accept bigger packets. > > > > > > > > So, that depends on pmtu/tcp-probe-mtu. > > > > > > > > If the os without pmtu/tcp-probe-mtu has a bigger mtu, then it's big packet > > > > will lost. > > > > > > > > Thanks. > > > > > > > > > > pmtu is designed for routing. LAN is supposed to be configured with > > > a consistent MTU. > > > > Virtio is often used with bridging or macvlan which can't support PMTU. > > PMTU only works when forwarding at layer 3 (ie routing) where there is > > a IP address to send the ICMP response. If doing L2 forwarding, the > > only thin the bridge can do is drop the packet. > > > > TCP cab recover but detecting an MTU blackhole requires retransmissions. > > Exactly. That's why we basically use the MTU advice supplied by device > by default - it's designed for use-cases of software devices where > the device might have more information about the MTU than the guest. > If hardware devices want e.g. a way to communicate support for > jumbo frames without communicating any information about the LAN, > a new feature will be needed. Let's think this question carefully. If necessary, we will try to introduce a new feature for virtio-net spec to support Jumbo Frame. Thanks. > > -- > MST >