Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp2971173pxb; Tue, 12 Jan 2021 03:13:31 -0800 (PST) X-Google-Smtp-Source: ABdhPJztz05uInre/x0ezf4L8vuYqvWJMZN343PWsd9MPghk/2TqYeDqDU8Y+jW6381cmKT321X9 X-Received: by 2002:a17:906:3685:: with SMTP id a5mr2718138ejc.544.1610450011175; Tue, 12 Jan 2021 03:13:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610450011; cv=none; d=google.com; s=arc-20160816; b=D7wq7AANa9lQxBonU63IFjLK+8mkuAmrUc90q2PyK7DS95m9b1CgvGNIN9TDWSgcak SVxZ+7IQMjBCACDw+F0HgMj4GRkwMXwKRfCxyBfhsO0NuFKKpbk0lsasO9C5n3Nl/ACB RInqTiNfuZvXgsaApzDQc6T5om9k4b/G4XyTvlWy1YO9EPdSIoB8cU3iGPTQKdSfTdEZ UAFrOf+4cZH8dKfZw/UUVMfkC9KUhmwB6ff+uRRYvZ9COSIMOqdWBbCBvzlJHiDbhU/5 Y+39IA/z1OqLIpfl+oYS6LmceEiZo53LeWhPuO/89NEJKN3awICXxMhl6JXo3KGecRNK EswA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:mime-version:message-id:date :sender:dkim-signature; bh=srYruzwMD9dqHYu9mhQyqr32NqB25nzIPSQzatQ9efg=; b=Ti8Orn02++HmcAtWoReYATIHPKIyVhHFPfEKTVsrHXBzQ/L4OyCWnWhsmwCxzKU1bF VspwZ020AYwrsCX6az6mKTyR02buiGpqwqNC0xFBlgBW0gXgz20wv7ey6DZT3gf5qbV7 sTrocpB+7KNRbdgt0PY3pqgbuzRs+t5HSXc30IpsUE0NMrK+8zqHNu+ESPSy2pPHjMIT wGGONzv3m6vOnTmSzQ4Pcp14zdIv2pTsn+rCCCaIVa0+F52hNbMZb8revDpbEbc80BLx 4zZCeRrP0SYv/074UV/LiUmS5Zc432nvPxJ0vGVlABoJ+5FGq3TaPyq9sBc0lvI3WYtL O/yQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=GlT7QDl0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j20si990611ejs.76.2021.01.12.03.13.07; Tue, 12 Jan 2021 03:13:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=GlT7QDl0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727300AbhALECw (ORCPT + 99 others); Mon, 11 Jan 2021 23:02:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43310 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726564AbhALECw (ORCPT ); Mon, 11 Jan 2021 23:02:52 -0500 Received: from mail-qt1-x849.google.com (mail-qt1-x849.google.com [IPv6:2607:f8b0:4864:20::849]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CFFDAC061794 for ; Mon, 11 Jan 2021 20:02:11 -0800 (PST) Received: by mail-qt1-x849.google.com with SMTP id m27so752804qtu.20 for ; Mon, 11 Jan 2021 20:02:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:date:message-id:mime-version:subject:from:to:cc; bh=srYruzwMD9dqHYu9mhQyqr32NqB25nzIPSQzatQ9efg=; b=GlT7QDl0qRuEu0YpYsnP6Nit1RQ2PSu6oMQRj9edkRqFpIMNHxHS0D4KjkAwVNGt2a wT4By/XUh61m9wv3WMvFTHjGmLhk9/iUTr8M9NjgPaiBGNjf6E64E3Tbjw9Uk2Umrtcy OOkEXhcC3QXl27gCjn9gdmkYcK7eY0E4sXmn/ekW6A7N3h7ZzlAwYoGF8mxmy5EJaANt K7ht9E0NdAON+/tZOeJuUMJUFDPakq0rlpKJJU3r1v65FBaUWODTG++dCUqjrvsRfYW6 IQlgtxKKk+3s9maM1s8dXFNyhQ9jviJ5meYp2OTwVb+xKXDO93FNCaxjGDzGeBmChp9g W4IQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:message-id:mime-version:subject:from :to:cc; bh=srYruzwMD9dqHYu9mhQyqr32NqB25nzIPSQzatQ9efg=; b=bVjDNx+HSmH3I+mSyqbopgRV9nCrvP2WJGildDSp9qQ3ZWjmdHQAntcE+MS3c1tGoY ynXFSB+57D9zvI1V8an1ahDjG3DaNu88yetYwfy1AvUUZ8Lg22GXxZgDEC6AQ9/qaEm6 SMLiyHy4+fO4W0jv3DcUpEWtLnSLLRBLdt3HdCd8WJDonTvkZwnKoTPH/KxNj4C+m+aT ehmGfQAhGJiIy7d5ZD2uXzK+DLy4ggElAOPfA24YDTyR76vle2NPUjY0wbucsmWpcB2O /TwA1DYWlSrT+k+lIajeaNuAya9HvNi57KDOdkU8OiBVoEtMPZJddmveCi3HmvGDZEpq x3+A== X-Gm-Message-State: AOAM533tA4lziemTSbdkJukTb1yRjwACYMOZvTnsYOIoV6IzG8WCmuY+ urxjSDBp6EaZdOl0Fsbdip9nVwMPgqTvVH6T Sender: "victording via sendgmr" X-Received: from victording.c.googlers.com ([fda3:e722:ac3:10:24:72f4:c0a8:65c7]) (user=victording job=sendgmr) by 2002:a05:6214:184a:: with SMTP id d10mr2505402qvy.41.1610424130356; Mon, 11 Jan 2021 20:02:10 -0800 (PST) Date: Tue, 12 Jan 2021 04:02:03 +0000 Message-Id: <20210112040205.4117303-1-victording@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.30.0.284.gd98b1dd5eaa7-goog Subject: [PATCH 0/2] Disable ASPM on GL9750 during a suspension From: Victor Ding To: Ulf Hansson , Adrian Hunter Cc: Ben Chuang , Bjorn Helgaas , linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linux-mmc@vger.kernel.org, Victor Ding , Alex Levin , Bjorn Helgaas , Kai-Heng Feng , "Saheed O. Bolarinwa" , Sean Paul , Sukumar Ghorai , Yicong Yang Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org GL9750 SD Host Controller has a 3100us PortTPowerOnTime; however, it enters L1.2 after only ~4us inactivity per PCIe trace. During a suspend/resume process, PCI access operations are frequently longer than 4us apart. Therefore, the device frequently enters and leaves L1.2 during this process, causing longer than desirable suspend/resume time. The total time cost due to this L1.2 exit latency could add up to ~200ms. Considering that PCI access operations are fairly close to each other (though sometimes > 4us), the actual time the device could stay in L1.2 is negligible. Therefore, the little power-saving benefit from ASPM during suspend/resume does not overweight the performance degradation caused by long L1.2 exit latency. Therefore, I am proposing to disable ASPM during a suspend/resume process. Victor Ding (2): PCI/ASPM: Disable ASPM until its LTR and L1ss state is restored mmc: sdhci-pci-gli: Disable ASPM during a suspension drivers/mmc/host/sdhci-pci-core.c | 2 +- drivers/mmc/host/sdhci-pci-gli.c | 46 +++++++++++++++++++++++++++++-- drivers/mmc/host/sdhci-pci.h | 1 + drivers/pci/pci.c | 11 ++++++++ drivers/pci/pci.h | 2 ++ drivers/pci/pcie/aspm.c | 2 +- 6 files changed, 60 insertions(+), 4 deletions(-) -- 2.30.0.284.gd98b1dd5eaa7-goog