From patchwork Wed Nov 9 16:34:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felix Fietkau X-Patchwork-Id: 13037713 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F2B7BC4332F for ; Wed, 9 Nov 2022 16:36:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=kfZopKdmP7cghipCIOQPe93L4BJ+gqAldGf0pV7xABk=; b=tjsMdAytNysXXR zQpIAzAEH+kRHgGFzuOIgyflJKVxeLMjmbR+BJgeEzgbVlCWLA6tBjH9JCvu4NfiiN25GE/NsvsbN 6MaEIZ4obvnpy+zaSBeVmbgFcCVapnnBmH+sYbcswUo4E3iwjXhkqkYHT4CTYUj6GjsrSAHCQU3/F E1bU8zDhyTT0jz8gURUxA7v/xGVDsHutLQvBQBfDGx3cItklQAQckBQ26vtM3dLILqYQIzcXTUj+6 AH6PVQ0zp69cK4pma4eigHgoepm1iozZBMJy5V0swCHrAbDBFXuWBa+acpCvI4w9mbTmJb/nH5Nje tioUpeRpL2ezJvyfUATg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oso33-00F3m4-7Y; Wed, 09 Nov 2022 16:35:33 +0000 Received: from nbd.name ([46.4.11.11]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oso2K-00F3KI-Eh; Wed, 09 Nov 2022 16:34:50 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=nbd.name; s=20160729; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=W2E4Ms9uc9J9Ds/fMfsOB8+k0By+V4+l9wVONX22uWE=; b=pA8lzr+rM2UmcM0MV2wVv0Kw4C fyf9BHbCCg2RLB0h0MPAXyJR70KaGvc28usii6aQo4415C3/S/LcHMO0L+SEQTSbO/+RpvrrbfScD 0ydNos+7lUENHNS+21V+Mo82l7pniop4A4kl9lVI/WJUN/LNmCs88s8AwHc6XYSAr8b8=; Received: from p200300daa72ee100054f3c61b16ef6e7.dip0.t-ipconnect.de ([2003:da:a72e:e100:54f:3c61:b16e:f6e7] helo=localhost.localdomain) by ds12 with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256 (Exim 4.94.2) (envelope-from ) id 1oso23-000l4N-2z; Wed, 09 Nov 2022 17:34:31 +0100 From: Felix Fietkau To: netdev@vger.kernel.org, John Crispin , Sean Wang , Mark Lee , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Matthias Brugger Cc: Vladimir Oltean , linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH net-next v2 01/12] net: ethernet: mtk_eth_soc: account for vlan in rx header length Date: Wed, 9 Nov 2022 17:34:15 +0100 Message-Id: <20221109163426.76164-2-nbd@nbd.name> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221109163426.76164-1-nbd@nbd.name> References: <20221109163426.76164-1-nbd@nbd.name> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221109_083448_507899_5F7B9CD7 X-CRM114-Status: GOOD ( 10.82 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The network stack assumes that devices can handle an extra VLAN tag without increasing the MTU Signed-off-by: Felix Fietkau Reviewed-by: Vladimir Oltean --- drivers/net/ethernet/mediatek/mtk_eth_soc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/mediatek/mtk_eth_soc.h b/drivers/net/ethernet/mediatek/mtk_eth_soc.h index 589f27ddc401..3d7cdc1efbbc 100644 --- a/drivers/net/ethernet/mediatek/mtk_eth_soc.h +++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.h @@ -29,7 +29,7 @@ #define MTK_TX_DMA_BUF_LEN_V2 0xffff #define MTK_DMA_SIZE 512 #define MTK_MAC_COUNT 2 -#define MTK_RX_ETH_HLEN (ETH_HLEN + ETH_FCS_LEN) +#define MTK_RX_ETH_HLEN (VLAN_ETH_HLEN + ETH_FCS_LEN) #define MTK_RX_HLEN (NET_SKB_PAD + MTK_RX_ETH_HLEN + NET_IP_ALIGN) #define MTK_DMA_DUMMY_DESC 0xffffffff #define MTK_DEFAULT_MSG_ENABLE (NETIF_MSG_DRV | \