UefiCpuPkg/SecMain: Add NORETURN decorator to SecStartup().

The function SecStartup() is not supposed to return. Hence, add the
NORETURN decorator.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Marvin Haeuser <Marvin.Haeuser@outlook.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
This commit is contained in:
Marvin H?user 2018-02-28 00:50:59 +08:00 committed by Eric Dong
parent ee3198e672
commit 7cd8a57599
2 changed files with 9 additions and 2 deletions

View File

@ -1,7 +1,7 @@
/** @file /** @file
C functions in SEC C functions in SEC
Copyright (c) 2008 - 2017, Intel Corporation. All rights reserved.<BR> Copyright (c) 2008 - 2018, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at which accompanies this distribution. The full text of the license may be found at
@ -113,6 +113,7 @@ SecPerformancePpiCallBack (
@param BootFirmwareVolume Base address of the Boot Firmware Volume. @param BootFirmwareVolume Base address of the Boot Firmware Volume.
**/ **/
VOID VOID
NORETURN
EFIAPI EFIAPI
SecStartup ( SecStartup (
IN UINT32 SizeOfRam, IN UINT32 SizeOfRam,
@ -201,6 +202,11 @@ SecStartup (
// Initialize Debug Agent to support source level debug in SEC/PEI phases before memory ready. // Initialize Debug Agent to support source level debug in SEC/PEI phases before memory ready.
// //
InitializeDebugAgent (DEBUG_AGENT_INIT_PREMEM_SEC, &SecCoreData, SecStartupPhase2); InitializeDebugAgent (DEBUG_AGENT_INIT_PREMEM_SEC, &SecCoreData, SecStartupPhase2);
//
// Should not come here.
//
UNREACHABLE ();
} }
/** /**

View File

@ -1,7 +1,7 @@
/** @file /** @file
Master header file for SecCore. Master header file for SecCore.
Copyright (c) 2008 - 2017, Intel Corporation. All rights reserved.<BR> Copyright (c) 2008 - 2018, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at which accompanies this distribution. The full text of the license may be found at
@ -76,6 +76,7 @@ SecTemporaryRamDone (
@param BootFirmwareVolume Base address of the Boot Firmware Volume. @param BootFirmwareVolume Base address of the Boot Firmware Volume.
**/ **/
VOID VOID
NORETURN
EFIAPI EFIAPI
SecStartup ( SecStartup (
IN UINT32 SizeOfRam, IN UINT32 SizeOfRam,