From patchwork Mon May 22 20:00:30 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 685391 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 2B63FC7EE23 for ; Mon, 22 May 2023 20:01:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232003AbjEVUBN (ORCPT ); Mon, 22 May 2023 16:01:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50984 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231236AbjEVUBL (ORCPT ); Mon, 22 May 2023 16:01:11 -0400 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (mail-mw2nam10on2081.outbound.protection.outlook.com [40.107.94.81]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F3660A3; Mon, 22 May 2023 13:01:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Hu5pvUEqfgpe1mnZpZoiJtiY2oOytMEzZZ6G2/txTBqIiwu8l3Rf7eRnzUCj6aJZ3plLUce6+z3MDKK3atpiJFC4t+1hU1QEjIpTCNZ0Kk6aF8VOAvgXbDOM/QMJbDesTxsIZtXqwfCpzEjhIca5gswEKJcsuvqSSiqyFdfC0kZFc2bhMbv0o+5qpLOfA+J8G+zYcqqFtpgIkhM+0qf8wbFaQWSTIOQHhE2Cg3Yjjw8hIwwG6Ez1HEWNG01dihIkPaQXixvynoUfXUk05gW1Fulm1BGIqrppTXyHmFfYCJpfMkjN1nEqiZymEPhzSzQ9uRwlcIpTD4YaEoZASIzJ2w== 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=ubPxSYLQGxhGoWRcu44ovgwIBi2Oo1TW3ZlBkvAqxpU=; b=SD5W2Tfqg5ieESe7Qak+6raTAqmtk4RwIra8WjhL8OVHegXPXhFggXALy6R7RS6JRohCBRNCvw8qgL7KM5QZJJaDbSorTkgIqIV7/zI6NOi2W0Y/d1gGIiqZXK/VKzW5N7CjwYFJBGnYYmH3DlJ3/ZfF7gx3ro4MuNGUMFwScwI+/wvPhVU9TvkPvG2f9gUqKGxDzerDkN6eoGXkPku9qoU+VADXe3Lt/WQGbGHRHYfK9ba3ziQxIj5wzqqNu5WREAZ2NcXTDVXLAehPC2SUm93QJ2jectueAZRk7msRJsTSjrf0FDkU+sMWtqGOH25soJN4x0w08TwaM0yswFwRaA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ubPxSYLQGxhGoWRcu44ovgwIBi2Oo1TW3ZlBkvAqxpU=; b=dgikT8MRgjf5ozdDVVeUVwuI45y+p2WRKC0+QkaLvx/qhGlBZkxiprwW8I4QSxatqlanYBpiP73VkOSFIcH+d9b96LS3+z3O5bnnLF80Gv0X6J9gOX4wLWfvR6eCBudt+SnjrevqPQtYGjFbMQAPz2SsfUPObu1OfWcy9DAI9tc= Received: from MW4PR03CA0179.namprd03.prod.outlook.com (2603:10b6:303:8d::34) by DS0PR12MB8768.namprd12.prod.outlook.com (2603:10b6:8:14f::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28; Mon, 22 May 2023 20:01:07 +0000 Received: from CO1NAM11FT060.eop-nam11.prod.protection.outlook.com (2603:10b6:303:8d:cafe::63) by MW4PR03CA0179.outlook.office365.com (2603:10b6:303:8d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:07 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT060.mail.protection.outlook.com (10.13.175.132) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:06 +0000 Received: from SITE-L-T34-2.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Mon, 22 May 2023 15:01:04 -0500 From: Mario Limonciello To: , , CC: , , , , , , , Mario Limonciello Subject: [PATCH v2 1/4] include/linux/suspend.h: Only show pm_pr_dbg messages at suspend/resume Date: Mon, 22 May 2023 15:00:30 -0500 Message-ID: <20230522200033.2605-1-mario.limonciello@amd.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1NAM11FT060:EE_|DS0PR12MB8768:EE_ X-MS-Office365-Filtering-Correlation-Id: 2bb469ce-ddb1-4ba6-6f59-08db5aff47ca X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: tYWlnN2I89r0gMTnjkhwoS8rjNk+ODi51F3uYt7Z0IhD1D3dIzaRqnIuMk1coXp3tL1f1SkClQmQF0zU3wOA6cvMnhkBfekbXwbybkXN05Lu6mYXXBDflxKzJ8IovwXEBhz4cE+fJyU8LMtNIPOOJIHDUhwNxyw1wHrFcBvnkPh/jIVlvxRNsUVV1yUBJdyiofCgPadPV4ALuEWonACcBdhq67trn3DoKPY8SN8pJwKav51m7waFB/0gGPTMz+S/JucZGIlVYtj5zPcOkZVnP0CvEyPRDhfXWBjYZzZ/t1Eg3xtzrz6XOs0sV4gn0/HuxCHxQmEckAIJ7BUzhYFUnPlo0Jfp4FJboC5dwqV2glIBGdVR9GEoD8P3RugelE5rclTUtWDKFW8bZZom9H0s6YwNfcM+HNHAcSeBiWtD+coObsmRbHkRMHHJrh+Q7+sucxIFvScxbROYs62t6AXjHIGC5SWeP+D/3qZVvi1Mn0Vcs5jC4JhBZNKuk6Gv8YyK0cWFcAfnxZ8Zdqapgp5pJmteG7zs+IzUxmqj7oLDG+lF+WGs71yZ+EVQ29yVZLw3Njsq88hKcwwzSHc9QVNkp30SW0xfAheKtC3I5olzwuLZhqYaCihLH0y+taouM6LeA0HL/jv68r6RZv3jDrA4vJ05NLhMm6FMnwgsRHGIZ5qsKPNi8Y8Qfh+xju4gHLoCmHVjjws6BQ7ytLxwFlFKfMNFTHt5Yf/ovHaUOgM/cQC10oH2OfGIhYVWpnwOkIyp2QTGpTgZ7s47Jy3u+iYf2A== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(346002)(376002)(136003)(39860400002)(396003)(451199021)(36840700001)(46966006)(40470700004)(8936002)(8676002)(47076005)(5660300002)(44832011)(36860700001)(82310400005)(83380400001)(186003)(16526019)(1076003)(86362001)(2616005)(26005)(81166007)(356005)(82740400003)(426003)(336012)(40460700003)(41300700001)(6666004)(7696005)(40480700001)(70206006)(70586007)(316002)(4326008)(36756003)(478600001)(110136005)(54906003)(2906002)(15650500001)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 May 2023 20:01:06.9104 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2bb469ce-ddb1-4ba6-6f59-08db5aff47ca X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT060.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR12MB8768 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org All uses in the kernel are currently already oriented around suspend/resume. As some other parts of the kernel may also use these messages in functions that could also be used outside of suspend/resume, only enable in suspend/resume path. Signed-off-by: Mario Limonciello --- include/linux/suspend.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) base-commit: 42dfdd08422dec99bfe526072063f65c0b9fb7d2 diff --git a/include/linux/suspend.h b/include/linux/suspend.h index d0d4598a7b3f..a40f2e667e09 100644 --- a/include/linux/suspend.h +++ b/include/linux/suspend.h @@ -564,7 +564,8 @@ static inline int pm_dyn_debug_messages_on(void) #endif #define __pm_pr_dbg(fmt, ...) \ do { \ - if (pm_debug_messages_on) \ + if (pm_debug_messages_on && \ + pm_suspend_target_state != PM_SUSPEND_ON) \ printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__); \ else if (pm_dyn_debug_messages_on()) \ pr_debug(fmt, ##__VA_ARGS__); \ @@ -589,7 +590,8 @@ static inline int pm_dyn_debug_messages_on(void) /** * pm_pr_dbg - print pm sleep debug messages * - * If pm_debug_messages_on is enabled, print message. + * If pm_debug_messages_on is enabled and the system is entering/leaving + * suspend, print message. * If pm_debug_messages_on is disabled and CONFIG_DYNAMIC_DEBUG is enabled, * print message only from instances explicitly enabled on dynamic debug's * control. From patchwork Mon May 22 20:00:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 684740 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 757FAC7EE2F for ; Mon, 22 May 2023 20:01:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235528AbjEVUBO (ORCPT ); Mon, 22 May 2023 16:01:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50986 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232065AbjEVUBM (ORCPT ); Mon, 22 May 2023 16:01:12 -0400 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2081.outbound.protection.outlook.com [40.107.223.81]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 351B5A9; Mon, 22 May 2023 13:01:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mmWKynsXaphW52QVHgF3PMbSffgsYhLsIeX6YkpVB22uB5c3zW+jNcisBrslpmaVIet5UdGLK8heD/7FGpEcD5cSlZsuqeB2UhKx7HhFF9cosWbzZ1KJzVljfUeewtRDGj+zj1fkC0zIzmbcIZ2TKw9JquBYXnww7nI8bKHqkbXgUykMEsLdOcRtba+h6+a1sc4JvdETi/V6O4d+J2Z/r7kRRvJt/pZjn8ilG5iC+GSigIxpoELsM8US+oqLao3gJ8mGiKpWPrAhtWy5b7c/XNwhkgX36fqwCMEq/ER9B9Q2zHucKTXH8jJdzEKCI4aZVnTKTGQHyuB536f4wtUHJw== 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=6rLIPJ9+GBmoUs4o3I512F7rTUPbSUhKwVHw9JjZSDI=; b=BSiBUPoCeCdrDSHfocJFnx8amqnc379ChF9NbQWAlth0+EO78akQG6gPLbeNN961EiFksUm+iusH81iQvChn+NiXcAAGLkEWK+FqdzE9uHgqF7PbTJ2iGRH2VtFp98O7cOK+7h+LI6MvYDO8i6FdFM8+hOaRqDQQjJ7m/cfNBS6pWxf3AmmaUT3iZj6EKcakx7xzhep3nicUwjenMcU1P5fKEzY61A+tTJZh6iZTQLSHsGhAWdFikDapOgOsYUUE5KMjRP/Cn54jciB+G+wSicPd2Dly7MUb+HtBat2juppjsEwJyx2FuEpDlL66DVLnIb+w1cViV7YZy05lqlV8Fg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=6rLIPJ9+GBmoUs4o3I512F7rTUPbSUhKwVHw9JjZSDI=; b=RBsTTjHLa4UMsYScStOgBWmPeyV2vikfCIF3R7ik+kPwqF2E8r3ARjrVLc9gAQ9usn1A9EFYrgZlG8kGAfMgDbU3mOPZ4PVyugDPijwbosFljSOU6cZb+cVS8OC1b5/PP0L4jfpmRxpY47OiJrF5gRjF94A8BRSjghmahU7SxuA= Received: from MW4PR03CA0165.namprd03.prod.outlook.com (2603:10b6:303:8d::20) by CY5PR12MB6154.namprd12.prod.outlook.com (2603:10b6:930:26::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28; Mon, 22 May 2023 20:01:07 +0000 Received: from CO1NAM11FT060.eop-nam11.prod.protection.outlook.com (2603:10b6:303:8d:cafe::32) by MW4PR03CA0165.outlook.office365.com (2603:10b6:303:8d::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:07 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT060.mail.protection.outlook.com (10.13.175.132) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:07 +0000 Received: from SITE-L-T34-2.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Mon, 22 May 2023 15:01:06 -0500 From: Mario Limonciello To: , , CC: , , , , , , , Mario Limonciello Subject: [PATCH v2 2/4] ACPI: x86: Add pm_debug_messages for LPS0 _DSM state tracking Date: Mon, 22 May 2023 15:00:31 -0500 Message-ID: <20230522200033.2605-2-mario.limonciello@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230522200033.2605-1-mario.limonciello@amd.com> References: <20230522200033.2605-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1NAM11FT060:EE_|CY5PR12MB6154:EE_ X-MS-Office365-Filtering-Correlation-Id: 4fc1f980-b154-4540-559c-08db5aff4833 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Yw7c1XgyjF+24pVVEwp+n2+suK+zcNpdRTUpWH5lrUtbGcpk5lRLl3nSYMNSrRbSwr0ukOcFYW3FCUKeRK77EVFumA8k+vsrar4R/Z1mDppfG0N4gFiCzr6VyOKi8aydSCSdt1eaZ68pJGB8tFwkEK8JopPLuL984x40EVS+rghSUXVpTx2Rbi2lJNIWwIT3yoFd6Z4XGga3Tjt46vg/mifglwkYeAus0Yu3jhTtQaHOu2AAhji5d4DoJrsedvPEA4HQhB1465Crv6ynUtEtwGckkYaOtav9+d1ZNebZOuPfQ6FD7VnkSPu+ZAeOPG4Gnqayssuh0u1DpXa4R0ISKFv2QfjqLRjihCMD1YL/q7/YLKwtIUWmKiPz5wnQzfV3Zja25mx8GwhL3D8YdBFK87Q5eHrqlUOLpZeTmkn74SwAewYmgKMYRiUXRtRd7CUwi3YChSm3u8pGfKMFzBzX5ydGzSXngjkX4xxQIN3LDkKXBX9bWEaDmSynvBVmROUq9bZ75PpLqo+QAATlkAb5AutT4o/+s6lKbXZa0Pwkd9roTUimOXolYlvxSUop6XwYRm6zOU08fZnj7dxPcAQvI/dAbWGc/h6LANTVAHU6vkMRrv9V5S2LHIYjr7cNaM5Ik0gbVdAYh12sQLW7geU/HpPxkfuWIEwY5yYfvsK3W5tnTLT/nto8gmP9Y8FScAbJMqzR/Vy/OjP784SlfY8sjXyKFB2w59Z5P3+SEXzxzBmNNQg4klxIxIOSnmkC/a3q2J+G2soKQvnMMuHcT8EO/Q== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(39860400002)(346002)(136003)(396003)(376002)(451199021)(46966006)(40470700004)(36840700001)(8936002)(8676002)(47076005)(5660300002)(44832011)(36860700001)(82310400005)(16526019)(186003)(83380400001)(426003)(26005)(81166007)(2616005)(1076003)(86362001)(82740400003)(336012)(356005)(40460700003)(41300700001)(7696005)(40480700001)(45080400002)(6666004)(70206006)(70586007)(316002)(4326008)(36756003)(478600001)(54906003)(110136005)(2906002)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 May 2023 20:01:07.5978 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 4fc1f980-b154-4540-559c-08db5aff4833 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT060.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY5PR12MB6154 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org Enabling debugging messages for the state requires turning on dynamic debugging for the file. To make it more accessible, use `pm_debug_messages` and clearer strings for what is happening. Signed-off-by: Mario Limonciello --- v1->v2: * Remove an unnecessary stray semicolon drivers/acpi/x86/s2idle.c | 52 ++++++++++++++++++++++++++++++++++----- 1 file changed, 46 insertions(+), 6 deletions(-) diff --git a/drivers/acpi/x86/s2idle.c b/drivers/acpi/x86/s2idle.c index e499c60c4579..7681f6ecab67 100644 --- a/drivers/acpi/x86/s2idle.c +++ b/drivers/acpi/x86/s2idle.c @@ -59,6 +59,7 @@ static int lps0_dsm_func_mask; static guid_t lps0_dsm_guid_microsoft; static int lps0_dsm_func_mask_microsoft; +static int lps0_dsm_state; /* Device constraint entry structure */ struct lpi_device_info { @@ -320,6 +321,44 @@ static void lpi_check_constraints(void) } } +static bool acpi_s2idle_vendor_amd(void) +{ + return boot_cpu_data.x86_vendor == X86_VENDOR_AMD; +} + +static const char *acpi_sleep_dsm_state_to_str(unsigned int state) +{ + if (lps0_dsm_func_mask_microsoft || !acpi_s2idle_vendor_amd()) { + switch (state) { + case ACPI_LPS0_SCREEN_OFF: + return "screen off"; + case ACPI_LPS0_SCREEN_ON: + return "screen on"; + case ACPI_LPS0_ENTRY: + return "lps0 entry"; + case ACPI_LPS0_EXIT: + return "lps0 exit"; + case ACPI_LPS0_MS_ENTRY: + return "lps0 ms entry"; + case ACPI_LPS0_MS_EXIT: + return "lps0 ms exit"; + } + } else { + switch (state) { + case ACPI_LPS0_SCREEN_ON_AMD: + return "screen on"; + case ACPI_LPS0_SCREEN_OFF_AMD: + return "screen off"; + case ACPI_LPS0_ENTRY_AMD: + return "lps0 entry"; + case ACPI_LPS0_EXIT_AMD: + return "lps0 exit"; + } + } + + return "unknown"; +} + static void acpi_sleep_run_lps0_dsm(unsigned int func, unsigned int func_mask, guid_t dsm_guid) { union acpi_object *out_obj; @@ -331,14 +370,15 @@ static void acpi_sleep_run_lps0_dsm(unsigned int func, unsigned int func_mask, g rev_id, func, NULL); ACPI_FREE(out_obj); - acpi_handle_debug(lps0_device_handle, "_DSM function %u evaluation %s\n", - func, out_obj ? "successful" : "failed"); + lps0_dsm_state = func; + if (pm_debug_messages_on) { + acpi_handle_info(lps0_device_handle, + "%s transitioned to state %s\n", + out_obj ? "Successfully" : "Failed to", + acpi_sleep_dsm_state_to_str(lps0_dsm_state)); + } } -static bool acpi_s2idle_vendor_amd(void) -{ - return boot_cpu_data.x86_vendor == X86_VENDOR_AMD; -} static int validate_dsm(acpi_handle handle, const char *uuid, int rev, guid_t *dsm_guid) { From patchwork Mon May 22 20:00:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 685390 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 91955C7EE2E for ; Mon, 22 May 2023 20:01:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235546AbjEVUBW (ORCPT ); Mon, 22 May 2023 16:01:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51008 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235532AbjEVUBQ (ORCPT ); Mon, 22 May 2023 16:01:16 -0400 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2077.outbound.protection.outlook.com [40.107.223.77]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BFFF395; Mon, 22 May 2023 13:01:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Uk6WZv9LIYPGgS+0OwVaFWJMchFmPCfNwZB7XpjwTDcrL4M5CLKQO4VoOEdnNu72GSOomd50KydtgvgIXwIu571xH20BySW164Vs9ewIOCBpomDl+/GzMCtJp2mcyYBctwX26DXR9ZZZnTKT/YVjNMIfZEH02JVZoYfc29uKW00ViHjHoQpIYxSXS7z+O/jRjEj/wt+hAZ89kyryjQROsLTTHjOPdbPpLxnt03UT+3Ry0ay+JWIWaJSSI2DEh7Cq+4gZkWUkGZwRZn7FMeWE4Vsh6kQ0jw/kt/cIdVk7l4eH2U68t1b48CDiGB99qfHmOkIfGNleVEGMV/W+OB2irw== 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=HCtaCSh2xp3TLU3Jn9duTu+a0ilJ5rZJIXMRb1Vd+cU=; b=NmIPPzA7qtQx72aW/P3xWHneVpwbUpAE7G2eesbJ0YRETwCOOSlGnaer8M+WutQTgpjDicJX53c4LnfGjxDfs5jfgvQucclbLfoIw1ga5MMrdK20Q0Zs2ezJFWtq4lt+79tNbnOa74YdUlR6ArgCLHE0qxS/11a/Go+rSHwo5SO/SHXU4s9crtj2az/P6YEKp7gzNYiPvNK10ZC40NaJwp6IvMxpgIPBkLqUtNqAJ+9gsqm8yABXlIoBffsplWZzRgOZH3rfTqEFcTEfunK5bAOet3CPRzw2bLLfNvPh9mKawyqyoLtfE9j84RfsnwB4VKgA9wp8Z7c5okXrseVIBg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HCtaCSh2xp3TLU3Jn9duTu+a0ilJ5rZJIXMRb1Vd+cU=; b=x1Z/0bpd613FKOAKUlDC6vMKpwNeQ4/BsbO86g7TVP6nmx5PFbD83NtAPllV/rsKtUzYMUBoAlD7Wz0dTddlLNE49hE0BDfyAG8LnoOySCkDa1Qg9B6/1/5cqkkQgtxZ37f2OJ3bdOtUN6ZA146cwtUCmced2kdstrg79sEgSAs= Received: from MW4PR03CA0161.namprd03.prod.outlook.com (2603:10b6:303:8d::16) by IA1PR12MB6353.namprd12.prod.outlook.com (2603:10b6:208:3e3::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28; Mon, 22 May 2023 20:01:09 +0000 Received: from CO1NAM11FT060.eop-nam11.prod.protection.outlook.com (2603:10b6:303:8d:cafe::24) by MW4PR03CA0161.outlook.office365.com (2603:10b6:303:8d::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.29 via Frontend Transport; Mon, 22 May 2023 20:01:09 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT060.mail.protection.outlook.com (10.13.175.132) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:09 +0000 Received: from SITE-L-T34-2.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Mon, 22 May 2023 15:01:07 -0500 From: Mario Limonciello To: , , CC: , , , , , , , Mario Limonciello Subject: [PATCH v2 3/4] pinctrl: amd: Use pm_pr_dbg to show debugging messages Date: Mon, 22 May 2023 15:00:32 -0500 Message-ID: <20230522200033.2605-3-mario.limonciello@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230522200033.2605-1-mario.limonciello@amd.com> References: <20230522200033.2605-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1NAM11FT060:EE_|IA1PR12MB6353:EE_ X-MS-Office365-Filtering-Correlation-Id: ad48489a-6384-48c9-4743-08db5aff492b X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: t/xyU/nz6B7ExV/3YpVEPhY9nbkSRlzndF6/4+SmPe35DfZWlaLU1xzMo2Wl811KuZJAc7Ju5kMlTZXEk7zERuADtQxq4bIir9f1dBKRbb+t1IjYnOfZd5fHL+3pu5EtNG7FU1mgpdhUmsi+VMGoBUcueJeD7TkCmtsh/sX/gRhVLHp6K9u6fjI6BiOnaeuLbH8HVAsZuBxQuyie2vdaImqyZox3jKWDcCjGJ9f4AZFIxcislqK9AM5Q4mhLOhcz3sKphJN+3a8npBYmfnTmfm9kwSQ1ld+ehgO0DUqJc1a6AUSV8gOmx5TSdNmxVwT+RXa1ZJNQ8EmD/5pTEF5/Mm3wuctzg5I8TwjZo7AoICkVtMf8xrCRhkYM96eqB78ju9pudnepzXpMplkojTpXBWPoEpNE4VNE66WIQkzhCsj81HUfSU9I0R6A5FcquO8xRqL3doH0Q6u1YVQZH039ekSWErFC3gv8oYyzT4c2pLoJuUyB2hsN51OWyPbZrAC6I07rU0KT9YpsN1zlkkgFx950G4TfrC4N/sAhMlqUs0NRX8PhzaQI9C3lw1YHFUO75QSCD1Wy2h4xLntHvnFKGR7cJfTGBCNUvQWsczEsoR8iBKARxBx2C6v/Y+QRPrP5xworoA5RM/kMWUnlsOyg6UIzc1PDEtZMNIvNwr6Y47WOEQwHAT6PTZtXX2jlOTdigCpeI47+DxyKS0thQf0qT9yI30Sfmkl7S2fVKXrCo+EyT+ZhPsSWn+OZEAd67y9rBIfUcx1j4ZbifEj8heuYXQ== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(346002)(136003)(396003)(376002)(39860400002)(451199021)(40470700004)(36840700001)(46966006)(186003)(82740400003)(26005)(1076003)(44832011)(81166007)(16526019)(8676002)(8936002)(47076005)(2616005)(2906002)(356005)(426003)(336012)(15650500001)(40480700001)(40460700003)(6666004)(7696005)(83380400001)(4326008)(316002)(70586007)(70206006)(86362001)(478600001)(82310400005)(36756003)(110136005)(54906003)(41300700001)(5660300002)(36860700001)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 May 2023 20:01:09.2228 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: ad48489a-6384-48c9-4743-08db5aff492b X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT060.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA1PR12MB6353 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org To make the GPIO tracking around suspend easier for end users to use, link it with pm_debug_messages. This will make discovering sources of spurious GPIOs around suspend easier. Signed-off-by: Mario Limonciello --- drivers/pinctrl/pinctrl-amd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-amd.c b/drivers/pinctrl/pinctrl-amd.c index f279b360c20d..43d3530bab48 100644 --- a/drivers/pinctrl/pinctrl-amd.c +++ b/drivers/pinctrl/pinctrl-amd.c @@ -30,6 +30,7 @@ #include #include #include +#include #include "core.h" #include "pinctrl-utils.h" @@ -636,9 +637,8 @@ static bool do_amd_gpio_irq_handler(int irq, void *dev_id) regval = readl(regs + i); if (regval & PIN_IRQ_PENDING) - dev_dbg(&gpio_dev->pdev->dev, - "GPIO %d is active: 0x%x", - irqnr + i, regval); + pm_pr_dbg("GPIO %d is active: 0x%x", + irqnr + i, regval); /* caused wake on resume context for shared IRQ */ if (irq < 0 && (regval & BIT(WAKE_STS_OFF))) From patchwork Mon May 22 20:00:33 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Limonciello X-Patchwork-Id: 684739 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 71B65C77B73 for ; Mon, 22 May 2023 20:01:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234247AbjEVUB2 (ORCPT ); Mon, 22 May 2023 16:01:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51110 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235553AbjEVUBY (ORCPT ); Mon, 22 May 2023 16:01:24 -0400 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (mail-bn8nam12on20618.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe5b::618]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 185DFA9; Mon, 22 May 2023 13:01:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hmFa2cMKYcoiv6s7Lds6ROZwMYyLYHlRGHJEN1i5ERiPvHSv1Wq6GNsJIVcmKy26UDvtem9ZBTKCKKmBCekK/ugeljKDa+V9amnKH0VIIdBKZOfy8izWfW37Ct4G83fQ+h0kaS6hA8mHfASu3y/c12xyQbvVhTdXvL/wz82oAhWjDemxVQ4C7hH7rQGrLDws6yzjRlAEyFPm4myQC6gkyS0ijazn2H1zL/mzcFcTJs5Fuuz3KYqdUTs0vHPaVjwnWj0q15DQsvSoALAt/jbzsn0id+DA/yvTHMAxC5S5qv1kV95MKtL03C8z41JM09wbn0QbowopOvMLpZ/mvJq3NQ== 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=CrHATCoFhmN6yg/azbKKFkcA0h9V7q/tjG0BF8LbZ5Q=; b=lfMoniGPnsV3su/XFF0tFiejbQBBh9HLkO8bs3yy/5Zhm41vOyHsOLlmmQImQwOAaC+WOxyZtzvkITo8ygjHcRPvruONLy7FgJMINOo2q042J7lbzIeAhlWp17yaVltnpe/mfIvgydKoO7pVRA70TK9b4L4UmaWFAI6Hn1TCSdkDgSRofE1r7eFownJ/5tSPbKmheQxydN/Bxeci6Q3r+UnQTTb60IP6xgFgskxQBihUV8IqkPs2YYdAWXGNT6CQvj2RmRZ1Uj3nXHBgvC/QITbLLgSdSxEJUPPBFJrEMWY0VijMx47TCHrM1DdFJOT58lDBULZHtQwUraiFIB4Wuw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=CrHATCoFhmN6yg/azbKKFkcA0h9V7q/tjG0BF8LbZ5Q=; b=DsoCIqWe+4b8td+PzIFDOFUHPawlY32G8stxypAUPJUYIHao4LY8AHVBaUQGF5YVspoenABpcbyb2doEg7EEPW1KHLfqEFOdbVay0AzeQoEKI32BNHcoalXu2Tw7ooZjzpAWz4bZtov6YvPKwmEVjH9qufCJe4mrQqhowCW6FyM= Received: from MW4PR03CA0167.namprd03.prod.outlook.com (2603:10b6:303:8d::22) by DM6PR12MB4169.namprd12.prod.outlook.com (2603:10b6:5:215::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28; Mon, 22 May 2023 20:01:11 +0000 Received: from CO1NAM11FT060.eop-nam11.prod.protection.outlook.com (2603:10b6:303:8d::4) by MW4PR03CA0167.outlook.office365.com (2603:10b6:303:8d::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:11 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT060.mail.protection.outlook.com (10.13.175.132) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6411.28 via Frontend Transport; Mon, 22 May 2023 20:01:10 +0000 Received: from SITE-L-T34-2.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Mon, 22 May 2023 15:01:08 -0500 From: Mario Limonciello To: , , CC: , , , , , , , Mario Limonciello Subject: [PATCH v2 4/4] platform/x86/amd: pmc: Use pm_pr_dbg() for suspend related messages Date: Mon, 22 May 2023 15:00:33 -0500 Message-ID: <20230522200033.2605-4-mario.limonciello@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230522200033.2605-1-mario.limonciello@amd.com> References: <20230522200033.2605-1-mario.limonciello@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1NAM11FT060:EE_|DM6PR12MB4169:EE_ X-MS-Office365-Filtering-Correlation-Id: c07bf1c8-8200-40dd-c244-08db5aff4a2c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Cy1k35ph/Zwscf+cqriUXNrF+kJ2BIDnlsXNOymzGlkNKHn/WtT95ltNI7HHHPKLevEfU8G2/eQc0a+SmSsG9dlao4L4mZW0ChCFEwsRh0zEPYqc5v7il5hFC0Dd6v7oCJr/FlQyHLpU12k0aDpBDZVmvc2oTixE04xmjAYx7tPnvkufo0loXuUM+5hyyxZbU12NH0U2HJpKYV6smMEX9OZVVaUMS40Aq+foYPIEZTGC45flQQl5RqGPcGRlgpgjqg8kXdJF04NCDRtfZ2g4vbxQ8QBZE0+QmZlAmJUDHkqQbYIP8sKfAsSWsBmgRcTrNkmitLKmz8Ok2Vc2fX16pTrgDUFe95ah5tAC85g0ixffThDxkGT/JsUsOwVh13l2BjbJkAKFdpHh/BMLM3d/5KXYGtDx0BExiyWLqtFIA38TSSJBt1F6gHXMkKTy0IM/F/jjA+/NvS9wklXS1tptGCWvILyDlF+c+fcckUvKnMIkx0YDLbtVae309RVs6o/7hxjwIdXRLxBhScDUrubjMSF4S39L/fdMnWNM8FS2IFA2rYujwCw/ApwE3Fi45hxKWXHelkpYnMxu5wqwyUrgyd9UL2sua1hNuwYkHNvbqaV11jQMwjBEIJE5tt2ackbOC5pn2yvDu3KLIWvdYZvKzKuoWg/a7x5L20nJdKkzuDHgQy6TDENkjsvPjY28vswj4hF6TlL9rKmWL74v/0rJHs52PFncp+GIyrgMYPEJdD2BwAJtkj/5gFjNNUErJU3K15OCsmLOxTF3FkIYB4f0SA== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(346002)(376002)(136003)(39860400002)(396003)(451199021)(36840700001)(46966006)(40470700004)(8936002)(8676002)(47076005)(5660300002)(44832011)(36860700001)(82310400005)(83380400001)(186003)(16526019)(1076003)(86362001)(2616005)(26005)(81166007)(356005)(82740400003)(426003)(336012)(40460700003)(41300700001)(6666004)(7696005)(40480700001)(70206006)(70586007)(316002)(4326008)(36756003)(478600001)(110136005)(54906003)(2906002)(15650500001)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 May 2023 20:01:10.9102 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c07bf1c8-8200-40dd-c244-08db5aff4a2c X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT060.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB4169 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org Using pm_pr_dbg() allows users to toggle `/sys/power/pm_debug_messages` as a single knob to turn on messages that amd-pmc can emit to aid in any s2idle debugging. Signed-off-by: Mario Limonciello --- drivers/platform/x86/amd/pmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86/amd/pmc.c b/drivers/platform/x86/amd/pmc.c index 427905714f79..1304cd6f13f6 100644 --- a/drivers/platform/x86/amd/pmc.c +++ b/drivers/platform/x86/amd/pmc.c @@ -543,7 +543,7 @@ static int amd_pmc_idlemask_read(struct amd_pmc_dev *pdev, struct device *dev, } if (dev) - dev_dbg(pdev->dev, "SMU idlemask s0i3: 0x%x\n", val); + pm_pr_dbg("SMU idlemask s0i3: 0x%x\n", val); if (s) seq_printf(s, "SMU idlemask : 0x%x\n", val); @@ -769,7 +769,7 @@ static int amd_pmc_verify_czn_rtc(struct amd_pmc_dev *pdev, u32 *arg) *arg |= (duration << 16); rc = rtc_alarm_irq_enable(rtc_device, 0); - dev_dbg(pdev->dev, "wakeup timer programmed for %lld seconds\n", duration); + pm_pr_dbg("wakeup timer programmed for %lld seconds\n", duration); return rc; }