From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (NAM12-BN8-obe.outbound.protection.outlook.com [40.107.237.66]) by mx.groups.io with SMTP id smtpd.web10.47557.1670333023835061785 for ; Tue, 06 Dec 2022 05:23:44 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amd.com header.s=selector1 header.b=3uikdvyy; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.237.66, mailfrom: abdullateef.attar@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=d02a3y7pECljf78Kojp58k/WVXs9sTeOz21mc6Kr05movzT6PTLwDHMAYWW0EM5TrquNbA8h822RmkmV7USwVW4NHZKPvifjlQiY4edcaLkIFWXnn9pUuUtVousiQzBhfXVX7v9Z/nzNrgtyy5xBhdHpwRdSVbwo5xzOT8gixlOdcewaSQ6o733C+9vwJk3Emrbx4foBBn6s1UGrj940oQKGNXccZp6efDysaKodCqb4xCE8HfIwfCNduhD49xy+iYiFCamhGDxdxU3+Xi3Ah+LGX3TS8W6g3xMQDW3bMs8W0G4TYgbwzwCrRuZYF2RRebC9xytNU7OnqEDxGKoefA== 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=7LwBaIepAjodymNKw7vxEjn6TPBuoBZY2e2Zn8qn9H0=; b=XfH4t6HcWHDO5kr0CzCSqjuSTpG0R8xEsAfShJLAhXc6lKRehKTX/Q8BoAy7KaRHEvAEMVppYIoH0ZeW8ZeJr4jA+DP514J/lUEc03p3SGVx2/EPu49BXA8HVoBqQXX3naSyHV7ujBTlD4QdHG+H17PUMlRAisXBf3tFP6kyo21NmJG2pIZgUjWzxqWUJtPS3O0b3tCVrk3UmO/QEvnVLInwicFm99XiBiENyCfNR5HkxnFUnG844kAcPCqqG4sMwfwGL3Lr7+aLeL+wCq7dI50fHtHwFlnfYCEYQf8Yp1rFsH1HWlRMj2F+DegIYqfcE7borhJsPc7VK/Kp0jowrg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=edk2.groups.io 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=7LwBaIepAjodymNKw7vxEjn6TPBuoBZY2e2Zn8qn9H0=; b=3uikdvyyBoHKk2jY6B76qFUZBrTCscgts7a0mNS4FPIzdKBfAPPnJ1wrLmB1qseuOjGLaQum2gJjfDlky/+rJm4rmI/gB6vHE6MflHK95PbaKqoZca/J/6w1j1aE1W8gQPa3uCQVF9d8bD2MOJO+j9dzjqdVG0k6QuVmFfF0efw= Received: from BN9PR03CA0917.namprd03.prod.outlook.com (2603:10b6:408:107::22) by SJ0PR12MB8168.namprd12.prod.outlook.com (2603:10b6:a03:4e7::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5880.14; Tue, 6 Dec 2022 13:23:41 +0000 Received: from BN8NAM11FT019.eop-nam11.prod.protection.outlook.com (2603:10b6:408:107:cafe::12) by BN9PR03CA0917.outlook.office365.com (2603:10b6:408:107::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5880.14 via Frontend Transport; Tue, 6 Dec 2022 13:23:41 +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 BN8NAM11FT019.mail.protection.outlook.com (10.13.176.158) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5880.14 via Frontend Transport; Tue, 6 Dec 2022 13:23:40 +0000 Received: from SATLEXMB08.amd.com (10.181.40.132) 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; Tue, 6 Dec 2022 07:23:34 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB08.amd.com (10.181.40.132) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Tue, 6 Dec 2022 05:23:34 -0800 Received: from BLR-LAB-SFW01.amd.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2375.34 via Frontend Transport; Tue, 6 Dec 2022 07:23:31 -0600 From: "Abdul Lateef Attar" To: CC: Abdul Lateef Attar , Paul Grimes , Garrett Kirkendall , Abner Chang , Eric Dong , Ray Ni , Rahul Kumar , Michael D Kinney , Liming Gao , Zhiguang Liu Subject: [PATCH v1 0/5] Adds AmdSmmCpuFeaturesLib Date: Tue, 6 Dec 2022 18:53:13 +0530 Message-ID: X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Return-Path: AbdulLateef.Attar@amd.com X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN8NAM11FT019:EE_|SJ0PR12MB8168:EE_ X-MS-Office365-Filtering-Correlation-Id: 6ca1fbd9-d47e-4146-72bc-08dad78d1731 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: vNV4NiZkOahn5KHQcopvX5Wl6hc4+S35vlf8TnctOyAPROrT7jOho3eL3OCv8lolt3SiXWMbrFVifkbgRQP1/fr1xgB0twx3OAaMYe8dBMvp49xEYzzjLLLhsTs7qd69/QE5KXvBiI9JmcwISjpuAoj7AqG9l6t0dHf00eIwWrHfBSMZjppM7xw5j6ceZHUUC/67e5bRAXDrVlJsTgi/T1/FXSlrXGrwgT79XKQANL3w+8BQa6rg/O7ndUVoP2gBs6ZsLYmWvkfKZz9KoqWzSS1WPuckfx3K1WZJYOwDDI8wd6rcwk3LDqGKGeJqh8Ys8C/Cwo8TSHVIRg/3Y5ejDMjUW+yRZxiGBB9GZG6Pco9U4SWtdkpeuNJ88+F5nWxD9CiQsE5YfReiLVPA885wMzx0K/iicnz8HGLjBxmrATQSmP4Qem26jd2OhmZ+Y4HyUHOCPcZiFbB3JoP7dwOXjM3ANsTODOmZanMqgEg4Nxo9pg4RTmy+AsWu1JtDhF2FHE44IOjhmfa/tzRrTFu+yPkdEL73fjJW/4/h++YiSMZXPdqFr5LzmeDI0P2xpsd3NKtOstvXNqUqhCG/MRrNkchYZHpVJbFOSk7dCzu9snxroliQLpcUNlZFXwvYRsW0PqzRoKQWDndkajgA73ilUYBL5f2XWsJ5gagb6pz1EHUQoEZ4JGgasdCB0Cy+QorwOT4C/9eppDCL2EPTsWn+PAa927+FlwMTn+SVcF+va9ZCk0FMnLrEbs1/D5JhNBxNSOPsRUZwC/Q1vH0whnOHyW1em/DcwfAASFoJEtnUeBY= 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:(13230022)(4636009)(39860400002)(346002)(376002)(396003)(136003)(451199015)(46966006)(36840700001)(40470700004)(186003)(81166007)(336012)(356005)(2616005)(2906002)(41300700001)(82740400003)(83380400001)(82310400005)(5660300002)(40460700003)(8936002)(36860700001)(36756003)(426003)(47076005)(966005)(70206006)(478600001)(40480700001)(6666004)(8676002)(7696005)(4326008)(70586007)(26005)(6916009)(54906003)(316002)(213903007)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Dec 2022 13:23:40.5354 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6ca1fbd9-d47e-4146-72bc-08dad78d1731 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: BN8NAM11FT019.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR12MB8168 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Implements SmmCpuFeaturesLib library class for AMD processor family. Adds AMD processor families processor save state registers. Implements required functions. Handles S3 save state from SMM. PR: https://github.com/tianocore/edk2/pull/3726 Cc: Paul Grimes Cc: Garrett Kirkendall Cc: Abner Chang Cc: Eric Dong Cc: Ray Ni Cc: Rahul Kumar Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Abdul Lateef Attar (5): UefiCpuPkg/SmmCpuFeaturesLib: Restructure arch-dependent code MdePkg: Adds AMD SMRAM save state map UefiCpuPkg: Initial implementation of AMD's SmmCpuFeaturesLib UefiCpuPkg: Implements SmmCpuFeaturesLib for AMD Family UefiCpuPkg/AmdSmmCpuFeaturesLib: Handles S3 save state UefiCpuPkg/UefiCpuPkg.dsc | 9 + .../AmdSmmCpuFeaturesLib.inf | 40 ++ .../Include/Register/Amd/SmramSaveStateMap.h | 194 +++++++ .../SmmCpuFeaturesLib/Amd/SmramSaveState.h | 128 +++++ .../SmmCpuFeaturesLib/Amd/SmmCpuFeaturesLib.c | 476 ++++++++++++++++++ .../SmmCpuFeaturesLib/Amd/SmramSaveState.c | 409 +++++++++++++++ .../IntelSmmCpuFeaturesLib.c | 140 ++++++ .../SmmCpuFeaturesLibCommon.c | 140 ------ MdePkg/MdePkg.ci.yaml | 3 +- 9 files changed, 1398 insertions(+), 141 deletions(-) create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/AmdSmmCpuFeaturesL= ib.inf create mode 100644 MdePkg/Include/Register/Amd/SmramSaveStateMap.h create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/Amd/SmramSaveState= .h create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/Amd/SmmCpuFeatures= Lib.c create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/Amd/SmramSaveState= .c --=20 2.25.1