Skip to contentSkip to conversation

panic: remove warning "'noreturn' function does return"

PATCH New Heiko Schocher 2 participants 2 messages Jul 27, 2011 – Jul 28, 2011

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 panic: remove warning "'noreturn' function does return"

since commit

commit d2e8b911c0a0661d395ccac72156040702ac842d

Author: Mike Frysinger <[email protected]>
Date:   Wed Jun 29 11:58:04 2011 +0000

panic: add noreturn attribute

I see the following warnings:

vsprintf.c: In function 'panic':
vsprintf.c:730: warning: 'noreturn' function does return

for nearly all boards. This patch fixes this warning.

---
 lib/vsprintf.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
lib/vsprintf.c +2 -0
index 3b924ec..c029fbb 100644
@@ -727,4 +727,6 @@ void panic(const char *fmt, ...)
 	udelay (100000);	/* allow messages to go out */
 	do_reset (NULL, 0, 0, NULL);
 #endif
+	while (1)
+		;
 }
Signature · 1 line
1.7.6
#1 lore raw

PATCH 1/1 panic: remove warning "'noreturn' function does return"

Dear Heiko Schocher,

Quoted 13 lines · In message <[email protected]> you wrote:

since commit

commit d2e8b911c0a0661d395ccac72156040702ac842d

Author: Mike Frysinger <[email protected]>
Date:   Wed Jun 29 11:58:04 2011 +0000

panic: add noreturn attribute

I see the following warnings:

vsprintf.c: In function 'panic':
vsprintf.c:730: warning: 'noreturn' function does return

Quoted 7 lines

for nearly all boards. This patch fixes this warning.

---
 lib/vsprintf.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

Applied, thanks.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"We don't have to protect the environment -- the Second Coming is  at
hand."                                                   - James Watt