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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EB685C77B7C for ; Thu, 11 May 2023 22:21:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239175AbjEKWVt (ORCPT ); Thu, 11 May 2023 18:21:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34468 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238953AbjEKWVr (ORCPT ); Thu, 11 May 2023 18:21:47 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E40A8173D; Thu, 11 May 2023 15:21:46 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 81E726129A; Thu, 11 May 2023 22:21:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BA1F6C433D2; Thu, 11 May 2023 22:21:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1683843705; bh=uEoG19WBzDgFCX22lW5kC0LgLB9V2u85hfxE6ag5YkA=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=ulzjhPJYTRC4uNs09sODz7gu3QFGottnH387NekTYaeDanZxk4OxFmB2gKM/GMAxs FCn7qrmOxH50BGO/Vzxe011AiAvTKpJ3V0ISv/n5VrmHSNNR3yCj1f1hOQ5yyabSt1 O1Urd8vker0uVvCO08/KP7g2HLNIoklU3nneVly6C2Od04TP+qg15vVsAmW5RMsRZh EMEG8QAAhYcJjexZ9VDIuJwBRXr02rP78Vho996NqUH5GnrE+FuF8n/yOTaHUwPX1n h5pFxeFHu5pfl/eWV4vy9xQ2FgeJvzsart6qmgiNXQf3+ZKMf7IfOXCqqgIlXubm1d SUz9wnUay+QtA== Date: Thu, 11 May 2023 17:21:44 -0500 From: Bjorn Helgaas To: Ilpo =?iso-8859-1?Q?J=E4rvinen?= Cc: Lukas Wunner , linux-pci@vger.kernel.org, Rob Herring , Lorenzo Pieralisi , Krzysztof Wilczy?ski , Bjorn Helgaas , LKML , Emmanuel Grumbach , "Rafael J. Wysocki" , Heiner Kallweit Subject: Re: [PATCH 01/17] PCI: Add concurrency safe clear_and_set variants for LNKCTL{,2} Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <13f587b-e937-d546-817d-5fd94443c1eb@linux.intel.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [+cc Emmanuel, Rafael, Heiner] On Thu, May 11, 2023 at 11:28:05PM +0300, Ilpo Järvinen wrote: > ... > One question before I trying to come up something is when PCIEASPM is =n, > should I provide some simple function that just does the LNKCTL write to > disable it? The current pci_disable_link_state() stub when CONFIG_PCIEASPM is unset seems clearly wrong. In fact, it returns *success* when it actually did nothing. I think it should probably clear ASPM Control, at least when the OS has ownership via _OSC. I kind of think it should do that independent of _OSC, but that depends on the conversation at [1]. Bjorn [1] https://lore.kernel.org/r/ZF1dsvJYYnl8Wv0v@bhelgaas