Module Name: src Committed By: roy Date: Sat Feb 4 13:36:07 UTC 2017
Modified Files: src/sys/arch/i386/stand/efiboot: Makefile.efiboot panic.c Log Message: Mark reboot() and _rtt() as __dead. Use __builtin_unreachable() to ensure Panic really is marked dead. Thanks to joerg@ To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/arch/i386/stand/efiboot/Makefile.efiboot cvs rdiff -u -r1.1 -r1.2 src/sys/arch/i386/stand/efiboot/panic.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/i386/stand/efiboot/Makefile.efiboot diff -u src/sys/arch/i386/stand/efiboot/Makefile.efiboot:1.2 src/sys/arch/i386/stand/efiboot/Makefile.efiboot:1.3 --- src/sys/arch/i386/stand/efiboot/Makefile.efiboot:1.2 Fri Feb 3 17:24:43 2017 +++ src/sys/arch/i386/stand/efiboot/Makefile.efiboot Sat Feb 4 13:36:07 2017 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.efiboot,v 1.2 2017/02/03 17:24:43 roy Exp $ +# $NetBSD: Makefile.efiboot,v 1.3 2017/02/04 13:36:07 roy Exp $ S= ${.CURDIR}/../../../../.. @@ -46,7 +46,6 @@ CPPFLAGS+= -I$S -I${.CURDIR} -I${.CURDIR CPPFLAGS+= -I${.OBJDIR} CPPFLAGS+= -I${.CURDIR}/../../lib -CWARNFLAGS.clang+= -Wno-invalid-noreturn #panic.c COPTS+= -ffreestanding -fPIC -fshort-wchar -fno-strict-aliasing -fno-builtin COPTS+= -fno-stack-protector COPTS+= ${${ACTIVE_CC} == "gcc":? -falign-functions=16 :} Index: src/sys/arch/i386/stand/efiboot/panic.c diff -u src/sys/arch/i386/stand/efiboot/panic.c:1.1 src/sys/arch/i386/stand/efiboot/panic.c:1.2 --- src/sys/arch/i386/stand/efiboot/panic.c:1.1 Tue Jan 24 11:09:14 2017 +++ src/sys/arch/i386/stand/efiboot/panic.c Sat Feb 4 13:36:07 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: panic.c,v 1.1 2017/01/24 11:09:14 nonaka Exp $ */ +/* $NetBSD: panic.c,v 1.2 2017/02/04 13:36:07 roy Exp $ */ /*- * Copyright (c) 2016 Kimihiro Nonaka <non...@netbsd.org> @@ -47,9 +47,10 @@ Panic( va_end(args); reboot(); /*NOTREACHED*/ + __builtin_unreachable(); } -void +__dead void reboot(void) { @@ -61,7 +62,7 @@ reboot(void) continue; } -void +__dead void _rtt(void) {