From patchwork Tue Sep 7 04:15:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kai-Heng Feng X-Patchwork-Id: 1525106 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=jKE9u152; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4H3X463HZxz9sXk; Tue, 7 Sep 2021 14:15:17 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1mNSVr-00051o-2Z; Tue, 07 Sep 2021 04:15:11 +0000 Received: from smtp-relay-canonical-0.internal ([10.131.114.83] helo=smtp-relay-canonical-0.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1mNSVp-00051Z-Kl for kernel-team@lists.ubuntu.com; Tue, 07 Sep 2021 04:15:09 +0000 Received: from localhost.localdomain (1-171-98-108.dynamic-ip.hinet.net [1.171.98.108]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPSA id AD1564015D for ; Tue, 7 Sep 2021 04:15:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1630988109; bh=Zhn3seNK53MyNYA6g/rvgRAf+AKIuvx6vURUe4QG68g=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=jKE9u152hEhpqcU262qI4674Tqnnqy3zFLBgxtBq9uPBoMqnCJj/nwRkEOyzVadbX cy/vN2Bt3QK6yO4azUbTWGdSKASrdPZGUqtWfMMsxe5ukO21oUDs7vAvxsI+pg2ST8 xFEbWu1QLUhXo/5YrL9axYRwo7jGpvQuBkYXbNkDCr/IME/BFLxSXPEQDqSnT4aAnc QvxL2BAzN86RwotzY0TI3SdQhuHTkoUHze+NHRVbFrqggnhb5ysMBNOSjXd5A4QEPZ eKw844inbdzqyZKV9tss03/J3WaZEmgGxXgiHtF8Agj1TNwwm9i48qtceU1YnL92ZM qiy4hFQ4PG5qQ== From: Kai-Heng Feng To: kernel-team@lists.ubuntu.com Subject: [Unstable/OEM-5.13/OEM-5.14] [PATCH 1/1] UBUNTU: SAUCE: r8169: Disable ASPM L1.2 Date: Tue, 7 Sep 2021 12:15:02 +0800 Message-Id: <20210907041502.573623-2-kai.heng.feng@canonical.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210907041502.573623-1-kai.heng.feng@canonical.com> References: <20210907041502.573623-1-kai.heng.feng@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/1942830 There's a r8169 ethernet NIC that has abysmal TX/RX speed, because it requires longer time to exit from ASPM L1.1/L1.2 than it advertises. Changing its LTR to a smaller value doesn't help, so in addition to ASPM L1.1, also disable ASPM L1.2. Signed-off-by: Kai-Heng Feng --- drivers/net/ethernet/realtek/r8169_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c index 32e9ba8efb0ad..93bf8882a3c9a 100644 --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c @@ -5281,7 +5281,7 @@ static int rtl_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) /* Disable ASPM completely as that cause random device stop working * problems as well as full system hangs for some PCIe devices users. */ - rc = pci_disable_link_state(pdev, PCIE_LINK_STATE_L1_1); + rc = pci_disable_link_state(pdev, PCIE_LINK_STATE_L1_1 | PCIE_LINK_STATE_L1_2); tp->aspm_manageable = !rc; /* enable device (incl. PCI PM wakeup and hotplug setup) */