Received: by 2002:a05:7412:f589:b0:e2:908c:2ebd with SMTP id eh9csp268754rdb; Tue, 31 Oct 2023 07:07:21 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEO5P9p7hJCZMxzmfboakU9b7zF3CbAI/4X09/Bzgvr4ldaxoaKkGwevBanwvqaYFqYJn88 X-Received: by 2002:a05:6a21:32a8:b0:180:f8c2:6363 with SMTP id yt40-20020a056a2132a800b00180f8c26363mr1832110pzb.55.1698761241370; Tue, 31 Oct 2023 07:07:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698761241; cv=none; d=google.com; s=arc-20160816; b=ur8i0oB+nlNH1t3BE3zBgmJ3tNouFKA0H4GZe27ULCJm06B8tfz4ckTPz/hSrxlX6N 41gcWtDomcKO7GSRI2mtHWDGRzvSsTnTISAoKXsE5i9VfEp4VJnFfkfebDPl62Q20Vuc uFIjYytwHEpj92z5HxbMdw9tYEWGwtA0Sl35EpWO55wvDQP5kdOkuB1A+9bT/FCnU4nR T5Qi8143dKefjk2JgiJG6WTnYcSAg7ZU1ktQjFyyEB0FRyYsqM5RkxQoW/4oYxlVmXwn LyuvUu7Hb/AgMDo19nAuWn4QCTubo3UDF4gl2457y7T1HZXAmXlpmgIuhmOA/jRBq9ez U/iw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=3gOGBDhGMAomhjgIfG+7vYKiHbH7aSl3HXwGenxwfd8=; fh=AA86fYySLnjYeKw6zyKpXDl3SCMz+EeNUy91eZQI764=; b=Ami2u0MaZgY9cuLg0TaGa56GdVa8qPooeIU/6zCt59UkI8bjsQkgYs/pvbMZnYa60l gqpoAV1vglN56rx+Sh2g4sQIUFnUyL0UzVdkjbtHmRUIYZb6UiFuQZGtjIozXZXeWxyL IojxQUP+BuiQLmyeSgx73ows0haZOjb19gDKVGmUSZ8VcgfvgYK//QRwXQjIpQ69NTiD GYh5fEz0g3FylEIvagTB4GWnyCrNdNmIh51L3uE16gspU7cbXda+wImriQNOmN3L12nM Ubg5URSl3/sqNcmabCI/YnjCyUUjH10EGW8vqlFT7lM6JT5bqS6X/RQB5kUaIH6lujr5 7bYg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ijI6iDVF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id c7-20020a6566c7000000b0059779ae58a0si1108938pgw.465.2023.10.31.07.07.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 Oct 2023 07:07:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ijI6iDVF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id B64A7802138B; Tue, 31 Oct 2023 07:07:18 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232223AbjJaOHM (ORCPT + 99 others); Tue, 31 Oct 2023 10:07:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42914 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235976AbjJaOGv (ORCPT ); Tue, 31 Oct 2023 10:06:51 -0400 Received: from mail-yw1-x1135.google.com (mail-yw1-x1135.google.com [IPv6:2607:f8b0:4864:20::1135]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C3395D7F for ; Tue, 31 Oct 2023 07:06:26 -0700 (PDT) Received: by mail-yw1-x1135.google.com with SMTP id 00721157ae682-5a7afd45199so56360177b3.0 for ; Tue, 31 Oct 2023 07:06:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1698761185; x=1699365985; 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=3gOGBDhGMAomhjgIfG+7vYKiHbH7aSl3HXwGenxwfd8=; b=ijI6iDVFyTBszIfnye6I+ujsE0YOatWd8xEUAI1wG3U43K/sEZsdVz7YcNXkVe+upN N1d2Dl6sogtAAxdjSC1Pl0vMHz9ag1mV8u45qWoSRTAkYn3V+g8KiRwgacU033TB9MVp YxuT9OuFphXJGGNg/gkEZBrbmDoMfAwqCUZF0PoJV1mOKONO0bmdPyJwL0VZZoVyB28h 6hQvXWn6rWYfwAklRz6NfFIwbjDX64YwdVUhz7xZgn3s7LrGOukjH6vlWjxaBGbj54hr cnKnNri0w7fRilzq4tzjeoAAxrbzx0Ee2W9xT/O98vsNdxlnY5tuRMA4znn7SvY6xU5O lF4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698761185; x=1699365985; 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=3gOGBDhGMAomhjgIfG+7vYKiHbH7aSl3HXwGenxwfd8=; b=GGh5gsM1oLmI88k1Gr7jFRrUFfNoSuKQsHl6NkNoWvnyqgi/4DD54YjHVqMbpsF/6S 9OTNsIy9ghpWmKgWKomTwCkwBYwJlQRwj1MpzGWSGgupH59TfpKMlcZMxT1ND7UCA3S4 qXThCKEtxar/UHNeH3egxLvBdBIRbu7X00QIHvNOsUrMMWeABIYm2zHzgrnPw55b0h/9 MxWC4qmk7QNUBy+lkbVCTy2jb3dNTJ6QXp2W48kSTi4C9NWKlXxp+VKpOAFVwMk4r9j9 w7GXriEjyc20jW13YwSC4j9TMgKqh+13AextADJ1V4YM2oasHcj1V927Ft3EuGbIpExy ZHtQ== X-Gm-Message-State: AOJu0YxV3qQq+hWxBCZJ0hLYA4r8kX0cXTIJgBbkaIGYkQyQ4wa9eK+f 03Zyg5FIo9lBERA+HJjpUHwtxxhH3cyIkBXhEVNl0Q== X-Received: by 2002:a81:8b44:0:b0:5a7:af89:c4a0 with SMTP id e4-20020a818b44000000b005a7af89c4a0mr13078152ywk.23.1698761185232; Tue, 31 Oct 2023 07:06:25 -0700 (PDT) MIME-Version: 1.0 References: <20231030-fix-rtl8366rb-v2-1-e66e1ef7dbd2@linaro.org> <20231030141623.ufzhb4ttvxi3ukbj@skbuf> <20231030222035.oqos7v7sdq5u6mti@skbuf> <20231030230906.s5feepjcvgbg5e7v@skbuf> <494a8bb7-7ca1-40bd-b3a7-babeadfd88a0@lunn.ch> In-Reply-To: <494a8bb7-7ca1-40bd-b3a7-babeadfd88a0@lunn.ch> From: Linus Walleij Date: Tue, 31 Oct 2023 15:06:12 +0100 Message-ID: Subject: Re: [PATCH net v2] net: dsa: tag_rtl4_a: Bump min packet size To: Andrew Lunn Cc: Vladimir Oltean , Florian Fainelli , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.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 (fry.vger.email [0.0.0.0]); Tue, 31 Oct 2023 07:07:19 -0700 (PDT) On Tue, Oct 31, 2023 at 1:37=E2=80=AFAM Andrew Lunn wrote: > On Tue, Oct 31, 2023 at 01:09:06AM +0200, Vladimir Oltean wrote: > > On Mon, Oct 30, 2023 at 11:57:33PM +0100, Linus Walleij wrote: > > > This of course make no sense, since the padding function should do no= thing > > > when the packet is bigger than 60 bytes. > > > > Indeed, this of course makes no sense. Ping doesn't work, or ARP doesn'= t > > work? Could you add a static ARP entry for the 192.168.1.137 IP address= ? > > Probably the ARP, since they are short packets and probably need the > padding. It seems correct: the reason ping stops working is not that the ping isn't reaching the host, I can see the pin request on tcpdumps. The reason is that the host has no idea where to send the reply. Because it's not getting any ARP replies. And that is probably because the ARP replies are short and needs padding to ETH_ZLEN. I notice the code is probably borrowed from tag_brcm.c which does exactly the same thing (ETH_ZLEN + tag). It comes with this explanation: /* The Ethernet switch we are interfaced with needs packets to be at * least 64 bytes (including FCS) otherwise they will be discarded when * they enter the switch port logic. When Broadcom tags are enabled, we * need to make sure that packets are at least 68 bytes * (including FCS and tag) because the length verification is done after * the Broadcom tag is stripped off the ingress packet. * * Let dsa_slave_xmit() free the SKB */ The switch fabric is dropping smaller packets when CPU tags (DSA tags) are enabled. So is the padding to ETH_ZLEN OK or should is happen elsewhere? Yours, Linus Walleij