[edk2-devel] [Patch] IntelSiliconPkg: Declare zero array explicitly to avoid compiler error.

Ni, Ray ray.ni at intel.com
Wed Feb 26 02:33:27 UTC 2020


Reviewed-by: Ray Ni <ray.ni at intel.com>

> -----Original Message-----
> From: Chaganty, Rangasai V <rangasai.v.chaganty at intel.com>
> Sent: Wednesday, February 26, 2020 9:39 AM
> To: Fu, Siyuan <siyuan.fu at intel.com>; devel at edk2.groups.io
> Cc: Ni, Ray <ray.ni at intel.com>
> Subject: RE: [Patch] IntelSiliconPkg: Declare zero array explicitly to avoid compiler error.
> 
> Reviewed-by: Sai Chaganty <rangasai.v.chaganty at intel.com>
> 
> -----Original Message-----
> From: Fu, Siyuan <siyuan.fu at intel.com>
> Sent: Tuesday, February 25, 2020 5:08 PM
> To: devel at edk2.groups.io
> Cc: Ni, Ray <ray.ni at intel.com>; Chaganty, Rangasai V <rangasai.v.chaganty at intel.com>
> Subject: [Patch] IntelSiliconPkg: Declare zero array explicitly to avoid compiler error.
> 
> This patch fixes a potential compiler error introduced by commit b0099a39bd since not all compiler can support empty
> array member.
> 
> BZ: https://tianocore.acgmultimedia.com/show_bug.cgi?id=2449
> Cc: Ray Ni <ray.ni at intel.com>
> Cc: Rangasai V Chaganty <rangasai.v.chaganty at intel.com>
> Signed-off-by: Siyuan Fu <siyuan.fu at intel.com>
> ---
>  .../Intel/IntelSiliconPkg/Include/Guid/MicrocodeShadowInfoHob.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Silicon/Intel/IntelSiliconPkg/Include/Guid/MicrocodeShadowInfoHob.h
> b/Silicon/Intel/IntelSiliconPkg/Include/Guid/MicrocodeShadowInfoHob.h
> index d1a9d79a51..d887b39123 100644
> --- a/Silicon/Intel/IntelSiliconPkg/Include/Guid/MicrocodeShadowInfoHob.h
> +++ b/Silicon/Intel/IntelSiliconPkg/Include/Guid/MicrocodeShadowInfoHob.
> +++ h
> @@ -33,7 +33,7 @@ typedef struct {
>    // An array with MicrocodeCount elements that stores
>    // the shadowed microcode patch address in memory.
>    //
> -  UINT64    MicrocodeAddrInMemory[];
> +  UINT64    MicrocodeAddrInMemory[0];
>    //
>    // A buffer which contains details about the storage information
>    // specific to StorageType.
> --
> 2.19.1.windows.1
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#54836): https://edk2.groups.io/g/devel/message/54836
Mute This Topic: https://groups.io/mt/71546083/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list