Update comments, put LOADER_PHYS_BASE back at 3 GB.
[pintos-anon] / src / threads / loader.h
1 #ifndef HEADER_LOADER_H
2 #define HEADER_LOADER_H
3
4 /* Constants fixed by the PC BIOS. */
5 #define LOADER_BASE 0x7c00      /* Physical address of loader's base. */
6 #define LOADER_SIZE 0x200       /* Loader size in bytes (one disk sector). */
7
8 /* Physical address of kernel base. */
9 #define LOADER_KERN_BASE 0x100000       /* 1 MB. */
10
11 /* Kernel virtual address at which all physical memory is mapped.
12
13    The loader maps the 4 MB at the bottom of physical memory to
14    this virtual base address.  Later, paging_init() adds the rest
15    of physical memory to the mapping.
16
17    This must be aligned on a 4 MB boundary. */
18 #define LOADER_PHYS_BASE 0xc0000000     /* 3 GB. */
19
20 /* Offsets within the loader. */
21 #define LOADER_BIOS_SIG (LOADER_SIZE - 2)        /* aa55 BIOS signature. */
22 #define LOADER_CMD_LINE (LOADER_BIOS_SIG - 0x80) /* Kernel command line. */
23 #define LOADER_RAM_PAGES (LOADER_CMD_LINE - 4)   /* # of pages of RAM. */
24
25 #endif /* loader.h */