]> git.proxmox.com Git - mirror_edk2.git/blobdiff - SecurityPkg/Library/Tpm2DeviceLibRouter/Tpm2DeviceLibRouterPei.c
SecurityPkg: Apply uncrustify changes
[mirror_edk2.git] / SecurityPkg / Library / Tpm2DeviceLibRouter / Tpm2DeviceLibRouterPei.c
index e24ef08515f8d9f0a0dab079fc1eba987c7865ca..1c9f54907ff4b5acb17091d779103ebe555cf40f 100644 (file)
@@ -15,7 +15,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
 #include <Library/PcdLib.h>\r
 #include <Library/Tpm2DeviceLib.h>\r
 \r
-EFI_GUID mInternalTpm2DeviceInterfaceGuid = {\r
+EFI_GUID  mInternalTpm2DeviceInterfaceGuid = {\r
   0x349cf818, 0xc0ba, 0x4c43, { 0x92, 0x9a, 0xc8, 0xa1, 0xb1, 0xb3, 0xd2, 0x55 }\r
 };\r
 \r
@@ -29,12 +29,13 @@ InternalGetTpm2DeviceInterface (
   VOID\r
   )\r
 {\r
-  EFI_HOB_GUID_TYPE *Hob;\r
+  EFI_HOB_GUID_TYPE  *Hob;\r
 \r
   Hob = GetFirstGuidHob (&mInternalTpm2DeviceInterfaceGuid);\r
   if (Hob == NULL) {\r
     return NULL;\r
   }\r
+\r
   return (TPM2_DEVICE_INTERFACE *)(Hob + 1);\r
 }\r
 \r
@@ -53,13 +54,13 @@ InternalGetTpm2DeviceInterface (
 EFI_STATUS\r
 EFIAPI\r
 Tpm2SubmitCommand (\r
-  IN UINT32            InputParameterBlockSize,\r
-  IN UINT8             *InputParameterBlock,\r
-  IN OUT UINT32        *OutputParameterBlockSize,\r
-  IN UINT8             *OutputParameterBlock\r
+  IN UINT32      InputParameterBlockSize,\r
+  IN UINT8       *InputParameterBlock,\r
+  IN OUT UINT32  *OutputParameterBlockSize,\r
+  IN UINT8       *OutputParameterBlock\r
   )\r
 {\r
-  TPM2_DEVICE_INTERFACE *Tpm2DeviceInterface;\r
+  TPM2_DEVICE_INTERFACE  *Tpm2DeviceInterface;\r
 \r
   Tpm2DeviceInterface = InternalGetTpm2DeviceInterface ();\r
   if (Tpm2DeviceInterface == NULL) {\r
@@ -87,12 +88,13 @@ Tpm2RequestUseTpm (
   VOID\r
   )\r
 {\r
-  TPM2_DEVICE_INTERFACE *Tpm2DeviceInterface;\r
+  TPM2_DEVICE_INTERFACE  *Tpm2DeviceInterface;\r
 \r
   Tpm2DeviceInterface = InternalGetTpm2DeviceInterface ();\r
   if (Tpm2DeviceInterface == NULL) {\r
     return EFI_UNSUPPORTED;\r
   }\r
+\r
   return Tpm2DeviceInterface->Tpm2RequestUseTpm ();\r
 }\r
 \r
@@ -108,12 +110,12 @@ Tpm2RequestUseTpm (
 EFI_STATUS\r
 EFIAPI\r
 Tpm2RegisterTpm2DeviceLib (\r
-  IN TPM2_DEVICE_INTERFACE   *Tpm2Device\r
+  IN TPM2_DEVICE_INTERFACE  *Tpm2Device\r
   )\r
 {\r
-  TPM2_DEVICE_INTERFACE *Tpm2DeviceInterface;\r
+  TPM2_DEVICE_INTERFACE  *Tpm2DeviceInterface;\r
 \r
-  if (!CompareGuid (PcdGetPtr(PcdTpmInstanceGuid), &Tpm2Device->ProviderGuid)){\r
+  if (!CompareGuid (PcdGetPtr (PcdTpmInstanceGuid), &Tpm2Device->ProviderGuid)) {\r
     DEBUG ((DEBUG_WARN, "WARNING: Tpm2RegisterTpm2DeviceLib - does not support %g registration\n", &Tpm2Device->ProviderGuid));\r
     return EFI_UNSUPPORTED;\r
   }\r
@@ -124,10 +126,10 @@ Tpm2RegisterTpm2DeviceLib (
     // In PEI phase, there will be shadow driver dispatched again.\r
     //\r
     DEBUG ((DEBUG_INFO, "Tpm2RegisterTpm2DeviceLib - Override\n"));\r
-    CopyMem (Tpm2DeviceInterface, Tpm2Device, sizeof(*Tpm2Device));\r
+    CopyMem (Tpm2DeviceInterface, Tpm2Device, sizeof (*Tpm2Device));\r
     return EFI_SUCCESS;\r
   } else {\r
-    Tpm2Device = BuildGuidDataHob (&mInternalTpm2DeviceInterfaceGuid, Tpm2Device, sizeof(*Tpm2Device));\r
+    Tpm2Device = BuildGuidDataHob (&mInternalTpm2DeviceInterfaceGuid, Tpm2Device, sizeof (*Tpm2Device));\r
     if (Tpm2Device != NULL) {\r
       return EFI_SUCCESS;\r
     } else {\r