| H. Peter Anvin | f2d98ae | 2007-07-11 12:18:55 -0700 | [diff] [blame] | 1 | /* | 
 | 2 |  * setup.ld | 
 | 3 |  * | 
 | 4 |  * Linker script for the i386 setup code | 
 | 5 |  */ | 
 | 6 | OUTPUT_FORMAT("elf32-i386", "elf32-i386", "elf32-i386") | 
 | 7 | OUTPUT_ARCH(i386) | 
 | 8 | ENTRY(_start) | 
 | 9 |  | 
 | 10 | SECTIONS | 
 | 11 | { | 
 | 12 | 	. = 0; | 
 | 13 | 	.bstext		: { *(.bstext) } | 
 | 14 | 	.bsdata		: { *(.bsdata) } | 
 | 15 |  | 
 | 16 | 	. = 497; | 
 | 17 | 	.header		: { *(.header) } | 
 | 18 | 	.inittext	: { *(.inittext) } | 
 | 19 | 	.initdata	: { *(.initdata) } | 
| H. Peter Anvin | be72169 | 2009-03-17 15:26:06 -0700 | [diff] [blame] | 20 | 	.text		: { *(.text) } | 
 | 21 | 	.text32		: { *(.text32) } | 
| H. Peter Anvin | f2d98ae | 2007-07-11 12:18:55 -0700 | [diff] [blame] | 22 |  | 
 | 23 | 	. = ALIGN(16); | 
 | 24 | 	.rodata		: { *(.rodata*) } | 
 | 25 |  | 
 | 26 | 	.videocards	: { | 
 | 27 | 		video_cards = .; | 
 | 28 | 		*(.videocards) | 
 | 29 | 		video_cards_end = .; | 
 | 30 | 	} | 
 | 31 |  | 
 | 32 | 	. = ALIGN(16); | 
 | 33 | 	.data		: { *(.data*) } | 
 | 34 |  | 
 | 35 | 	.signature	: { | 
 | 36 | 		setup_sig = .; | 
 | 37 | 		LONG(0x5a5aaa55) | 
 | 38 | 	} | 
 | 39 |  | 
 | 40 |  | 
 | 41 | 	. = ALIGN(16); | 
 | 42 | 	.bss		: | 
 | 43 | 	{ | 
 | 44 | 		__bss_start = .; | 
 | 45 | 		*(.bss) | 
 | 46 | 		__bss_end = .; | 
 | 47 | 	} | 
 | 48 | 	. = ALIGN(16); | 
 | 49 | 	_end = .; | 
 | 50 |  | 
 | 51 | 	/DISCARD/ : { *(.note*) } | 
 | 52 |  | 
 | 53 | 	. = ASSERT(_end <= 0x8000, "Setup too big!"); | 
 | 54 | 	. = ASSERT(hdr == 0x1f1, "The setup header has the wrong offset!"); | 
 | 55 | } |