From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.246.84.56 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794928814; b=Pi+kxiBvTKr+69Ik+IX8X0csOAU7HRoGjPzFPcpHoJFjzWLIsC3cJ29L0k2s98lY5oOD pf5LbBeeng+sA3OSWbzdlp6lEWu5g8ollXo7ZMWeSNrHPcb8Wec4PNkDwKAaNYucingZD wMFF7FnIQBvP7axXNUGiugSRyDcCzTaUcza6mRbKvh189cVL1EAbd+dxoIRC+4al9ZTEU QFvmubunkMpUwTHRKa+yxZGIqkIJ5cuUW7nSc1Y2YANP8ithez4OEchR/oS1IJdpG0sfv GiF+XEoi20fuZGrSR66o5msx8XwZJdcyPtDIjrA/sMdwbzdJUSK5Uqz0v51B4SOv88w== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794928814; h=DMARC-Filter:Received:Received:Received:DKIM-Signature:Message-ID: Date:MIME-Version:User-Agent:Subject:To:Cc:References:From: Content-Language:In-Reply-To:Content-Type:Content-Transfer-Encoding: X-Last-TLS-Session-Version; bh=f8D4AXpdECEMbVGfexe2cz/ScJYTT4Gg2O95M/ifd9s=; b=uIdhBZcoMxyn1afwOWTZr/iSfguFyqWc4F9PKDNHpUsUT0Mo5fDj64D8yEcoZ8p9NT+0 FCB8l3A1SQvZf35SqxYstEBb6kgHyBEA25Q3qy/+XPnxwrl7ibPjnjOV3KAkPBxn52Ces f/EoBOiukZjd5UBwBAylydDn9sUtzijVumNaSmK0oP0PJKEi+oxfS2aJhWz385rVZ84tr 0sDlAgF359fGFKtv4cvHFRZI54YIsrK6KSIGAwrBkpLL0D7N6EVqaz+mzv3bh4Y8xZBgB hy1Zs2k/2iSAK6JisZD3u9jRr1RiiiF9F9fVxy78UFOmXOqtTqMi5V+msnIADVwuOFg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=spPImfx6; arc=none smtp.remote-ip=185.246.84.56 Received: from smtpout-02.galae.net (smtpout-02.galae.net [185.246.84.56]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4991A606A335 for ; Tue, 17 Nov 2026 15:20:12 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 4991A606A335 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=spPImfx6 Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-02.galae.net (Postfix) with ESMTPS id 68A811A15CD; Tue, 17 Nov 2026 15:20:11 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 326355FD6A; Tue, 17 Nov 2026 15:20:11 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 5396711BC0041; Tue, 17 Nov 2026 16:20:01 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1794928806; h=from:subject:date:message-id:to:cc:mime-version:content-type: content-transfer-encoding:content-language:in-reply-to:references; bh=f8D4AXpdECEMbVGfexe2cz/ScJYTT4Gg2O95M/ifd9s=; b=spPImfx6F3CzhN16ICPmW7T06RqvUifyDFcrx8atsJuVdxPSElDxgZB3E+SewfgfHYbQk7 V4MlwVfWoKNAWrdv5W73fwoMA5MKtYJL6gTuWVWG5jpjyMFOs6PTpxcM3z1Ak1FEeJgqSV pDsvdF2j+XIkT3XSP5tIkPd/Grrg8Ck2a58GoDWddT0px3jEXbYA9SHV1AcW1meNc2od9k lSpWdBItmquE4Ebno/2zFDY9affW+xNwnrDKoEVv6JXEFnixQ+Tw96/Q6PGmfrhO6/VDuL kTmlc3oYWYiDDxby2VdZYL37wbzOyJPI6nLRUjWOyPwVyoUZW+CvSDlUe9uyzQ== Message-ID: Date: Tue, 17 Nov 2026 16:20:00 +0100 X-Mailing-List: netdev@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH net] net: stmmac: dwmac-sun8i: Honor the RX checksum offload setting To: James Hilliard , netdev@vger.kernel.org, Andrew Lunn , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Maxime Coquelin , Alexandre Torgue , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , LABBE Corentin Cc: linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org References: <20261115-submit-sun8i-emac-rx-checksum-v1-v1-1-f186d127b39f@gmail.com> From: Maxime Chevallier Content-Language: en-US In-Reply-To: <20261115-submit-sun8i-emac-rx-checksum-v1-v1-1-f186d127b39f@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Last-TLS-Session-Version: TLSv1.3 Hi, On 11/16/26 01:58, James Hilliard wrote: > stmmac_set_features() clears hw->rx_csum when RX checksum offload is > disabled, but sun8i_dwmac_rx_ipc_enable() unconditionally enables the > hardware checksum engine. The MAC therefore keeps dropping packets with > invalid IP or transport checksums before they reach the host, even after > ethtool reports RX checksumming as disabled. > > Set or clear EMAC_RX_DO_CRC according to hw->rx_csum so that disabling > offload leaves checksum validation to the network stack. Preserve the > callback's existing success return value. > > Fixes: 9f93ac8d4085 ("net-next: stmmac: Add dwmac-sun8i") > Signed-off-by: James Hilliard Nice and simple, I tested that on an orangepi zero, with an allwinner H2+, and I can indeed see the difference as bad chksum packets are dropped on that core. Reviewed-by: Maxime Chevallier Tested-by: Maxime Chevallier Maxime