From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Axtens Subject: Re: [PATCH v2] bnx2x: disable GSO where gso_size is too big for hardware Date: Tue, 16 Jan 2018 11:12:44 +1100 Message-ID: <87k1wiirur.fsf@linkitivity.dja.id.au> References: <20180111235905.10110-1-dja@axtens.net> <20180115.140635.2227899396084253886.davem@davemloft.net> Mime-Version: 1.0 Content-Type: text/plain Cc: netdev@vger.kernel.org, tlfalcon@linux.vnet.ibm.com, Yuval.Mintz@cavium.com To: David Miller Return-path: Received: from mail-pf0-f169.google.com ([209.85.192.169]:37494 "EHLO mail-pf0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750716AbeAPAMu (ORCPT ); Mon, 15 Jan 2018 19:12:50 -0500 Received: by mail-pf0-f169.google.com with SMTP id p1so8788693pfh.4 for ; Mon, 15 Jan 2018 16:12:50 -0800 (PST) In-Reply-To: <20180115.140635.2227899396084253886.davem@davemloft.net> Sender: netdev-owner@vger.kernel.org List-ID: David Miller writes: > From: Daniel Axtens > Date: Fri, 12 Jan 2018 10:59:05 +1100 > >> If a bnx2x card is passed a GSO packet with a gso_size larger than >> ~9700 bytes, it will cause a firmware error that will bring the card >> down: >> >> bnx2x: [bnx2x_attn_int_deasserted3:4323(enP24p1s0f0)]MC assert! >> bnx2x: [bnx2x_mc_assert:720(enP24p1s0f0)]XSTORM_ASSERT_LIST_INDEX 0x2 >> bnx2x: [bnx2x_mc_assert:736(enP24p1s0f0)]XSTORM_ASSERT_INDEX 0x0 = 0x00000000 0x25e43e47 0x00463e01 0x00010052 >> bnx2x: [bnx2x_mc_assert:750(enP24p1s0f0)]Chip Revision: everest3, FW Version: 7_13_1 >> ... (dump of values continues) ... >> >> Detect when gso_size + header length is greater than the maximum >> packet size (9700 bytes) and disable GSO. For simplicity and speed >> this is approximated by comparing gso_size against 9200 and assuming >> no-one will have more than 500 bytes of headers. > > What is the MTU size configured on the bnx2x device when these 9700 > byte packets are seen? > > If it's less than 9700, whatever is allowing your device (openvswitch, > ibmveth, whatever) needs to be fixed. Sure, I had an approach that checks the gso_size in is_skb_forwardable and the equivalent openvswitch path - I'll send that. Regards, Daniel > > I don't like this at all, quite frankly. We'll have one device now that > has this special check, probably many others can run into this situation > as well but they won't be used on these kinds of powerpc boxes and > therefore nobody is going to notice. > > I'm not applying this without more information or better justification, > sorry.