Ard:
  Sorry for the inconvenience, your fix is good. 




Thanks & Best regards
Chao Zhang

-----Original Message-----
From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] 
Sent: Monday, December 07, 2015 4:35 PM
To: Zhang, Chao B
Cc: edk2-devel@lists.01.org; qin.l...@inte.com; Zeng, Star
Subject: Re: [edk2] [PATCH 2/3] SecurityPkg: AuthVariableLib: Customized 
SecureBoot Mode transition. Implement Customized SecureBoot Mode transition 
logic according to Mantis 1263, including AuditMode/DeployedMode/PK update 
management. Also implement image veri...

On 7 December 2015 at 03:04, Zhang, Chao B <chao.b.zh...@intel.com> wrote:
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Zhang, Chao <chao.b.zh...@intel.com>
> Reviewed-by: Zeng Star <star.z...@intel.com>
> Reviewed-by: Long Qin <qin.l...@intel.com>
> ---

This patch breaks the build for GCC, since it mixes UINT8** and VOID**, which 
GCC does not allow.

The following patch fixes the build for me. Please fix asap.

diff --git a/SecurityPkg/Library/AuthVariableLib/AuthService.c
b/SecurityPkg/Library/AuthVariableLib/AuthService.c
index 5546c2e5c906..9a09eaed609a 100644
--- a/SecurityPkg/Library/AuthVariableLib/AuthService.c
+++ b/SecurityPkg/Library/AuthVariableLib/AuthService.c
@@ -555,10 +555,10 @@ TransitionFromAuditMode(
   )
 {
   EFI_STATUS  Status;
-  UINT8       *AuditVarData;
-  UINT8       *DeployedVarData;
-  UINT8       *SetupVarData;
-  UINT8       *SecureBootVarData;
+  VOID        *AuditVarData;
+  VOID        *DeployedVarData;
+  VOID        *SetupVarData;
+  VOID        *SecureBootVarData;
   UINT8       SecureBootEnable;
   UINTN       DataSize;

@@ -693,9 +693,9 @@ TransitionFromDeployedMode(
   )
 {
   EFI_STATUS  Status;
-  UINT8       *DeployedVarData;
-  UINT8       *SetupVarData;
-  UINT8       *SecureBootVarData;
+  VOID        *DeployedVarData;
+  VOID        *SetupVarData;
+  VOID        *SecureBootVarData;
   UINT8       SecureBootEnable;
   UINTN       DataSize;

@@ -835,11 +835,11 @@ TransitionFromUserMode(
   )
 {
   EFI_STATUS   Status;
-  UINT8        *AuditVarData;
-  UINT8        *DeployedVarData;
-  UINT8        *SetupVarData;
-  UINT8        *PkVarData;
-  UINT8        *SecureBootVarData;
+  VOID         *AuditVarData;
+  VOID         *DeployedVarData;
+  VOID         *SetupVarData;
+  VOID         *PkVarData;
+  VOID         *SecureBootVarData;
   UINT8        SecureBootEnable;
   UINTN        DataSize;
   VARIABLE_ENTRY_CONSISTENCY  VariableEntry; @@ -1034,9 +1034,9 @@ 
TransitionFromSetupMode(
   )
 {
   EFI_STATUS   Status;
-  UINT8        *AuditVarData;
-  UINT8        *SetupVarData;
-  UINT8        *SecureBootVarData;
+  VOID         *AuditVarData;
+  VOID         *SetupVarData;
+  VOID         *SecureBootVarData;
   UINT8        SecureBootEnable;
   UINTN        DataSize;

@@ -1746,7 +1746,7 @@ ProcessSecureBootModeVar (
   )
 {
   EFI_STATUS    Status;
-  UINT8         *VarData;
+  VOID          *VarData;
   UINTN         VarDataSize;

   //
@@ -1801,7 +1801,7 @@ ProcessSecureBootModeVar (
   //
   // If AuditMode/DeployedMode is assigned same value. Simply return 
EFI_SUCCESS
   //
-  if (*VarData == *(UINT8 *)Data) {
+  if (*(UINT8 *)VarData == *(UINT8 *)Data) {
     return EFI_SUCCESS;
   }
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to