Kevin O'Connor | 1f2c307 | 2009-05-06 23:35:59 -0400 | [diff] [blame] | 1 | // 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'Connor | 3dba4c2 | 2011-01-29 11:26:54 -0500 | [diff] [blame] | 13 | #include "vgaccode.16.s" |
Kevin O'Connor | 1f2c307 | 2009-05-06 23:35:59 -0400 | [diff] [blame] | 14 | |
Julian Pidancet | 7c6509c | 2011-12-19 05:07:55 +0000 | [diff] [blame] | 15 | #include "config.h" // CONFIG_* |
Kevin O'Connor | 1f2c307 | 2009-05-06 23:35:59 -0400 | [diff] [blame] | 16 | #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'Connor | c9d3c2d | 2010-01-01 12:53:32 -0500 | [diff] [blame] | 32 | .byte 0 |
| 33 | _rom_header_other: |
Julian Pidancet | 7c6509c | 2011-12-19 05:07:55 +0000 | [diff] [blame] | 34 | .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'Connor | 72b5e45 | 2011-12-23 23:01:48 -0500 | [diff] [blame] | 43 | _rom_header_other2: |
| 44 | .word 0 |
| 45 | _rom_header_signature: |
| 46 | .asciz "IBM" |
Kevin O'Connor | 1f2c307 | 2009-05-06 23:35:59 -0400 | [diff] [blame] | 47 | |
| 48 | |
| 49 | /**************************************************************** |
| 50 | * Entry points |
| 51 | ****************************************************************/ |
| 52 | |
Kevin O'Connor | 9961f99 | 2012-01-21 11:53:44 -0500 | [diff] [blame^] | 53 | DECLFUNC entry_104f05 |
| 54 | entry_104f05: |
| 55 | ENTRY_ARG vbe_104f05 |
| 56 | lretw |
| 57 | |
Kevin O'Connor | 1f2c307 | 2009-05-06 23:35:59 -0400 | [diff] [blame] | 58 | DECLFUNC _optionrom_entry |
| 59 | _optionrom_entry: |
| 60 | ENTRY_ARG vga_post |
| 61 | lretw |
| 62 | |
Kevin O'Connor | 9f193b9 | 2009-05-16 23:31:27 -0400 | [diff] [blame] | 63 | DECLFUNC entry_10 |
| 64 | entry_10: |
| 65 | ENTRY_ARG handle_10 |
| 66 | iretw |