From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM10-BN7-obe.outbound.protection.outlook.com (NAM10-BN7-obe.outbound.protection.outlook.com [40.107.92.49]) by mx.groups.io with SMTP id smtpd.web11.10414.1676448112872657834 for ; Wed, 15 Feb 2023 00:01:53 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amd.com header.s=selector1 header.b=4RpXjKR3; 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.92.49, mailfrom: abdullateef.attar@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fBs/Zxm7KarzW6M9DxM6P4aYVcgF5rVdAirtypNLdT3I+UZZhtkBfIeaLI8Zr+T3MPXf/f7CePDrXvFdixW4UA5hW+RMgIh5beCeU5c1wFXgUnRFTqWlhGjJjRdt78BEvrnzEmTKTC4lNsmRdYFOdr5Ckg5FJJdhZjiQAKQuUTndCT22Ageok4m57Fj9NdbAyIZeEZ/en6+0Bndid/luSMfHA1lNUBrE8pkJHeNBxBM2xT9YULT5nPm05A3ZXb9g92vS57ywpFBLpwfm1P0WICmb2dbjvKYD5NZzcvH6XlXu8Tmjd9sDNePfXA7aaTNXPq8FkKUlAtF2uh8g0h0zTw== 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=Kt4GlQibhzoyz9UfiwZCqzYTwuvzkuCMV0/D5LN6hIc=; b=Yojaa51Vat4oZY/b6pwViJWfBOGJsoeK5cxYk7kRBLw7wZm4lxSeB3ARY0otU1MBZcit0VmJkNmscxnGUq1ynaormxAMBbBiOdumq7ejz3pYRDJ6Kb3eBTGr+uY4kolZON6gWMK6djMkmuoMjo64/mVBx9Lw+pOdMMMOfiLi77KKua3jEh8x5ecAkF+QQvhcw76IYJgPFZ8u7TCEs+nD1HcSU7r6BZURTFiJIrGgwNDFtJFHrpUmXplw7yT8cNUOpxq2DTDdkN1SiM+ZeGm4Rzn/K0ul9G9EdqOrJtQYCdGnPm5YeTVfxPQLalNZH3dgorwmzN0vwp+YlPjZZ7pgGg== 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=Kt4GlQibhzoyz9UfiwZCqzYTwuvzkuCMV0/D5LN6hIc=; b=4RpXjKR33cLmxOC30u5rGB9Ie+zOW+624itwLhvgFA1EX7mXroqmlrwWpVK+rVbwyQqouoH6TpscvvmgBjX7hr1gWGchTr8n+c6Sc1XqsldbqX4s7I0wWixcJg2CZP21O2GB6AC6tkdDqELDkRPlb2JLQka2byD6at2yOdq5UYg= Received: from DS7PR03CA0238.namprd03.prod.outlook.com (2603:10b6:5:3ba::33) by CY5PR12MB6083.namprd12.prod.outlook.com (2603:10b6:930:29::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6086.26; Wed, 15 Feb 2023 08:01:50 +0000 Received: from DM6NAM11FT042.eop-nam11.prod.protection.outlook.com (2603:10b6:5:3ba:cafe::b6) by DS7PR03CA0238.outlook.office365.com (2603:10b6:5:3ba::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6086.26 via Frontend Transport; Wed, 15 Feb 2023 08:01:50 +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 DM6NAM11FT042.mail.protection.outlook.com (10.13.173.165) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6086.24 via Frontend Transport; Wed, 15 Feb 2023 08:01:50 +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; Wed, 15 Feb 2023 02:01:49 -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; Wed, 15 Feb 2023 00:01:44 -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; Wed, 15 Feb 2023 02:01:43 -0600 From: "Abdul Lateef Attar" To: Subject: [PATCH v5 0/6] Adds AmdSmmCpuFeaturesLib for AMD Family Date: Wed, 15 Feb 2023 13:31:37 +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: DM6NAM11FT042:EE_|CY5PR12MB6083:EE_ X-MS-Office365-Filtering-Correlation-Id: d6a139b1-9dcf-457d-2998-08db0f2ae4b2 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: bT/+yXMI+5QUbhP1dI+VSBlyqANtADzG2kmmlnm0GRE5fOs2XsUBANEhSPVOiG5dticlPRMN7QWBUGxVlflJBAENQZ9h42+QmSaldyNxLc2Vncr8E5mUkbEg3dhGXVsWNy9tkzRFZnDMmVT7/MEE/L3q5UwErQb69ELLE3WnnLOZWg0Dhyn4J/9yLArzwYjeEq9poUJcoecWnkbBs/cDvkR2duyONFNPfzgoVp0gxYkJAXTTE0joGelCTVK2oPYo8CXkF7TG1DqM5ozmPA33TfNB4y4jUkaVPaOtUukuQJbxTqkNghZ4jEC9pucELoKK9sHLJU9tkWfaVdqXvv2EwL877lIGHAAzHDljULi3dJitRdb33d3ppqWwXEsomYbSYm0Cf/jQhYhU9yYrbKuQY/OUUXeGvHjV68p7YpNxYRW56aom1AGI338Y29kDLUwvmIcXNKItMf4C65eimJbPmHglSmVyUJXsnJoJ7y5B+hcl5SXF1lfNqNw9qJzP/ZmFwUdNZoIZCXxVCTLoRTb2VPaGixiemozpnbVB31oVYnTTeEENJyUokQ1naSyb+lF4tLk97762B1PeZp36olvXlTOtAHuxD2jV/IV9gOGkbug4JrdcLRhyAcMGWDCo966tsSNK+SC7C93xZ0Nvp4H5P7Dl4Pr6y39Zr9S/AfKHAZHYeezJzNs/Qk/vJmyStkU6rMRcQe5h9jfKx9noqOfuwM/XBQ6kSiKXemyR0FGshRWDOnPIqIVGg2q2OZi3sMpJ 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:(13230025)(4636009)(346002)(376002)(136003)(396003)(39860400002)(451199018)(46966006)(36840700001)(40470700004)(82310400005)(2906002)(36756003)(40460700003)(47076005)(2616005)(426003)(336012)(83380400001)(40480700001)(7696005)(966005)(478600001)(26005)(6666004)(186003)(316002)(356005)(82740400003)(8936002)(41300700001)(5660300002)(70206006)(36860700001)(70586007)(6916009)(81166007)(8676002)(213903007)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 15 Feb 2023 08:01:50.2200 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: d6a139b1-9dcf-457d-2998-08db0f2ae4b2 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: DM6NAM11FT042.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY5PR12MB6083 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain MIME-Version: 1.0 Content-Type: text/plain; charset=3DUTF-8 Content-Transfer-Encoding: 8bit PR: https://github.com/tianocore/edk2/pull/4044 V5 delta changes: rebase to master branch. updated Reviewed-by V4 delta changes: rebase to master branch. added reviewed-by. V3 delta changes: Addressed review comments from Abner chang. Re-arranged patch order. Abdul Lateef Attar (6): MdePkg: Adds AMD SMRAM save state map UefiCpuPkg: Adds SmmSmramSaveStateLib library class UefiCpuPkg: Implements SmmSmramSaveStateLib library class UefiCpuPkg/SmmCpuFeaturesLib: Restructure arch-dependent code UefiCpuPkg: Initial implementation of AMD's SmmCpuFeaturesLib UefiCpuPkg: Implements SmmCpuFeaturesLib for AMD Family UefiCpuPkg/UefiCpuPkg.dec | 4 + UefiCpuPkg/UefiCpuPkg.dsc | 11 + .../AmdSmmCpuFeaturesLib.inf | 39 ++ .../AmdSmmSmramSaveStateLib.inf | 28 ++ .../Include/Register/Amd/SmramSaveStateMap.h | 194 ++++++++ .../Include/Library/SmmSmramSaveStateLib.h | 70 +++ .../SmmSmramSaveStateLib/SmramSaveState.h | 102 ++++ .../SmmCpuFeaturesLib/AmdSmmCpuFeaturesLib.c | 445 ++++++++++++++++++ .../IntelSmmCpuFeaturesLib.c | 128 +++++ .../SmmCpuFeaturesLibCommon.c | 128 ----- .../SmmSmramSaveStateLib/AmdSmramSaveState.c | 319 +++++++++++++ .../SmramSaveStateCommon.c | 124 +++++ MdePkg/MdePkg.ci.yaml | 4 +- 13 files changed, 1467 insertions(+), 129 deletions(-) create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/AmdSmmCpuFeaturesL= ib.inf create mode 100644 UefiCpuPkg/Library/SmmSmramSaveStateLib/AmdSmmSmramSave= StateLib.inf create mode 100644 MdePkg/Include/Register/Amd/SmramSaveStateMap.h create mode 100644 UefiCpuPkg/Include/Library/SmmSmramSaveStateLib.h create mode 100644 UefiCpuPkg/Library/SmmSmramSaveStateLib/SmramSaveState.= h create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/AmdSmmCpuFeaturesL= ib.c create mode 100644 UefiCpuPkg/Library/SmmSmramSaveStateLib/AmdSmramSaveSta= te.c create mode 100644 UefiCpuPkg/Library/SmmSmramSaveStateLib/SmramSaveStateC= ommon.c --=20 2.25.1