SecurityPkg/Tpm2DeviceLibTcg2: Make mTcg2Protocol static

The global variable has a common name that can conflict with other
TCG modules. For example, Tcg2Dxe has a similarly named global that
is of type EFI_TCG2_PROTOCOL instead of EFI_TCG2_PROTOCOL*.

Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Jian J Wang <jian.j.wang@intel.com>
Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
This commit is contained in:
Michael Kubacki 2023-08-15 23:50:33 +08:00 committed by mergify[bot]
parent 14bf2cb411
commit 9896a9c618

View File

@ -14,7 +14,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
#include <Protocol/Tcg2Protocol.h>
#include <IndustryStandard/Tpm20.h>
EFI_TCG2_PROTOCOL *mTcg2Protocol = NULL;
STATIC EFI_TCG2_PROTOCOL *mTcg2Protocol = NULL;
/**
This service enables the sending of commands to the TPM2.