Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp117667imm; Tue, 19 Jun 2018 17:15:49 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKCArcPJ0R5H+/zSYRg7kobe5xv0Z9tvcTE+Kn8oVh0fBr0YZoreNUNI1tp2WGNYSpz9eqk X-Received: by 2002:a65:6142:: with SMTP id o2-v6mr16991901pgv.347.1529453749021; Tue, 19 Jun 2018 17:15:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529453748; cv=none; d=google.com; s=arc-20160816; b=Qkf8+DyOnxMieUxLy6+L4K3mRaxxOGbQ9EdAOODIW4qkDDJsGQQ5pVdav1ukc4V70d zJ5pwlfWKKqplLduKgTmejj3xvyz3mMqgq+O5hMZECCsOb9AyCLwGnCok6lyBNdbTGC/ enHJ76Y5R19r8XE83BCNmTST/+Rz8tfMrQHBtuXVceDEylxlsHTaS+UBFwRugHSo0C/N 5pz1IZqAPSFZhWJRosbtvRmThqeouRp8pB2SmeZdoHIG9iMRj1PASm91OdatODc7fz83 qNjpmUSoo1f1af90vnEpVwoPdW78UbmlAmkj2RUuZS2znG2gIjnm6tBAv01P4pMpRIel n4Nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:arc-authentication-results; bh=LxTvOgkxxDOnELK0dY94ib9NYlRVGtxEECxkWtQMxSI=; b=ZETlaqtGd8oLHLWnzeySAEJKTWj9NxpM02AA/euGZkUELyFzyVipOWK90JF1rjnc2X BiwxRmr4i5e6ZUGgEoF6Rb2uQ5Q2FFhBUm5PvV4RfIj1baGA3AL4nhr5y3onR9aamFaO Xc4+zt8AbS07ciJECKdVFnOOw6hsOVkZtLXXxWAnYAaRMkORKYkXGr9e0wY+nE4SFtDf r21DeGP2p2nRpY7wRR0ZUwfhureI1bsLewFLS1EkMPpkcK+LZ/oTaxzAvaq0b0J8IEi/ I9/GsF2EPUV/h/OUqCSqXRd+ByiAhrUX3awGK/7PeSLQ3d5DHHMgoERjHJOTh5ymqJC2 //+g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g14-v6si906247plq.41.2018.06.19.17.15.35; Tue, 19 Jun 2018 17:15:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754009AbeFTANw (ORCPT + 99 others); Tue, 19 Jun 2018 20:13:52 -0400 Received: from ozlabs.org ([203.11.71.1]:36487 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751655AbeFTANu (ORCPT ); Tue, 19 Jun 2018 20:13:50 -0400 Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPSA id 419QKm5c8Yz9s47; Wed, 20 Jun 2018 10:13:48 +1000 (AEST) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au From: Michael Ellerman To: Eric Dumazet , Mathieu Malaterre , "David S. Miller" Cc: Eric Dumazet , linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: Re: [PATCH] Revert "net: pskb_trim_rcsum() and CHECKSUM_COMPLETE are friends" In-Reply-To: References: <20180615185645.8921-1-malat@debian.org> Date: Wed, 20 Jun 2018 10:13:45 +1000 Message-ID: <87muvqwc06.fsf@concordia.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Eric Dumazet writes: > On 06/15/2018 11:56 AM, Mathieu Malaterre wrote: >> This reverts commit 88078d98d1bb085d72af8437707279e203524fa5. >> >> It causes regressions for people using chips driven by the sungem >> driver. Suspicion is that the skb->csum value isn't being adjusted >> properly. >> >> Symptoms as seen on G4+sungem are: >> >> [ 34.023281] eth0: hw csum failure >> [ 34.023438] CPU: 0 PID: 0 Comm: swapper Not tainted 4.17.0+ #2 >> [ 34.023618] Call Trace: >> [ 34.023707] [dffedbd0] [c069ddac] __skb_checksum_complete+0xf0/0x108 (unreliable) >> [ 34.023948] [dffedbf0] [c0777a70] tcp_v4_rcv+0x604/0xe00 >> [ 34.024118] [dffedc70] [c0731624] ip_local_deliver_finish+0xa8/0x3c4 >> [ 34.024315] [dffedcb0] [c0732430] ip_local_deliver+0xf0/0x154 >> [ 34.024493] [dffedcf0] [c07328dc] ip_rcv+0x448/0x774 >> [ 34.024653] [dffedd50] [c06aeae0] __netif_receive_skb_core+0x5e8/0x1184 >> [ 34.024857] [dffedde0] [c06bba20] napi_gro_receive+0x160/0x22c >> [ 34.025044] [dffede10] [e14b2590] gem_poll+0x7fc/0x1ac0 [sungem] >> [ 34.025228] [dffedee0] [c06bacf0] net_rx_action+0x34c/0x618 >> [ 34.025402] [dffedf60] [c07fd27c] __do_softirq+0x16c/0x5f0 >> [ 34.025575] [dffedfd0] [c0064c7c] irq_exit+0x110/0x1a8 >> [ 34.025738] [dffedff0] [c0016170] call_do_irq+0x24/0x3c >> [ 34.025903] [c0cf7e80] [c0009a84] do_IRQ+0x98/0x1a0 >> [ 34.026055] [c0cf7eb0] [c001b474] ret_from_except+0x0/0x14 >> [ 34.026225] --- interrupt: 501 at arch_cpu_idle+0x30/0x78 >> LR = arch_cpu_idle+0x30/0x78 >> [ 34.026510] [c0cf7f70] [c0cf6000] 0xc0cf6000 (unreliable) >> [ 34.026682] [c0cf7f80] [c00a3868] do_idle+0xc4/0x158 >> [ 34.026835] [c0cf7fb0] [c00a3ab0] cpu_startup_entry+0x20/0x28 >> [ 34.027013] [c0cf7fc0] [c0998820] start_kernel+0x47c/0x490 >> [ 34.027181] [c0cf7ff0] [00003444] 0x3444 >> >> See commit 7ce5a27f2ef8 ("Revert "net: Handle CHECKSUM_COMPLETE more >> adequately in pskb_trim_rcsum()."") for previous reference. > > This fix seems to hide a bug in csum functions on this architecture. > > Or a bug on this NIC when receiving a small packet (less than 60 bytes). > Maybe the padding bytes are not included in NIC provided csum, and not 0. Just so I'm clear, this turned out to be a driver/hw problem rather than the arch csum implementation? cheers