From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2DDFEC433E0 for ; Fri, 19 Jun 2020 14:53:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id EBD00218AC for ; Fri, 19 Jun 2020 14:53:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592578395; bh=YUAEiWEGe5jqokQOiKCUo81Y71KVNrYCtlGnZm3dUVA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=es4AEZSVVy6bNOCOWDVxDaTA/QoNi+gZBcknsZxbJdKYPzNpbTdqNzWEySI/QcFBt PbWtxdJN335ia1Vy/TonXhUKjlopKdWdauqv1mKJC23/cQ11crmb9GYYopJXJSwf2/ zPl1hSOmCxaQfW3Jx8q1IxVKAAyKrJnix6KyIV9o= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389712AbgFSOxM (ORCPT ); Fri, 19 Jun 2020 10:53:12 -0400 Received: from mail.kernel.org ([198.145.29.99]:47418 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389294AbgFSOxJ (ORCPT ); Fri, 19 Jun 2020 10:53:09 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5D215218AC; Fri, 19 Jun 2020 14:53:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592578389; bh=YUAEiWEGe5jqokQOiKCUo81Y71KVNrYCtlGnZm3dUVA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hMjeAzGDd3ye3bazGMpK5Qz/38xRAjHKBBX/319ORz0fgnmQuyIJGyV6EUvUTK5iU iF17JRe34Py1bJmyaYA3Sl4QBreKxHsAE2a65lwyAGX8cANkpGeukw4NJqxyMF0uyu /47g6C9IZUcjviQb8Z3EaJOu6oDgHJ9ukHGKUoGQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kai-Heng Feng , Aaron Brown , Jeff Kirsher Subject: [PATCH 4.14 163/190] e1000e: Disable TSO for buffer overrun workaround Date: Fri, 19 Jun 2020 16:33:28 +0200 Message-Id: <20200619141641.911923484@linuxfoundation.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200619141633.446429600@linuxfoundation.org> References: <20200619141633.446429600@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Kai-Heng Feng commit f29801030ac67bf98b7a65d3aea67b30769d4f7c upstream. Commit b10effb92e27 ("e1000e: fix buffer overrun while the I219 is processing DMA transactions") imposes roughly 30% performance penalty. The commit log states that "Disabling TSO eliminates performance loss for TCP traffic without a noticeable impact on CPU performance", so let's disable TSO by default to regain the loss. CC: stable Fixes: b10effb92e27 ("e1000e: fix buffer overrun while the I219 is processing DMA transactions") BugLink: https://bugs.launchpad.net/bugs/1802691 Signed-off-by: Kai-Heng Feng Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++++ 1 file changed, 4 insertions(+) --- a/drivers/net/ethernet/intel/e1000e/netdev.c +++ b/drivers/net/ethernet/intel/e1000e/netdev.c @@ -5271,6 +5271,10 @@ static void e1000_watchdog_task(struct w /* oops */ break; } + if (hw->mac.type == e1000_pch_spt) { + netdev->features &= ~NETIF_F_TSO; + netdev->features &= ~NETIF_F_TSO6; + } } /* enable transmits in the hardware, need to do this