Received: by 2002:a05:6358:e9c4:b0:b2:91dc:71ab with SMTP id hc4csp4960793rwb; Mon, 8 Aug 2022 09:43:34 -0700 (PDT) X-Google-Smtp-Source: AA6agR4YPcjwpNk9UeYlT9l9KX8z5yTwz55mKPgw4/fG6AHzYBDqLXq2Wp2ySE3n7GHGR5GDQJFW X-Received: by 2002:a05:6a00:428d:b0:52e:6305:14c with SMTP id bx13-20020a056a00428d00b0052e6305014cmr19143053pfb.10.1659977014415; Mon, 08 Aug 2022 09:43:34 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1659977014; cv=pass; d=google.com; s=arc-20160816; b=rW98eUNvaiqwQc4bnX6gC+BXufDo2raaVHNCrgB491SeD91QRSDA8py24uaKbiqFzm U5FmnWqfH5W4piczmu3tyJ2HtX3e2ykH+3ODKdQHGTOgt/jTz67P7Xb77zyySj84nZWM vzzEghImcC1mpG1/ClojsKiOny3M7LtGt0YNGAXAF+KwQ3SbFwNgrv1czPGD+oyY3RTg CNRwvNo7h9b81AHSxlfi2FKdJy+LsH19C0SYL2y0UtliWWZQG7htt/4RVBAHVdSxPEuU ICeVUwSCylrq9lUVsx73YiKN0C9D+DgjQnhnyffEBwA1M2UhzYajvEZOtrOZp/niuy7Q jMrw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :in-reply-to:from:references:cc:to:content-language:subject :user-agent:date:message-id:dkim-signature; bh=AYwMW8q0Z/Fro88mLq9JYK9eBFTT4WZ2CSAhxDCY3HE=; b=CX04DQUykk+P9DcgRSf5mzhvhLfxmMGZndR8xwMuVf+uejA8bp87nTm6+o5Bodr+6M YguhdsgIfBVQNIshSb71jizvZhbbdHhR0ddVAnrfdCrAGqYRu+5Ox1yJV2Qvc4sQTizg 3RenP8OZw7J3bfbdVz0yIbUBgBlTQ6t9+CgKU3E6sguXjHf6y5e20b8f1RJjG4qX/VFZ sZY0KjfXYvRRBOWbxFmfGINDiSlwLqhr7WOiqqyzygqwgLdSybI5AiNIiCf0SQVL9/LM d4Xt8OcSFGPnL5976yDH9uwerzj4w3yIx3H4nPhJndMCio/A1eVmW/l8beBci4DvrnRC NmIw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@Nvidia.com header.s=selector2 header.b=l4FEAK1+; arc=pass (i=1 spf=pass spfdomain=nvidia.com dkim=pass dkdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=nvidia.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x36-20020a634a24000000b0041ae5bf1290si10706840pga.246.2022.08.08.09.43.19; Mon, 08 Aug 2022 09:43:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@Nvidia.com header.s=selector2 header.b=l4FEAK1+; arc=pass (i=1 spf=pass spfdomain=nvidia.com dkim=pass dkdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243932AbiHHQRI (ORCPT + 99 others); Mon, 8 Aug 2022 12:17:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233493AbiHHQRG (ORCPT ); Mon, 8 Aug 2022 12:17:06 -0400 Received: from NAM04-MW2-obe.outbound.protection.outlook.com (mail-mw2nam04on2082.outbound.protection.outlook.com [40.107.101.82]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3FC17E2F; Mon, 8 Aug 2022 09:17:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=g+JQHzjYqZeqoaFo0CzFGG85/okxZqgjdD6F8jNu1LQBRwRO++0NCIbNKCNskrpO0g4qpeHUxA4UXAsBdtAMzht4+iJIZ6z7KTQDecGClzlXFyc3EhIKAywMPFBcxPh2cKLD94o4XQ143xXHzVUmAv7CXz0gGjVuPqzAnO3xvNcafCdB3A322nrYEewJs+M/lvuN0Nv+KI5q4kjh1HwuQiYv+aLqOXaTWRH1I+Yba7Mj4x/tfa7n0bfQf3mbOXCxOdojbroZSGQEf/55wzE4dTsJHKMgnWRpbPJjEH/S1l1rj4TdJ0rIz09CWBuR1SBlvL5P0fYqvIhlA4grVPtW1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=AYwMW8q0Z/Fro88mLq9JYK9eBFTT4WZ2CSAhxDCY3HE=; b=Wku7SD6MIvyWtXUD/TL0OIIyS502n1EGKRSMsbGTCUxQrboQ0piSdX0Ik7fagKRpzDMf3i1K6Q9dTIAM+vZyR84oqL6W+yBSw8ic8OMcmDXbN9tl32gBhU2hjjyzx6Nhrs+AeDK9jzG3ZcBVXnZo9ordrVTv6nFNjAvNkUfJxSkfgmLP7BClUnLcay32ZEHwWlihqxleZqanPpOtV+EUy1njxlueqLShrRTjv16Jp7QYuiNZhmu9wk9Jm43cPfYEWPxawXn/b6EDg+CT3FHYlC2k70AAFHyFKDwej86dzY3xhoxNbXG3DClUPhtfYQbRNxL5GQ5qAy42of19CXj+zw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=AYwMW8q0Z/Fro88mLq9JYK9eBFTT4WZ2CSAhxDCY3HE=; b=l4FEAK1+dQpxKpGpIOO5jIbsWJOWTit+9wFfY4Svp0JhjBS/UW4TGT5/p8K+yvHioL6HF+eAzz9KPyb6J0aY+ibkciw9GdO9lbO2zmkixqgYgoVuz+Yr77PxcStte+s+kFUcKO7jJ+N2/IpenEJqBHx3vPyRiERktg4QAjtxeIsCVdKT7JPRW6beIXkaAMqhznHZcbKIsv3xAUG/S8Pd6rKWCUdicm3NZRPu8SdwdUdud3uiStJhDSiH8TGWnyk9bsVByv7ZXJ7PBKhvE5c4FQnNa0qNjiV8vh7gkBFg93RQXD0TDvLFP6h/6CSxuFrGzIXP/NXy+GhKt2SNjm9qKQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nvidia.com; Received: from BN8PR12MB2900.namprd12.prod.outlook.com (2603:10b6:408:69::18) by CH0PR12MB5251.namprd12.prod.outlook.com (2603:10b6:610:d2::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5504.14; Mon, 8 Aug 2022 16:17:01 +0000 Received: from BN8PR12MB2900.namprd12.prod.outlook.com ([fe80::b150:321c:21e4:40c9]) by BN8PR12MB2900.namprd12.prod.outlook.com ([fe80::b150:321c:21e4:40c9%7]) with mapi id 15.20.5504.020; Mon, 8 Aug 2022 16:17:01 +0000 Message-ID: Date: Mon, 8 Aug 2022 21:46:47 +0530 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.3.2 Subject: Re: [PATCH V2] PCI/ASPM: Save/restore L1SS Capability for suspend/resume Content-Language: en-US To: Lukasz Majczak , Bjorn Helgaas Cc: Rajat Jain , Kai-Heng Feng , Ben Chuang , bhelgaas@google.com, lorenzo.pieralisi@arm.com, refactormyself@gmail.com, kw@linux.com, kenny@panix.com, treding@nvidia.com, jonathanh@nvidia.com, abhsahu@nvidia.com, sagupta@nvidia.com, linux-pci@vger.kernel.org, Linux Kernel Mailing List , kthota@nvidia.com, mmaddireddy@nvidia.com, sagar.tv@gmail.com References: <20220722174212.GA1911979@bhelgaas> <86522aa5-2855-0f73-ddb2-a2b50b2fd1b7@nvidia.com> <8b36f97c-0cc4-3f4a-3b5b-49ad5786d9e9@nvidia.com> From: Vidya Sagar In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-ClientProxiedBy: MA1PR01CA0160.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:71::30) To BN8PR12MB2900.namprd12.prod.outlook.com (2603:10b6:408:69::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b7d0ca66-3898-4bb6-11a0-08da79596cd5 X-MS-TrafficTypeDiagnostic: CH0PR12MB5251:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: =?utf-8?B?Nm8xQTVyMHJBd0NHdUt0MytOSVltSk1RTzdWeTNNOEZJakFyRTlEaUhkNWNu?= =?utf-8?B?Y0dLMUtzTFVxMnlqTllxdis1T1ZOcTJHMU53ZjQ2RkhKejJ3SkNzQm5XSkRI?= =?utf-8?B?SkVneW5kWmFISG1OQ2w4cTVnNUlabVk2c0dvaWg3eThrU3lHZGxDd3JUV1Zk?= =?utf-8?B?dmYrS3FxR1dCb2tsSE9BdjVFRVNYR2pQajk0MGNLTlBuV3djcDJONmZWazZq?= =?utf-8?B?MXp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2?= =?utf-8?B?OCtqTTFTN3AybEd1QlpCQWRJUWlEb2txa2ZpRDJ2cENlUms2ZlpmZlNvYk1m?= =?utf-8?B?S0hXWGExalNLY3dpVk43emU0bnBVK3JPdFg1RzZwTWFUR2U4UTR2SXN3M3RI?= =?utf-8?B?TzFoSkx6V0ZrVXp5TDJONzhYenYwaHNPMU4zWG5pZExlTWlQQVhnOWx3WHF1?= =?utf-8?Q?seh0cbR+2IGgY=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN8PR12MB2900.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(4636009)(376002)(136003)(366004)(396003)(39860400002)(346002)(110136005)(66556008)(36756003)(54906003)(966005)(31686004)(66946007)(66476007)(8676002)(4326008)(86362001)(5660300002)(31696002)(6486002)(8936002)(478600001)(316002)(19627235002)(38100700002)(6666004)(15650500001)(41300700001)(53546011)(6506007)(2906002)(7416002)(30864003)(83380400001)(26005)(2616005)(6512007)(186003)(32563001)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?ODE4dzJ3TjhBVDQwTEZZbVJsZzVDaUNMVng5T1JYRGd6SDBZeis3VFE5Tm5p?= =?utf-8?B?S3FYQTB4TUVRUlg4TDJUdHRGdG9mLzQxdHFleGRvQ2x0Q012dUxHRC9OSStO?= =?utf-8?B?blh3ekhqSzNzcGJubjI4VURBRXZvckVMNEw2WXB1UDVsWm83bjRSdDMrcEdW?= =?utf-8?B?Z3RWZitINnI5V3B6YWN5VkFickh2bjNzWXpvM0pRVWRuWnFBNGc2U1VRWjRw?= =?utf-8?B?LzYrQ1dEMWZRV2tGUlYwT0xuQTM3RWhpaC9ZWnE0dmkzUC9pendodjltZUg2?= =?utf-8?B?WFdScnNObXZhOERvdUplMXgzUFNLODRuK2FJUkZBQ0t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=?utf-8?Q?b81T5KDwOyrjPNw8W4LLdR3y3?= X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-Network-Message-Id: b7d0ca66-3898-4bb6-11a0-08da79596cd5 X-MS-Exchange-CrossTenant-AuthSource: BN8PR12MB2900.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Aug 2022 16:17:01.3955 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ahK5/3oPqG/fh5G31ymlAw4e/uBhIkIFpXrYEmZHen2ZfHgy7CE4Vh+9OfVFrbKVYtZ5sefU04NZHgUuWY0pzg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH0PR12MB5251 X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FORGED_SPF_HELO, NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thanks Lukasz for the update. I think confirms that there is no issue with the patch as such. Bjorn, could you please define the next step for this patch? Thanks, Vidya Sagar On 8/8/2022 7:37 PM, Lukasz Majczak wrote: > External email: Use caution opening links or attachments > > > śr., 3 sie 2022 o 14:55 Vidya Sagar napisał(a): >> >> Thanks Lukasz for the logs. >> I still that the L1SS capability in the root port (00:14.0) disappeared >> after resume. >> I still don't understand how this patch can make the capability register >> itself disappear. Honestly, I still see this as a HW issue. >> Bjorn, could you please throw some light on this? >> >> Thanks, >> Vidya Sagar >> >> On 8/3/2022 5:34 PM, Lukasz Majczak wrote: >>> External email: Use caution opening links or attachments >>> >>> >>> pt., 29 lip 2022 o 16:36 Vidya Sagar napisał(a): >>>> >>>> Hi Lukasz, >>>> Thanks for sharing your observations. >>>> >>>> Could you please also share the output of 'sudo lspci -vvvv' before and >>>> after suspend-resume cycle with the latest linux-next? >>>> Do we still see the L1SS capabilities getting disappeared post resume? >>>> >>>> Thanks, >>>> Vidya Sagar >>>> >>>> On 7/29/2022 3:09 PM, Lukasz Majczak wrote: >>>>> External email: Use caution opening links or attachments >>>>> >>>>> >>>>> wt., 26 lip 2022 o 09:20 Lukasz Majczak napisał(a): >>>>>> >>>>>> wt., 26 lip 2022 o 00:51 Rajat Jain napisał(a): >>>>>>> >>>>>>> Hello, >>>>>>> >>>>>>> On Sat, Jul 23, 2022 at 10:03 AM Vidya Sagar wrote: >>>>>>>> >>>>>>>> Agree with Bjorn's observations. >>>>>>>> The fact that the L1SS capability registers themselves disappeared in >>>>>>>> the root port post resume indicates that there seems to be something >>>>>>>> wrong with the BIOS itself. >>>>>>>> Could you please check from that perspective? >>>>>>> >>>>>>> ChromeOS Intel platforms use S0ix (suspend-to-idle) for suspend. This >>>>>>> is a shallower sleep state that preserves more state than, for e.g. S3 >>>>>>> (suspend-to-RAM). When we use S0ix, then BIOS does not come in picture >>>>>>> at all. i.e. after the kernel runs its suspend routines, it just puts >>>>>>> the CPU into S0ix state. So I do not think there is a BIOS angle to >>>>>>> this. >>>>>>> >>>>>>> >>>>>>>> >>>>>>>> Thanks, >>>>>>>> Vidya Sagar >>>>>>>> >>>>>>>> >>>>>>>> On 7/22/2022 11:12 PM, Bjorn Helgaas wrote: >>>>>>>>> External email: Use caution opening links or attachments >>>>>>>>> >>>>>>>>> >>>>>>>>> On Fri, Jul 22, 2022 at 11:41:14AM +0200, Lukasz Majczak wrote: >>>>>>>>>> pt., 22 lip 2022 o 09:31 Kai-Heng Feng napisał(a): >>>>>>>>>>> On Fri, Jul 15, 2022 at 6:38 PM Ben Chuang wrote: >>>>>>>>>>>> On Tue, Jul 5, 2022 at 2:00 PM Vidya Sagar wrote: >>>>>>>>>>>>> >>>>>>>>>>>>> Previously ASPM L1 Substates control registers (CTL1 and CTL2) weren't >>>>>>>>>>>>> saved and restored during suspend/resume leading to L1 Substates >>>>>>>>>>>>> configuration being lost post-resume. >>>>>>>>>>>>> >>>>>>>>>>>>> Save the L1 Substates control registers so that the configuration is >>>>>>>>>>>>> retained post-resume. >>>>>>>>>>>>> >>>>>>>>>>>>> Signed-off-by: Vidya Sagar >>>>>>>>>>>>> Tested-by: Abhishek Sahu >>>>>>>>>>>> >>>>>>>>>>>> Hi Vidya, >>>>>>>>>>>> >>>>>>>>>>>> I tested this patch on kernel v5.19-rc6. >>>>>>>>>>>> The test device is GL9755 card reader controller on Intel i5-10210U RVP. >>>>>>>>>>>> This patch can restore L1SS after suspend/resume. >>>>>>>>>>>> >>>>>>>>>>>> The test results are as follows: >>>>>>>>>>>> >>>>>>>>>>>> After Boot: >>>>>>>>>>>> #lspci -d 17a0:9755 -vvv | grep -A5 "L1 PM Substates" >>>>>>>>>>>> Capabilities: [110 v1] L1 PM Substates >>>>>>>>>>>> L1SubCap: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ >>>>>>>>>>>> ASPM_L1.1+ L1_PM_Substates+ >>>>>>>>>>>> PortCommonModeRestoreTime=255us >>>>>>>>>>>> PortTPowerOnTime=3100us >>>>>>>>>>>> L1SubCtl1: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ ASPM_L1.1+ >>>>>>>>>>>> T_CommonMode=0us LTR1.2_Threshold=3145728ns >>>>>>>>>>>> L1SubCtl2: T_PwrOn=3100us >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>> After suspend/resume without this patch. >>>>>>>>>>>> #lspci -d 17a0:9755 -vvv | grep -A5 "L1 PM Substates" >>>>>>>>>>>> Capabilities: [110 v1] L1 PM Substates >>>>>>>>>>>> L1SubCap: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ >>>>>>>>>>>> ASPM_L1.1+ L1_PM_Substates+ >>>>>>>>>>>> PortCommonModeRestoreTime=255us >>>>>>>>>>>> PortTPowerOnTime=3100us >>>>>>>>>>>> L1SubCtl1: PCI-PM_L1.2- PCI-PM_L1.1- ASPM_L1.2- ASPM_L1.1- >>>>>>>>>>>> T_CommonMode=0us LTR1.2_Threshold=0ns >>>>>>>>>>>> L1SubCtl2: T_PwrOn=10us >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>> After suspend/resume with this patch. >>>>>>>>>>>> #lspci -d 17a0:9755 -vvv | grep -A5 "L1 PM Substates" >>>>>>>>>>>> Capabilities: [110 v1] L1 PM Substates >>>>>>>>>>>> L1SubCap: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ >>>>>>>>>>>> ASPM_L1.1+ L1_PM_Substates+ >>>>>>>>>>>> PortCommonModeRestoreTime=255us >>>>>>>>>>>> PortTPowerOnTime=3100us >>>>>>>>>>>> L1SubCtl1: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ ASPM_L1.1+ >>>>>>>>>>>> T_CommonMode=0us LTR1.2_Threshold=3145728ns >>>>>>>>>>>> L1SubCtl2: T_PwrOn=3100us >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>> Tested-by: Ben Chuang >>>>>>>>>>> >>>>>>>>>>> Forgot to add mine: >>>>>>>>>>> Tested-by: Kai-Heng Feng >>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>> Best regards, >>>>>>>>>>>> Ben Chuang >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>>> --- >>>>>>>>>>>>> Hi, >>>>>>>>>>>>> Kenneth R. Crudup , Could you please verify this patch >>>>>>>>>>>>> on your laptop (Dell XPS 13) one last time? >>>>>>>>>>>>> IMHO, the regression observed on your laptop with an old version of the patch >>>>>>>>>>>>> could be due to a buggy old version BIOS in the laptop. >>>>>>>>>>>>> >>>>>>>>>>>>> Thanks, >>>>>>>>>>>>> Vidya Sagar >>>>>>>>>>>>> >>>>>>>>>>>>> drivers/pci/pci.c | 7 +++++++ >>>>>>>>>>>>> drivers/pci/pci.h | 4 ++++ >>>>>>>>>>>>> drivers/pci/pcie/aspm.c | 44 +++++++++++++++++++++++++++++++++++++++++ >>>>>>>>>>>>> 3 files changed, 55 insertions(+) >>>>>>>>>>>>> >>>>>>>>>>>>> diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c >>>>>>>>>>>>> index cfaf40a540a8..aca05880aaa3 100644 >>>>>>>>>>>>> --- a/drivers/pci/pci.c >>>>>>>>>>>>> +++ b/drivers/pci/pci.c >>>>>>>>>>>>> @@ -1667,6 +1667,7 @@ int pci_save_state(struct pci_dev *dev) >>>>>>>>>>>>> return i; >>>>>>>>>>>>> >>>>>>>>>>>>> pci_save_ltr_state(dev); >>>>>>>>>>>>> + pci_save_aspm_l1ss_state(dev); >>>>>>>>>>>>> pci_save_dpc_state(dev); >>>>>>>>>>>>> pci_save_aer_state(dev); >>>>>>>>>>>>> pci_save_ptm_state(dev); >>>>>>>>>>>>> @@ -1773,6 +1774,7 @@ void pci_restore_state(struct pci_dev *dev) >>>>>>>>>>>>> * LTR itself (in the PCIe capability). >>>>>>>>>>>>> */ >>>>>>>>>>>>> pci_restore_ltr_state(dev); >>>>>>>>>>>>> + pci_restore_aspm_l1ss_state(dev); >>>>>>>>>>>>> >>>>>>>>>>>>> pci_restore_pcie_state(dev); >>>>>>>>>>>>> pci_restore_pasid_state(dev); >>>>>>>>>>>>> @@ -3489,6 +3491,11 @@ void pci_allocate_cap_save_buffers(struct pci_dev *dev) >>>>>>>>>>>>> if (error) >>>>>>>>>>>>> pci_err(dev, "unable to allocate suspend buffer for LTR\n"); >>>>>>>>>>>>> >>>>>>>>>>>>> + error = pci_add_ext_cap_save_buffer(dev, PCI_EXT_CAP_ID_L1SS, >>>>>>>>>>>>> + 2 * sizeof(u32)); >>>>>>>>>>>>> + if (error) >>>>>>>>>>>>> + pci_err(dev, "unable to allocate suspend buffer for ASPM-L1SS\n"); >>>>>>>>>>>>> + >>>>>>>>>>>>> pci_allocate_vc_save_buffers(dev); >>>>>>>>>>>>> } >>>>>>>>>>>>> >>>>>>>>>>>>> diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h >>>>>>>>>>>>> index e10cdec6c56e..92d8c92662a4 100644 >>>>>>>>>>>>> --- a/drivers/pci/pci.h >>>>>>>>>>>>> +++ b/drivers/pci/pci.h >>>>>>>>>>>>> @@ -562,11 +562,15 @@ void pcie_aspm_init_link_state(struct pci_dev *pdev); >>>>>>>>>>>>> void pcie_aspm_exit_link_state(struct pci_dev *pdev); >>>>>>>>>>>>> void pcie_aspm_pm_state_change(struct pci_dev *pdev); >>>>>>>>>>>>> void pcie_aspm_powersave_config_link(struct pci_dev *pdev); >>>>>>>>>>>>> +void pci_save_aspm_l1ss_state(struct pci_dev *dev); >>>>>>>>>>>>> +void pci_restore_aspm_l1ss_state(struct pci_dev *dev); >>>>>>>>>>>>> #else >>>>>>>>>>>>> static inline void pcie_aspm_init_link_state(struct pci_dev *pdev) { } >>>>>>>>>>>>> static inline void pcie_aspm_exit_link_state(struct pci_dev *pdev) { } >>>>>>>>>>>>> static inline void pcie_aspm_pm_state_change(struct pci_dev *pdev) { } >>>>>>>>>>>>> static inline void pcie_aspm_powersave_config_link(struct pci_dev *pdev) { } >>>>>>>>>>>>> +static inline void pci_save_aspm_l1ss_state(struct pci_dev *dev) { } >>>>>>>>>>>>> +static inline void pci_restore_aspm_l1ss_state(struct pci_dev *dev) { } >>>>>>>>>>>>> #endif >>>>>>>>>>>>> >>>>>>>>>>>>> #ifdef CONFIG_PCIE_ECRC >>>>>>>>>>>>> diff --git a/drivers/pci/pcie/aspm.c b/drivers/pci/pcie/aspm.c >>>>>>>>>>>>> index a96b7424c9bc..2c29fdd20059 100644 >>>>>>>>>>>>> --- a/drivers/pci/pcie/aspm.c >>>>>>>>>>>>> +++ b/drivers/pci/pcie/aspm.c >>>>>>>>>>>>> @@ -726,6 +726,50 @@ static void pcie_config_aspm_l1ss(struct pcie_link_state *link, u32 state) >>>>>>>>>>>>> PCI_L1SS_CTL1_L1SS_MASK, val); >>>>>>>>>>>>> } >>>>>>>>>>>>> >>>>>>>>>>>>> +void pci_save_aspm_l1ss_state(struct pci_dev *dev) >>>>>>>>>>>>> +{ >>>>>>>>>>>>> + int aspm_l1ss; >>>>>>>>>>>>> + struct pci_cap_saved_state *save_state; >>>>>>>>>>>>> + u32 *cap; >>>>>>>>>>>>> + >>>>>>>>>>>>> + if (!pci_is_pcie(dev)) >>>>>>>>>>>>> + return; >>>>>>>>>>>>> + >>>>>>>>>>>>> + aspm_l1ss = pci_find_ext_capability(dev, PCI_EXT_CAP_ID_L1SS); >>>>>>>>>>>>> + if (!aspm_l1ss) >>>>>>>>>>>>> + return; >>>>>>>>>>>>> + >>>>>>>>>>>>> + save_state = pci_find_saved_ext_cap(dev, PCI_EXT_CAP_ID_L1SS); >>>>>>>>>>>>> + if (!save_state) >>>>>>>>>>>>> + return; >>>>>>>>>>>>> + >>>>>>>>>>>>> + cap = (u32 *)&save_state->cap.data[0]; >>>>>>>>>>>>> + pci_read_config_dword(dev, aspm_l1ss + PCI_L1SS_CTL2, cap++); >>>>>>>>>>>>> + pci_read_config_dword(dev, aspm_l1ss + PCI_L1SS_CTL1, cap++); >>>>>>>>>>>>> +} >>>>>>>>>>>>> + >>>>>>>>>>>>> +void pci_restore_aspm_l1ss_state(struct pci_dev *dev) >>>>>>>>>>>>> +{ >>>>>>>>>>>>> + int aspm_l1ss; >>>>>>>>>>>>> + struct pci_cap_saved_state *save_state; >>>>>>>>>>>>> + u32 *cap; >>>>>>>>>>>>> + >>>>>>>>>>>>> + if (!pci_is_pcie(dev)) >>>>>>>>>>>>> + return; >>>>>>>>>>>>> + >>>>>>>>>>>>> + aspm_l1ss = pci_find_ext_capability(dev, PCI_EXT_CAP_ID_L1SS); >>>>>>>>>>>>> + if (!aspm_l1ss) >>>>>>>>>>>>> + return; >>>>>>>>>>>>> + >>>>>>>>>>>>> + save_state = pci_find_saved_ext_cap(dev, PCI_EXT_CAP_ID_L1SS); >>>>>>>>>>>>> + if (!save_state) >>>>>>>>>>>>> + return; >>>>>>>>>>>>> + >>>>>>>>>>>>> + cap = (u32 *)&save_state->cap.data[0]; >>>>>>>>>>>>> + pci_write_config_dword(dev, aspm_l1ss + PCI_L1SS_CTL2, *cap++); >>>>>>>>>>>>> + pci_write_config_dword(dev, aspm_l1ss + PCI_L1SS_CTL1, *cap++); >>>>>>>>>>>>> +} >>>>>>>>>>>>> + >>>>>>>>>>>>> static void pcie_config_aspm_dev(struct pci_dev *pdev, u32 val) >>>>>>>>>>>>> { >>>>>>>>>>>>> pcie_capability_clear_and_set_word(pdev, PCI_EXP_LNKCTL, >>>>>>>>>>>>> -- >>>>>>>>>>>>> 2.17.1 >>>>>>>>>>>>> >>>>>>>>>> >>>>>>>>>> Hi, >>>>>>>>>> >>>>>>>>>> With this patch (and also mentioned >>>>>>>>>> https://lore.kernel.org/all/20220509073639.2048236-1-kai.heng.feng@canonical.com/) >>>>>>>>>> applied on 5.10 (chromeos-5.10) I am observing problems after >>>>>>>>>> suspend/resume with my WiFi card - it looks like whole communication >>>>>>>>>> via PCI fails. Attaching logs (dmesg, lspci -vvv before suspend/resume >>>>>>>>>> and after) https://gist.github.com/semihalf-majczak-lukasz/fb36dfa2eff22911109dfb91ab0fc0e3 >>>>>>>>>> >>>>>>>>>> I played a little bit with this code and it looks like the >>>>>>>>>> pci_write_config_dword() to the PCI_L1SS_CTL1 breaks it (don't know >>>>>>>>>> why, not a PCI expert). >>>>>>>>> >>>>>>>>> Thanks a lot for testing this! I'm not quite sure what to make of the >>>>>>>>> results since v5.10 is fairly old (Dec 2020) and I don't know what >>>>>>>>> other changes are in chromeos-5.10. >>>>>>> >>>>>>> Lukasz: I assume you are running this on Atlas and are seeing this bug >>>>>>> when uprev'ving it to 5.10 kernel. Can you please try it on a newer >>>>>>> Intel platform that have the latest upstream kernel running already >>>>>>> and see if this can be reproduced there too? >>>>>>> Note that the wifi PCI device is different on newer Intel platforms, >>>>>>> but platform design is similar enough that I suspect we should see >>>>>>> similar bug on those too. The other option is to try the latest >>>>>>> ustream kernel on Atlas. Perhaps if we just care about wifi (and >>>>>>> ignore bringing up the graphics stack and GUI), it may come up >>>>>>> sufficiently enough to try this patch? >>>>>>> >>>>>>> Thanks, >>>>>>> >>>>>>> Rajat >>>>>>> >>>>>>> >>>>>>>>> >>>>>>>>> Random observations, no analysis below. This from your dmesg >>>>>>>>> certainly looks like PCI reads failing and returning ~0: >>>>>>>>> >>>>>>>>> Timeout waiting for hardware access (CSR_GP_CNTRL 0xffffffff) >>>>>>>>> iwlwifi 0000:01:00.0: 00000000: ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff >>>>>>>>> iwlwifi 0000:01:00.0: Device gone - attempting removal >>>>>>>>> Hardware became unavailable upon resume. This could be a software issue prior to suspend or a hardware issue. >>>>>>>>> >>>>>>>>> And then we re-enumerate 01:00.0 and it looks like it may have been >>>>>>>>> reset (BAR is 0): >>>>>>>>> >>>>>>>>> pci 0000:01:00.0: [8086:095a] type 00 class 0x028000 >>>>>>>>> pci 0000:01:00.0: reg 0x10: [mem 0x00000000-0x00001fff 64bit] >>>>>>>>> >>>>>>>>> lspci diffs from before/after suspend: >>>>>>>>> >>>>>>>>> 00:14.0 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port B #1 (rev fb) (prog-if 00 [Normal decode]) >>>>>>>>> Bus: primary=00, secondary=01, subordinate=01, sec-latency=64 >>>>>>>>> - DevSta: CorrErr- NonFatalErr+ FatalErr- UnsupReq+ AuxPwr+ TransPend- >>>>>>>>> + DevSta: CorrErr+ NonFatalErr- FatalErr- UnsupReq- AuxPwr+ TransPend- >>>>>>>>> - LnkCtl: ASPM L1 Enabled; RCB 64 bytes, Disabled- CommClk+ >>>>>>>>> + LnkCtl: ASPM Disabled; RCB 64 bytes, Disabled- CommClk+ >>>>>>>>> - LnkSta2: Current De-emphasis Level: -6dB, EqualizationComplete- EqualizationPhase1- >>>>>>>>> + LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete- EqualizationPhase1- >>>>>>>>> - Capabilities: [150 v0] Null >>>>>>>>> - Capabilities: [200 v1] L1 PM Substates >>>>>>>>> - L1SubCap: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ ASPM_L1.1+ L1_PM_Substates+ >>>>>>>>> - PortCommonModeRestoreTime=40us PortTPowerOnTime=10us >>>>>>>>> - L1SubCtl1: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ ASPM_L1.1+ >>>>>>>>> - T_CommonMode=40us LTR1.2_Threshold=98304ns >>>>>>>>> - L1SubCtl2: T_PwrOn=60us >>>>>>>>> >>>>>>>>> The DevSta differences might be BIOS bugs, probably not relevant. >>>>>>>>> Interesting that ASPM is disabled, maybe didn't get enabled after >>>>>>>>> re-enumerating 01:00.0? Strange that the L1 PM Substates capability >>>>>>>>> disappeared. >>>>>>>>> >>>>>>>>> 01:00.0 Network controller: Intel Corporation Wireless 7265 (rev 59) >>>>>>>>> LnkCtl: ASPM L1 Enabled; RCB 64 bytes, Disabled- CommClk+ >>>>>>>>> - ExtSynch- ClockPM+ AutWidDis- BWInt- AutBWInt- >>>>>>>>> + ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt- >>>>>>>>> Capabilities: [154 v1] L1 PM Substates >>>>>>>>> L1SubCap: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ ASPM_L1.1+ L1_PM_Substates+ >>>>>>>>> PortCommonModeRestoreTime=30us PortTPowerOnTime=60us >>>>>>>>> - L1SubCtl1: PCI-PM_L1.2+ PCI-PM_L1.1+ ASPM_L1.2+ ASPM_L1.1+ >>>>>>>>> - T_CommonMode=0us LTR1.2_Threshold=98304ns >>>>>>>>> + L1SubCtl1: PCI-PM_L1.2- PCI-PM_L1.1- ASPM_L1.2- ASPM_L1.1- >>>>>>>>> + T_CommonMode=0us LTR1.2_Threshold=0ns >>>>>>>>> >>>>>>>>> Dmesg claimed we reconfigured common clock config. Maybe ASPM didn't >>>>>>>>> get reinitialized after re-enumeration? Looks like we didn't restore >>>>>>>>> L1SubCtl1. >>>>>>>>> >>>>>>>>> Bjorn >>>>>>>>> >>>>>> >>>>>> Hi, >>>>>> >>>>>> Thank you all for the response and input! As Rajat mentioned I'm using >>>>>> chromebook - but not Atlas (Amberlake) - in this case it is Babymega >>>>>> (Apollolake) - I will try to load most recent kernel and give it a >>>>>> try once again. >>>>>> >>>>>> Best regards, >>>>>> Lukasz >>>>> >>>>> Hi, >>>>> >>>>> I have applied this patch on top of v5.19-rc7 (chromeos) and I'm >>>>> still getting same results: >>>>> https://gist.github.com/semihalf-majczak-lukasz/4b716704c21a3758d6711b2030ea34b9 >>>>> >>>>> Best regards, >>>>> Lukasz >>>>> >>> Hi Vidya, >>> >>> Sorry for the long delay, I have retested your patch on top of >>> linux-next/master (next-20220802) - the results for my device remain >>> the same. >>> Here are the logs (lspci -vvv before suspend, lspci -vvv after resume and dmesg) >>> https://gist.github.com/semihalf-majczak-lukasz/c7bfd811359f23278034056a8002b3ef >>> Let me know if you need any more logs and/or tests. >>> >>> Best regards, >>> Lukasz >>> > Hi Vidya, > > After your last email, I've re-tested my setup and (without your > patch) the capability register also disappears - so it looks there is > - in fact - some problem in my setup and your patch just brings it to > the top as after resume tries to write to a register that is no longer > present. I'm very sorry for the confusion here and I've not notice > that at the very beginning. > > Best regards, > Lukasz >