[U-Boot] [Patch] make reset_cpu nonreturn.
Pavel Machek
pavel at denx.de
Tue Sep 11 02:17:41 CEST 2012
Hi!
> > From: Dinh Nguyen <dinguyen at altera.com>
> >
> > Add minimal support for Altera's SOCFPGA Cyclone 5 hardware.
> >
> > Applied on top of trini/WIP/spl-improvements v6
> [...]
>
> __noreturn attribute to reset_cpu() is still missing, but that's a minor thing.
Hmm, I thought about it, but I guess the right solution is below.
---
reset_cpu should never return, annotate it as such.
Signed-off-by: Pavel Machek <pavel at denx.de>
diff --git a/include/common.h b/include/common.h
index 55025c0..e57301f 100644
--- a/include/common.h
+++ b/include/common.h
@@ -582,7 +582,7 @@ int checkicache (void);
int checkdcache (void);
void upmconfig (unsigned int, unsigned int *, unsigned int);
ulong get_tbclk (void);
-void reset_cpu (ulong addr);
+void reset_cpu (ulong addr) __attribute__((noreturn));
#if defined (CONFIG_OF_LIBFDT) && defined (CONFIG_OF_BOARD_SETUP)
void ft_cpu_setup(void *blob, bd_t *bd);
#ifdef CONFIG_PCI
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
More information about the U-Boot
mailing list