From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pg1-f171.google.com (mail-pg1-f171.google.com [209.85.215.171]) by mx.groups.io with SMTP id smtpd.web12.2157.1657078726858443186 for ; Tue, 05 Jul 2022 20:38:47 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20210112 header.b=VcF8j4eG; spf=pass (domain: gmail.com, ip: 209.85.215.171, mailfrom: kuqin12@gmail.com) Received: by mail-pg1-f171.google.com with SMTP id z14so13065721pgh.0 for ; Tue, 05 Jul 2022 20:38:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=rWg7LKk8oGd7S+lgfGndH0diU81vxonwoeO142RESo0=; b=VcF8j4eGMin2exyHMRxmVx4eFMjOnfLfMzEG4/LB42J05BSvOquUjuWDr1wsCX0hfV qzSErBLvhNMfO95MQinYf02+2NOoD0jiHtjKOeD3CkrdrWp0heMeKHyLt9wRHCVtraID GwOoDj7S6jdjoI6Ha6FUUBe+B7WdCq4dt9TYglBmtyVIyb1OeIfiLW1VEdDiTjLYqfiI PrMrK28EM+p3jCHFw8FWYjTWNbXzOuEobptpryWobveskyChzQJNsC+FxPVxqUwQwCaT 8fd9R5cZJd9iWe66VSKgaoExhrmbp//OY2R8pAIsboag6XC9hJyKLvtqwGbkatci978k Qvdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rWg7LKk8oGd7S+lgfGndH0diU81vxonwoeO142RESo0=; b=qf0bvRZpbhuZu86GwwQx4HbjJCBCjHe00ptFQt3Vu7xUBXM+f0LkjFm5zUKm+jj1eZ 36fMUtAaHt7DFvrGvPl7CMa1BRUE4ZBbb1YsgpfPo3K5YPmFuF6cgz8reL0NWQ2t9peH j6knnvLewc+PrUt896fRA2cHGW2taUED1etgCK7cWioveUw/0bQdBqMfevrs4o305BDI a2yMdQMncGSWlXtjKQ0NNxSwzK0dchY/itz+qB52r65jorcYYO3Jq1fw4/oKJA/Zj7af 0OhoRdHSZSHx09U1vD9NEQIbZHSClaxpTGkeU56q+jJtfzu+trcddmTclU5C59PF4IU6 1C1g== X-Gm-Message-State: AJIora/eWvJEaj4y0GY/btE7LawRXpTxiC+/k+YbRRwclrpIxmfJDzeX sEoWJF9CYKAIVL3Nze8bkcsZkREiKMs= X-Google-Smtp-Source: AGRyM1tmwsPJ1D2WkNuBJ17ML4y5r3x+UkleQeuXmmym2/Kyvp18mS9ycNyqJmH4TPXKsUCnnqy51w== X-Received: by 2002:a63:e05:0:b0:412:91db:a653 with SMTP id d5-20020a630e05000000b0041291dba653mr2178656pgl.446.1657078726241; Tue, 05 Jul 2022 20:38:46 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([192.182.149.255]) by smtp.gmail.com with ESMTPSA id a140-20020a621a92000000b005289fbef7c4sm864251pfa.140.2022.07.05.20.38.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 20:38:45 -0700 (PDT) From: "Kun Qin" To: devel@edk2.groups.io Cc: Andrew Fish , Leif Lindholm , Michael D Kinney , Liming Gao , Zhiguang Liu Subject: [edk2-staging][PATCH v1 1/7] EDK2 Code First: PI Specification: New peripheral subclass for TPM Date: Tue, 5 Jul 2022 20:38:12 -0700 Message-Id: <20220706033818.1493-2-kuqin12@gmail.com> X-Mailer: git-send-email 2.35.1.windows.2 In-Reply-To: <20220706033818.1493-1-kuqin12@gmail.com> References: <20220706033818.1493-1-kuqin12@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3966 This change includes specification update markdown file that describes the proposed PI Specification v1.7 Errata A in detail and potential impact to the existing codebase. Cc: Andrew Fish Cc: Leif Lindholm Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Signed-off-by: Kun Qin --- CodeFirst/BZ3966-SpecChange.md | 60 ++++++++++++++++++++ 1 file changed, 60 insertions(+) diff --git a/CodeFirst/BZ3966-SpecChange.md b/CodeFirst/BZ3966-SpecChange.md new file mode 100644 index 000000000000..8a1541bdd577 --- /dev/null +++ b/CodeFirst/BZ3966-SpecChange.md @@ -0,0 +1,60 @@ +# Title: Introduction of `EFI_PERIPHERAL_TPM` Peripheral Subclass Definition + +## Status: Draft + +## Document: UEFI Platform Initialization Specification Version 1.7 Errata A + +## License + +SPDX-License-Identifier: CC-BY-4.0 + +## Submitter: [TianoCore Community](https://www.tianocore.org) + +## Summary of the change + +Add `EFI_PERIPHERAL_TPM` into Peripheral Subclass definition. + +## Benefits of the change + +Current status code covered various [peripheral subclass definitions](https://github.com/tianocore/edk2/blob/master/MdePkg/Include/Pi/PiStatusCode.h). + +As Trusted Platform Module (TPM) becomes more available on the modern systems, status reports from such peripheral are playing more important roles in anaylzing the secruity state and healthiness of a system. However, peripheral subclass definitions do not cover TPM as of today. + +Standardizing the TPM peripheral subclass definition could facilitate the parsing of peripheral reported errors and avoid potential definition collisions from implementation based subclass usages. + +The request of this change intends to expand definitions of `EFI_PERIPHERAL_**` under Periperhal Subclass definitions to cover the TPM subclass. + +## Impact of the change + +Occupy a new macro definitions of subclass under `Defined Subclasses: User-Accessible Peripheral Class`. + +## Detailed description of the change [normative updates] + +### Specification Changes + +1. In PI Specification v1.7 Errata A: Vol. 3, Table 3-30: Defined Subclasses: User-Accessible Peripheral Class, add one new rows below `EFI_PERIPHERAL_DOCKING` definition and adjust the rest of reserved definitions accordingly: + + | Subclass | Code Name | Description | + | --- | --- | --- | + | Trusted Platform Module | EFI_PERIPHERAL_TPM | The peripheral referred to is a Trusted Platform Module | + | 0x0F–0x7F | Reserved for future use by this specification | | + +1. In PI Specification v1.7 Errata A: Vol. 3, Table 3-84: Defined Subclasses: User-Accessible Peripheral Class, add one new rows below `EFI_PERIPHERAL_DOCKING` definition and adjust the rest of reserved definitions accordingly: + + | Subclass | Code Name | + | --- | --- | + | Trusted Platform Module | EFI_PERIPHERAL_TPM | + | 0x0F–0x7F | Reserved for future use by this specification. | + +1. In PI Specification v1.7 Errata A: Vol. 3, Section 6.7.2.1 Subclass Definitions: Prototype, add one new definitions below `EFI_PERIPHERAL_DOCKING` definition: + + ```c + #define EFI_PERIPHERAL_TPM \ + (EFI_PERIPHERAL | 0x000E0000) + ``` + +### Code Changes + +1. Add macro definitions in `MdePkg/Include/Pi/PiStatusCode.h` to match new specification. +1. Replace existing references of `gEfiSecurityPkgTokenSpaceGuid.PcdStatusCodeSubClassTpmDevice` from SecurityPkg with new definition. +1. Updated the default value of `gEfiSecurityPkgTokenSpaceGuid.PcdStatusCodeSubClassTpmDevice` to `(EFI_PERIPHERAL | 0x000E0000)` for consistency and backwards compatibility outside of SecurityPkg. -- 2.35.1.windows.2