From patchwork Thu Aug 31 06:20:27 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Evan Quan X-Patchwork-Id: 719539 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 AF05EC83F2F for ; Thu, 31 Aug 2023 06:22:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346081AbjHaGWF (ORCPT ); Thu, 31 Aug 2023 02:22:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55212 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343929AbjHaGWA (ORCPT ); Thu, 31 Aug 2023 02:22:00 -0400 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2046.outbound.protection.outlook.com [40.107.244.46]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4BCEAE59; Wed, 30 Aug 2023 23:21:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=eTEomrNVrFEqWksJVby1ROmX4Pv1oaUx3GcS24WCccj46XhmJ4+jtlwriqLh0F+UXoxshNE9qTzmxsSIKNLIoa7Zc9hEoD1VEB39ctgI6INB9w4ihf/762disSZLh3SqwtAskpIM+HzLZo/qorRjc9rqL2yZG28xMC7bZJem+YuWvWSb5wE5AJhNWpJUrH0f00+iKmvJ3tW5k+nt1zpiHf4xFzu8wCv4FQ+eSwWlUARHjEMIZ22/hjzv2Nb6h/JxmOLCyIchm8pEoUIKHNtrJeMrsqYbh/852onJTW/Chbk95U2DpcVaIERVOOZUOUIo/nDnqZ1PtFVxXckdF6pkdA== 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=8KVZcsU5wLNmNsZV2fXC998Zi1YeRhJaLYvlo00xQX4=; b=XatdWpQPtlSMnhSmshlzx5/2BvTp4WOFta4PJsRDI6cV9kHUK/LIlpdCnX9j8t0TCoxASdfo//lbucNmj+yEv9CdHKn8EWVZrotsC+wnmTtVnf76GSEL/NZHCmQy3JxYaQ5fQ8OsC+wf/v7qa4HLkhqUDHq4UbErQp+ccww1HmJL2OfZSNYWXohB2Gq207bYdGX1a1VknewzdpiyBLGxwYOnBfAYtw5g/5J6rw3XS40iBJGb7b1ENjUFbrTrnopAJZtz6Sb5Jpia3581Ja0YfejnPV3UTFjOAACwUqNmQt4OymF+9G/dLUNqCbydvAHA4d00Zj/wKQ3H3mYyEdJMJQ== 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=8KVZcsU5wLNmNsZV2fXC998Zi1YeRhJaLYvlo00xQX4=; b=gZqNtRCdlV/eFlnvVRssTL6Gp2jJ8OCjxa2mGvZLOVeTLwNI5PyQXomaClGIhsScNPdFKMZJmz37WdyfYiwPoMXvYjA+EPavYNfwAiP/jCpDhIcllVtbmy6yRYUQHaQZV4UwzOrkTbNENB1z4zlRQ6cCXxudW1At4qrmpkts/A4= Received: from MW4P223CA0006.NAMP223.PROD.OUTLOOK.COM (2603:10b6:303:80::11) by DM4PR12MB7551.namprd12.prod.outlook.com (2603:10b6:8:10d::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6745.20; Thu, 31 Aug 2023 06:21:22 +0000 Received: from CO1PEPF000044F8.namprd21.prod.outlook.com (2603:10b6:303:80:cafe::9c) by MW4P223CA0006.outlook.office365.com (2603:10b6:303:80::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6745.21 via Frontend Transport; Thu, 31 Aug 2023 06:21:22 +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 CO1PEPF000044F8.mail.protection.outlook.com (10.167.241.198) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6768.2 via Frontend Transport; Thu, 31 Aug 2023 06:21:22 +0000 Received: from equan-buildpc.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.2507.27; Thu, 31 Aug 2023 01:21:17 -0500 From: Evan Quan To: , , , , , , , , , CC: , , , , , , Evan Quan Subject: [V11 4/8] drm/amd/pm: update driver_if and ppsmc headers for coming wbrf feature Date: Thu, 31 Aug 2023 14:20:27 +0800 Message-ID: <20230831062031.1014799-5-evan.quan@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230831062031.1014799-1-evan.quan@amd.com> References: <20230831062031.1014799-1-evan.quan@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: CO1PEPF000044F8:EE_|DM4PR12MB7551:EE_ X-MS-Office365-Filtering-Correlation-Id: df2bc0fb-e1ff-4c5e-e190-08dba9ea7f1f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: AkqLwUlVIFsIgwE1cCrRysNfIJkukIF3x9GLV/8/ASS8GWVPBPqlqOoO6cOPAPLp9HFTJZUmAyXrNn9+VmK80GElK43MQOV7PEz3y/6jv2+bnQsa+nAsPrulMb4akac3dP/dW0WkUWIiqEQwAcg35ZGIjVSsi0zm7puiyWbh3f476OW3G0h4QmZToygWWRiNtnt0yyz7tgfi3VH5+QdKsSw2RntlucozvNf7a9wz1Xqg4SQWlKGElz8u8nu0d+JJFB1BadfEAsZbtGxA7N8JSITdnYKZPFc0JvOvaqQz/bppbVoZhXOMOPWyFPeZnyuGodZlPNqC0HxhV+jSCiNN0W54WkIX+78x4I2RRO2SQjJs5FptNO/JdehagDaLwB8rWHJqDrdtHJBpOjXT2EGRcPZm3jbaMw7+4L25rpU8YMmVcEjIk2HXCka/eUUCsZHhVHGePRKqBsHfu5zD+vp/ihJorwWyPJBbISIOBhRC5+8SjPsdMg/4/VeDrgbWQrAvpyhVVaFdKjYxzl/TTMOhUNMFCR1o3ECQkYksJRiqIVd4QjGN6xytmdg7G5xgWtMDAVnDrqkeeMaPTfKLRdNKQYZe2R5AXSp82oHsUdHmf6kCivCwpm/VoIb90WDIWtDYnrp8YYZORhj0QWLJvPBv5eoYMxm1KGQDrALjK5PNLX6CpBUL5nMShxzP3D+IVztFToepGHQZ0zQbQr8v/aKktrZNLje3J+ghuFUhovQ/mfE8dG0jOFkVMUjtJizPQimypLQv0QwqBkreASqkmC/BcE0CfmKtGbGPMg5bmPVPI24= 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:(13230031)(4636009)(39860400002)(396003)(376002)(136003)(346002)(186009)(1800799009)(451199024)(82310400011)(46966006)(40470700004)(36840700001)(40480700001)(40460700003)(83380400001)(54906003)(70206006)(316002)(6636002)(70586007)(110136005)(15650500001)(921005)(356005)(478600001)(2906002)(81166007)(82740400003)(41300700001)(86362001)(8936002)(8676002)(4326008)(5660300002)(44832011)(26005)(7696005)(47076005)(336012)(1076003)(6666004)(426003)(36860700001)(7416002)(16526019)(2616005)(36756003)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Aug 2023 06:21:22.1888 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: df2bc0fb-e1ff-4c5e-e190-08dba9ea7f1f 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: CO1PEPF000044F8.namprd21.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB7551 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org Add those data structures to support Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello --- .../pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h | 14 +++++++++++++- .../pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h | 14 +++++++++++++- .../amd/pm/swsmu/inc/pmfw_if/smu_v13_0_0_ppsmc.h | 3 ++- .../amd/pm/swsmu/inc/pmfw_if/smu_v13_0_7_ppsmc.h | 3 ++- 4 files changed, 30 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h index 9dd1ed5b8940..e481407b6584 100644 --- a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h +++ b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h @@ -391,6 +391,17 @@ typedef struct { EccInfo_t EccInfo[24]; } EccInfoTable_t; +typedef struct { + uint16_t LowFreq; + uint16_t HighFreq; +} WifiOneBand_t; + +typedef struct { + uint32_t WifiBandEntryNum; + WifiOneBand_t WifiBandEntry[11]; + uint32_t MmHubPadding[8]; +} WifiBandEntryTable_t; + //D3HOT sequences typedef enum { BACO_SEQUENCE, @@ -1615,7 +1626,8 @@ typedef struct { #define TABLE_I2C_COMMANDS 9 #define TABLE_DRIVER_INFO 10 #define TABLE_ECCINFO 11 -#define TABLE_COUNT 12 +#define TABLE_WIFIBAND 12 +#define TABLE_COUNT 13 //IH Interupt ID #define IH_INTERRUPT_ID_TO_DRIVER 0xFE diff --git a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h index 62b7c0daff68..1530ca002c6c 100644 --- a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h +++ b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h @@ -392,6 +392,17 @@ typedef struct { EccInfo_t EccInfo[24]; } EccInfoTable_t; +typedef struct { + uint16_t LowFreq; + uint16_t HighFreq; +} WifiOneBand_t; + +typedef struct { + uint32_t WifiBandEntryNum; + WifiOneBand_t WifiBandEntry[11]; + uint32_t MmHubPadding[8]; +} WifiBandEntryTable_t; + //D3HOT sequences typedef enum { BACO_SEQUENCE, @@ -1605,7 +1616,8 @@ typedef struct { #define TABLE_I2C_COMMANDS 9 #define TABLE_DRIVER_INFO 10 #define TABLE_ECCINFO 11 -#define TABLE_COUNT 12 +#define TABLE_WIFIBAND 12 +#define TABLE_COUNT 13 //IH Interupt ID #define IH_INTERRUPT_ID_TO_DRIVER 0xFE diff --git a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_0_ppsmc.h b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_0_ppsmc.h index 10cff75b44d5..c98cc32d11bd 100644 --- a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_0_ppsmc.h +++ b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_0_ppsmc.h @@ -138,7 +138,8 @@ #define PPSMC_MSG_SetBadMemoryPagesRetiredFlagsPerChannel 0x4A #define PPSMC_MSG_SetPriorityDeltaGain 0x4B #define PPSMC_MSG_AllowIHHostInterrupt 0x4C -#define PPSMC_Message_Count 0x4D +#define PPSMC_MSG_EnableUCLKShadow 0x51 +#define PPSMC_Message_Count 0x52 //Debug Dump Message #define DEBUGSMC_MSG_TestMessage 0x1 diff --git a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_7_ppsmc.h b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_7_ppsmc.h index 6aaefca9b595..a6bf9cdd130e 100644 --- a/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_7_ppsmc.h +++ b/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_7_ppsmc.h @@ -134,6 +134,7 @@ #define PPSMC_MSG_SetBadMemoryPagesRetiredFlagsPerChannel 0x4A #define PPSMC_MSG_SetPriorityDeltaGain 0x4B #define PPSMC_MSG_AllowIHHostInterrupt 0x4C -#define PPSMC_Message_Count 0x4D +#define PPSMC_MSG_EnableUCLKShadow 0x51 +#define PPSMC_Message_Count 0x52 #endif