Test program for the VESA code
[syslinux.git] / layout.inc
blobd688a6e9ae131e87c8e471b0aaa83845f015193b
1 ; -----------------------------------------------------------------------
3 ;   Copyright 1994-2004 H. Peter Anvin - All Rights Reserved
5 ;   This program is free software; you can redistribute it and/or modify
6 ;   it under the terms of the GNU General Public License as published by
7 ;   the Free Software Foundation, Inc., 53 Temple Place Ste 330,
8 ;   Bostom MA 02111-1307, USA; either version 2 of the License, or
9 ;   (at your option) any later version; incorporated herein by reference.
11 ; -----------------------------------------------------------------------
14 ; layout.inc
16 ; Memory layout of segments
20 ; Memory below 0800h is reserved for the BIOS and the MBR.
21 BSS_START       equ 0800h
23 ; Text starts at the load address of 07C00h.
24 TEXT_START      equ 7C00h
26 ; The secondary BSS section, above the text; we really wish we could
27 ; just make it follow .bcopy32 or hang off the end,
28 ; but it doesn't seem to work that way.
29 LATEBSS_START   equ 0B400h
31 ; Reserve memory for the stack.  This causes checkov to abort the
32 ; compile if we violate this space.
33 STACK_SIZE      equ 4096
34 STACK_START     equ TEXT_START-STACK_SIZE
36 %ifdef MAP
37                 [map all MAP]
38 %endif
41 ; The various sections and their relationship
43                 org TEXT_START
45                 ; NASM BUG: refers to hacks to handle NASM 0.98.38 bugs; might need
46                 ; conditional compilation
48                 section .earlybss nobits start=BSS_START
49                 section .bcopy32  align=4 valign=16 follows=.data vfollows=.earlybss
50                 ; NASM BUG: follows= here should be vfollows=
51                 section .bss      nobits align=256 follows=.bcopy32
53                 section .text     start=TEXT_START
54                 ; NASM BUG: follows=.text not accepted here
55                 section .data     align=16 ; follows=.text
57                 ; NASM BUG: We would like to do follows=.bcopy32
58                 section .latebss  nobits align=16 start=LATEBSS_START
60                 ; Reserve space for stack
61                 section .stack    nobits align=16 start=STACK_START
62 Stack           resb    STACK_SIZE