]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg/PiSmmCore: fix GCC build error
authorLaszlo Ersek <lersek@redhat.com>
Tue, 12 Dec 2017 11:14:35 +0000 (12:14 +0100)
committerLaszlo Ersek <lersek@redhat.com>
Tue, 12 Dec 2017 13:08:58 +0000 (14:08 +0100)
> MdeModulePkg/Core/PiSmmCore/PiSmmCore.c: In function
> 'SmmReadyToBootHandler':
> MdeModulePkg/Core/PiSmmCore/PiSmmCore.c:323:14: error: passing argument
> 3 of 'SmmLocateProtocol' from incompatible pointer type [-Werror]
>               );
>               ^
> In file included from MdeModulePkg/Core/PiSmmCore/PiSmmCore.c:15:0:
> MdeModulePkg/Core/PiSmmCore/PiSmmCore.h:586:1: note: expected 'void **'
> but argument is of type 'struct EFI_SMM_SX_DISPATCH2_PROTOCOL **'
>  SmmLocateProtocol (
>  ^
> cc1: all warnings being treated as errors

Cc: Eric Dong <eric.dong@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Fixes: 7b9b55b2ef7be13608605dc58a54b9ca04be4e40
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Yao Jiewen <jiewen.yao@intel.com>
MdeModulePkg/Core/PiSmmCore/PiSmmCore.c

index dbb89932e75bd074e459987914e533369293f0ea..1ccb9c7787ad8b7e57edba1ab9f2bccbf6caa115 100644 (file)
@@ -319,7 +319,7 @@ SmmReadyToBootHandler (
   Status = SmmLocateProtocol (\r
              &gEfiSmmSxDispatch2ProtocolGuid,\r
              NULL,\r
-             &SxDispatch\r
+             (VOID **)&SxDispatch\r
              );\r
   if (!EFI_ERROR (Status)) {\r
     //\r