diff options
author | Uwe Hermann <uwe@hermann-uwe.de> | 2008-03-20 19:54:59 +0000 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2008-03-20 19:54:59 +0000 |
commit | 6a441bfb46337ed6b59abed56dad35d94802282c (patch) | |
tree | 44eb1d67fcbc450907472186bbc0036afe9e380c /payloads/libpayload/i386/main.c | |
parent | 5f4c8abb6537fa7377969e837dab987abefcf922 (diff) |
Cosmetics, coding style fixes (trivial).
Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Acked-by: Uwe Hermann <uwe@hermann-uwe.de>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3180 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'payloads/libpayload/i386/main.c')
-rw-r--r-- | payloads/libpayload/i386/main.c | 47 |
1 files changed, 25 insertions, 22 deletions
diff --git a/payloads/libpayload/i386/main.c b/payloads/libpayload/i386/main.c index 846d46a426..ed5c1b9e9c 100644 --- a/payloads/libpayload/i386/main.c +++ b/payloads/libpayload/i386/main.c @@ -29,14 +29,12 @@ #include <arch/types.h> -/* This structure seeds the stack. We provide - the return address of our main function, and - further down, the address of the function - that we call when we leave and try to restore - the original stack. At the very bottom of the - stack we store the orignal stack pointer - from the calling application -*/ +/* + * This structure seeds the stack. We provide the return address of our main + * function, and further down, the address of the function that we call when + * we leave and try to restore the original stack. At the very bottom of the + * stack we store the orignal stack pointer from the calling application. + */ static void start_main(void); extern void _leave(void); @@ -45,35 +43,40 @@ static struct { uint32_t eip[2]; uint32_t raddr[2]; uint32_t esp; -} initial_stack __attribute__((section (".istack"))) = { +} initial_stack __attribute__ ((section(".istack"))) = { { (uint32_t) start_main, 0 }, { (uint32_t) _leave, 0 }, - (uint32_t) &initial_stack, + (uint32_t) & initial_stack, }; -void * _istack = &initial_stack; - -/* This is our C entry function - set up the system - and jump into the payload entry point */ +void *_istack = &initial_stack; +/** + * This is our C entry function - set up the system + * and jump into the payload entry point. + */ static void start_main(void) { extern int main(void); - /* Set up the consoles */ + /* Set up the consoles. */ console_init(); - /* Gather system information */ + /* Gather system information. */ lib_get_sysinfo(); - /* Any other system init that has to happen before the - user gets control goes here. */ + /* + * Any other system init that has to happen before the + * user gets control goes here. + */ - /* Go to the entry point */ + /* Go to the entry point. */ - /* in the future we may care about the return value */ + /* In the future we may care about the return value. */ (void) main(); - /* Returning here will go to the _leave function to return - us to the original context */ + /* + * Returning here will go to the _leave function to return + * us to the original context. + */ } |