public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH][rfc] Use int as return type of main in arch/x86/boot/main.c
@ 2011-03-13 22:00 Jesper Juhl
  2011-03-14 11:32 ` Harry Wei
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Jesper Juhl @ 2011-03-13 22:00 UTC (permalink / raw)
  To: x86; +Cc: linux-kernel, Ingo Molnar, Thomas Gleixner, H. Peter Anvin

I believe the return type of main should always be 'int'.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
---
 main.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/x86/boot/main.c b/arch/x86/boot/main.c
index 40358c8..4b80da8 100644
--- a/arch/x86/boot/main.c
+++ b/arch/x86/boot/main.c
@@ -125,7 +125,7 @@ static void init_heap(void)
 	}
 }
 
-void main(void)
+int main(void)
 {
 	/* First, copy the boot header into the "zeropage" */
 	copy_boot_params();
@@ -175,4 +175,6 @@ void main(void)
 
 	/* Do the last things and invoke protected mode */
 	go_to_protected_mode();
+
+	return 0;
 }


-- 
Jesper Juhl <jj@chaosbits.net>            http://www.chaosbits.net/
Plain text mails only, please.
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2011-03-15 13:55 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-13 22:00 [PATCH][rfc] Use int as return type of main in arch/x86/boot/main.c Jesper Juhl
2011-03-14 11:32 ` Harry Wei
2011-03-14 16:49   ` H. Peter Anvin
2011-03-14 19:04     ` Steven Rostedt
2011-03-14 23:35     ` Jesper Juhl
2011-03-14 19:03 ` Steven Rostedt
2011-03-14 22:50   ` H. Peter Anvin
2011-03-15  2:31     ` Steven Rostedt
2011-03-15 13:55 ` WANG Cong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox