blob: 90b2ec0df610b0b6416bdefe18724a92129e9c2c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
/* boot.S
* assembler bootstrap
*
* Copyright (C) 2003 Stefan Reinauer
*
* See the file "COPYING" for further information about
* the copyright and warranty status of this work.
*/
#define ASM 1
#include <multiboot.h>
.text
.code32
.globl start, _start
/* unused */
start:
_start:
/* Initialize stack pointer. */
movl $(stack + STACK_SIZE), %esp
/* Reset EFLAGS. */
pushl $0
popf
/* parameter 2 */
pushl %ebx
/* parameter 1 */
pushl %eax
/* jump to C main function... */
call EXT_C(cmain)
loop: hlt
jmp loop
.comm stack, STACK_SIZE /* stack area. */
|