summaryrefslogtreecommitdiffstats
path: root/UefiCpuPkg/SecCore
diff options
context:
space:
mode:
authorMarvin H?user <Marvin.Haeuser@outlook.com>2018-02-28 00:50:59 +0800
committerEric Dong <eric.dong@intel.com>2018-05-08 19:45:45 +0800
commit7cd8a57599b519c4ead0c0eadbb52469eaf2dda5 (patch)
tree4888316342e84d4a5a4f94362865bfc6b3a348a5 /UefiCpuPkg/SecCore
parentee3198e672e2f27d31e82adad572dbb4f3bbdf1f (diff)
downloadedk2-7cd8a57599b519c4ead0c0eadbb52469eaf2dda5.tar.gz
edk2-7cd8a57599b519c4ead0c0eadbb52469eaf2dda5.tar.bz2
edk2-7cd8a57599b519c4ead0c0eadbb52469eaf2dda5.zip
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>
Diffstat (limited to 'UefiCpuPkg/SecCore')
-rw-r--r--UefiCpuPkg/SecCore/SecMain.c8
-rw-r--r--UefiCpuPkg/SecCore/SecMain.h3
2 files changed, 9 insertions, 2 deletions
diff --git a/UefiCpuPkg/SecCore/SecMain.c b/UefiCpuPkg/SecCore/SecMain.c
index c241d3704a..b24e190617 100644
--- a/UefiCpuPkg/SecCore/SecMain.c
+++ b/UefiCpuPkg/SecCore/SecMain.c
@@ -1,7 +1,7 @@
/** @file
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
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
@@ -113,6 +113,7 @@ SecPerformancePpiCallBack (
@param BootFirmwareVolume Base address of the Boot Firmware Volume.
**/
VOID
+NORETURN
EFIAPI
SecStartup (
IN UINT32 SizeOfRam,
@@ -201,6 +202,11 @@ SecStartup (
// Initialize Debug Agent to support source level debug in SEC/PEI phases before memory ready.
//
InitializeDebugAgent (DEBUG_AGENT_INIT_PREMEM_SEC, &SecCoreData, SecStartupPhase2);
+
+ //
+ // Should not come here.
+ //
+ UNREACHABLE ();
}
/**
diff --git a/UefiCpuPkg/SecCore/SecMain.h b/UefiCpuPkg/SecCore/SecMain.h
index 46c7d41c6e..4bc6606044 100644
--- a/UefiCpuPkg/SecCore/SecMain.h
+++ b/UefiCpuPkg/SecCore/SecMain.h
@@ -1,7 +1,7 @@
/** @file
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
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
@@ -76,6 +76,7 @@ SecTemporaryRamDone (
@param BootFirmwareVolume Base address of the Boot Firmware Volume.
**/
VOID
+NORETURN
EFIAPI
SecStartup (
IN UINT32 SizeOfRam,