complier.h: add __noreturn and use it in code base
Add a __noreturn macro that wraps __attribute__((noreturn)) and replace current users with the macro. Change-Id: Iddd0728cf79678c3d1c1f7e7946c27375a644a7d Signed-off-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: https://review.coreboot.org/28505 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Furquan Shaikh <furquan@google.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
This commit is contained in:
committed by
Patrick Georgi
parent
261d626669
commit
0370bcf40c
@@ -20,7 +20,6 @@
|
||||
#include <halt.h>
|
||||
|
||||
#ifndef __ROMCC__
|
||||
#define NORETURN __attribute__((noreturn))
|
||||
|
||||
/*
|
||||
* The method should be overwritten in mainboard directory to signal that a
|
||||
@@ -33,7 +32,7 @@ __weak void die_notify(void)
|
||||
}
|
||||
|
||||
/* Report a fatal error */
|
||||
void NORETURN die(const char *msg)
|
||||
void __noreturn die(const char *msg)
|
||||
{
|
||||
printk(BIOS_EMERG, "%s", msg);
|
||||
die_notify();
|
||||
|
Reference in New Issue
Block a user