Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp709314rwb; Thu, 10 Nov 2022 06:31:39 -0800 (PST) X-Google-Smtp-Source: AMsMyM59k4MPP17vinaGQ55ysmSHLQksIn4jdp4M4Q8qyymRIw3GhaXWoDSs8K5sa1lgrxhyHzU7 X-Received: by 2002:a17:906:368f:b0:7ad:ab0e:76aa with SMTP id a15-20020a170906368f00b007adab0e76aamr2841796ejc.435.1668090699740; Thu, 10 Nov 2022 06:31:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668090699; cv=none; d=google.com; s=arc-20160816; b=C0/ISL+fFUPThUrPUW8wKFEJXIkptPTV4fveq915c/t50zBwWkW9a7F5pfM/TmlBaS 0lDjXpBQ8wHUUAIz6Uhp9sjFrVlszM+dve6P71Fp63J7EewRHPCGMY0X2WaLz1LauwLc YWO9vUS94NmAzRsND9bxuMWjnNqlOLiFRvmi9GRbbe9/TZB/+5xPSDXD7Mw0ZgOgq2Vm ElU7I9TtaiV0IY0P8+SKqpWs5ts9BK5qP5Z509kVCPBVyDXdKb+F7DEhCMNwoMSgD4Xc E7YuDG/OzYuvaJEeWEm8ZO3aPLvKR/oSSbxcduovg1RHIJ8WOceUrb/xsvP3Ead9RR/t 2aag== 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=uyUdvAvFfBedY8C4R1CoGalnnZqFS5BS9edNzqJV4LE=; b=rEwPuj7OhjftLZ8e+0qc+4Gi7boWB8sEqt/mwdkoKk4T+otsoFZYbEo6Ctdyt5nian SLDR74B3EzydZt19qeGGg0EB2Xt7Q+WrzswqxJRfujbKL9lY4xu/fy+JwsmeYGnjfcV1 LeLyPCjCIIQL6LMAtpbAj/Vk/7Bk+DPbe+tHVJ8x4MLd3Or2vH4VGt6CMLNKTqAirwwP qpyt/wMkE/ifgRpohSiklR9qU3CbHJKQgUD5JnzZ+Dmp6IuNTs3LFk0RBACr04hwbcIw AEjsT7UqGg/FB7f2mBVKZhFLmrsHmVZ0wtQmGOSPBG6CmR72uhgSFPCJlyAq+OosGMn7 Koog== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=awdpZzgH; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i8-20020a05640242c800b00459dc4e4b7fsi20506690edc.143.2022.11.10.06.31.15; Thu, 10 Nov 2022 06:31:39 -0800 (PST) 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; dkim=pass header.i=@gmail.com header.s=20210112 header.b=awdpZzgH; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230128AbiKJNDe (ORCPT + 92 others); Thu, 10 Nov 2022 08:03:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230116AbiKJNDc (ORCPT ); Thu, 10 Nov 2022 08:03:32 -0500 Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F3041D5F; Thu, 10 Nov 2022 05:03:30 -0800 (PST) Received: by mail-ej1-x633.google.com with SMTP id q9so4938134ejd.0; Thu, 10 Nov 2022 05:03:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=uyUdvAvFfBedY8C4R1CoGalnnZqFS5BS9edNzqJV4LE=; b=awdpZzgHXvaGozAEQ7Mhh+xLeFZETbddCE0K8LRU2+3No7vqY150um9E3Wv9NcyQ7s nGL5IWErgErtYri2MC8wDzOo97mCzWnXKQMVZOAO3ANSJRNRptLrIMMMVt5h3dMmhosP lnCBTnpC1EXf5R37OWxCzm+/OdrFkPgnmBLVrCfukeQVDFhk6SUbMb8BQqgftzxVQ5aS q/WJZoX9lhFPZM33HVCqyZvBzUfTRizH/gyh5EsuPJXq0NKW1sxF4jS66WtXtFapcpce zHG0OXZxJe7S+gC6gBK8lGmtIKrlLbLyzUuFFHREPxRi6PH0bYPHDftG1pcf8HQGJQFf D1Qg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=uyUdvAvFfBedY8C4R1CoGalnnZqFS5BS9edNzqJV4LE=; b=PsI+2xCNUx6pKO7112l4GFsD6j8eXKLsgVUYSoKxCaqkbhmiYelk7i2cVIAY9w0Y78 JehgATYFfNOnuv8nuotO/jiSCefQsW6G759ulqD+TZL+xaRfpj9FvvLM7gmeDdpdYQFb yO4OLKA4A4eeOZLek8WSpv2mTgbbCz66vd4YdhiV7pGnVvcoQPIbsfabeCbrNCkuKoRt zlRQa2KHQJW/LiYeexPOguLx2exEe1U0fE+T0H2PP7YMXbzk38MWOQrfIZwPBMtMC4xQ EKcdf0pCMMrNEoUGPSCS11ayLXdoXWs18xNy9QNeKramdIpUw4TeL6tox7hKZOiOeCB1 3EOw== X-Gm-Message-State: ACrzQf0w6016urg7W2/nIZn0gwofNiPD315CHYj3d1u0c/GMGAlfPFIw DQxFcL/YBfJ0/BF4WL32f8wY3jACXUWkjQ== X-Received: by 2002:a17:906:79c4:b0:782:7790:f132 with SMTP id m4-20020a17090679c400b007827790f132mr2747677ejo.649.1668085409325; Thu, 10 Nov 2022 05:03:29 -0800 (PST) Received: from skbuf ([188.27.184.197]) by smtp.gmail.com with ESMTPSA id l26-20020aa7c3da000000b0045bccd8ab83sm8622082edr.1.2022.11.10.05.03.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Nov 2022 05:03:28 -0800 (PST) Date: Thu, 10 Nov 2022 15:03:25 +0200 From: Vladimir Oltean To: Oleksij Rempel Cc: Woojung Huh , UNGLinuxDriver@microchip.com, Andrew Lunn , Vivien Didelot , Florian Fainelli , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Arun Ramadoss , kernel@pengutronix.de, linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: Re: [PATCH net-next v4 4/4] net: dsa: microchip: ksz8: add MTU configuration support Message-ID: <20221110130325.eklhybumv7naehxe@skbuf> References: <20221110122225.1283326-1-o.rempel@pengutronix.de> <20221110122225.1283326-5-o.rempel@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221110122225.1283326-5-o.rempel@pengutronix.de> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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 Thu, Nov 10, 2022 at 01:22:25PM +0100, Oleksij Rempel wrote: > Make MTU configurable on KSZ87xx and KSZ88xx series of switches. > > Before this patch, pre-configured behavior was different on different > switch series, due to opposite meaning of the same bit: > - KSZ87xx: Reg 4, Bit 1 - if 1, max frame size is 1532; if 0 - 1514 > - KSZ88xx: Reg 4, Bit 1 - if 1, max frame size is 1514; if 0 - 1532 > > Since the code was telling "... SW_LEGAL_PACKET_DISABLE, true)", I > assume, the idea was to set max frame size to 1532. > > With this patch, by setting MTU size 1500, both switch series will be > configured to the 1532 frame limit. > > This patch was tested on KSZ8873. > > Signed-off-by: Oleksij Rempel > Acked-by: Arun Ramadoss > --- Reviewed-by: Vladimir Oltean As an extension to this patch set, you might also want to set ds->mtu_enforcement_ingress = true, to activate the bridge MTU normalization logic, since you have one MTU global to the entire switch.