blob: 2dc07c1d811fa9297fb9f1e50cd5e378476d827b [file] [log] [blame]
Kevin O'Connor1f2c3072009-05-06 23:35:59 -04001// Rom layout and bios assembler to C interface.
2//
3// Copyright (C) 2009 Kevin O'Connor <kevin@koconnor.net>
4//
5// This file may be distributed under the terms of the GNU LGPLv3 license.
6
7
8/****************************************************************
9 * Include of 16bit C code
10 ****************************************************************/
11
12 .code16gcc
Kevin O'Connor3dba4c22011-01-29 11:26:54 -050013#include "vgaccode.16.s"
Kevin O'Connor1f2c3072009-05-06 23:35:59 -040014
Julian Pidancet7c6509c2011-12-19 05:07:55 +000015#include "config.h" // CONFIG_*
Kevin O'Connor1f2c3072009-05-06 23:35:59 -040016#include "entryfuncs.S" // ENTRY_*
17
18
19/****************************************************************
20 * Rom Header
21 ****************************************************************/
22
23 .section .rom.header
24 .global _rom_header, _rom_header_size, _rom_header_checksum
25_rom_header:
26 .word 0xaa55
27_rom_header_size:
28 .byte 0
29_rom_header_entry:
30 jmp _optionrom_entry
31_rom_header_checksum:
Kevin O'Connorc9d3c2d2010-01-01 12:53:32 -050032 .byte 0
33_rom_header_other:
Julian Pidancet7c6509c2011-12-19 05:07:55 +000034 .space 17
35_rom_header_pcidata:
36#if CONFIG_VGA_PCI == 1
37 .word rom_pci_data
38#else
39 .word 0
40#endif
41_rom_header_pnpdata:
42 .word 0
Kevin O'Connor1f2c3072009-05-06 23:35:59 -040043
44
45/****************************************************************
46 * Entry points
47 ****************************************************************/
48
49 DECLFUNC _optionrom_entry
50_optionrom_entry:
51 ENTRY_ARG vga_post
52 lretw
53
Kevin O'Connor9f193b92009-05-16 23:31:27 -040054 DECLFUNC entry_10
55entry_10:
56 ENTRY_ARG handle_10
57 iretw