Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp9472011rwr; Thu, 11 May 2023 15:50:14 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ72W7IPv+m8NEMSg2oUJTMBRC2zenM1M4roj1GUkJRZLRCK4+RkHCcqztPxrbOTTuQSrA7t X-Received: by 2002:a05:6a20:a10f:b0:ff:b9c4:a0aa with SMTP id q15-20020a056a20a10f00b000ffb9c4a0aamr26847042pzk.48.1683845414370; Thu, 11 May 2023 15:50:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683845414; cv=none; d=google.com; s=arc-20160816; b=w1662sBzH7Vgs8IIJdqo0cMPK+8vRWNFfmZNtjIDniwdc+jPTClxHV2MsnUn45x1BU 0ynw/rV3MzP89s2kS66xwD+D6e4AsSn8uYGrdf1/D1GYqzLVjgwnITvyFL7Kj9dJcdNS XSeSocXN1aVhQKkLna0dfkYwGq2yFNnUUbm10nLGBCIn7QzYjvSKB6kgnufR4+b1loBU pdZk0uWwdlScGxOzDMgaEUxDHAxcPFpOPMJuwzlZF+zZFtQ9edMORJook+LaKQJndQDS j0NWciydrj7JYlfpD5ODwAQU9Py/rW7MAfIMdfdD1cV+Qq8ociZzoatfQbJy43YVD3Vd 3D4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:message-id:subject:cc:to:from:date :dkim-signature; bh=tEIm68dlyVZpr4ZN0BDH5n8MWomc628Qz5J8CbWWsJQ=; b=f5iU9Qs4zisfu2BNjJ6jFwz9ii6HezsN7PyJc/hstt3osN0QATnmtmyr9SH5gWKyQr peGXusnUnzR602KoB64OkHymse+w6yacvrg36uPzboh0uLL1blTsYHGgfGWRB2opMhKi DK4MJ6xFtJApRtdo9m5HULQU8jUKMio5May5BB8eZektQ2DNjsgXMzi10qU1MtuQCUGl 8KSYNiOGDRB4eMRbD+b+nUOM3tkylaz6Boaupelcvu2yuwr5v58aO+0SxTl3laE7NHkm MU5jhrRK77nObQM32Vh0iZgcMkl9vSH9GCkmQstfQjpwT9PhquR8GXaiin0uf4mzDmVy mpTA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ulzjhPJY; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i7-20020a626d07000000b006414f24c5c7si8602938pfc.311.2023.05.11.15.50.00; Thu, 11 May 2023 15:50:14 -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=@kernel.org header.s=k20201202 header.b=ulzjhPJY; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239064AbjEKWVs (ORCPT + 99 others); Thu, 11 May 2023 18:21:48 -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> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 [+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