source: xtideuniversalbios/trunk/Configurator/Inc/RomVars.inc@ 180

Last change on this file since 180 was 2, checked in by Tomi Tilli, 14 years ago
File size: 3.3 KB
Line 
1; File name : RomVars.inc
2; Project name : IDE BIOS
3; Created date : 23.3.2010
4; Last update : 1.5.2010
5; Author : Tomi Tilli
6; Description : Defines for ROMVARS struct containing variables stored
7; in BIOS ROM.
8%ifndef ROMVARS_INC
9%define ROMVARS_INC
10
11; ROM Variables. There are written to ROM image before flashing.
12struc ROMVARS
13 .wRomSign resb 2 ; ROM Signature (AA55h)
14 .bRomSize resb 1 ; ROM size in 512 byte blocks
15 .rgbJump resb 5 ; First instruction to ROM init (jmp)
16 ; Offset 8 (8h) starts here
17 .rgbDate resb 8 ; BIOS build date string (mm/dd/yy)
18 ; Offset 16 (10h) starts here
19 .rgbSign resb 8 ; Signature for XTIDE Configurator Program
20 .szTitle resb 31 ; BIOS title string
21 .szVersion resb 25 ; BIOS version string
22 ; Offset 80 (50h) starts here
23 .wFlags resb 2 ; Word for ROM flags
24 .bIdeCnt resb 1 ; Number of supported IDE controllers
25 .bBootDrv resb 1 ; Boot Menu default drive
26 .bBootMnuH resb 1 ; Boot Menu maximum height
27 .bBootDelay resb 1 ; Boot Menu selection delay in seconds
28 .bBootLdrType resb 1 ; Boot Loader type
29 .bMinFddCnt resb 1 ; Minimum number of Floppy Drives
30 .bStealSize resb 1 ; Number of 1kB blocks stolen from 640kB base RAM
31 resb 7
32 ; Offset 96 (60h) starts here
33 ; Last IDEVARS must not start after offset FFh.
34 .ideVars0 resb IDEVARS_size
35 .ideVars1 resb IDEVARS_size
36 .ideVars2 resb IDEVARS_size
37 .ideVars3 resb IDEVARS_size
38 .ideVars4 resb IDEVARS_size
39endstruc
40
41; Bit defines for ROMVARS.wFlags
42FLG_ROMVARS_FULLMODE EQU (1<<0) ; Full operating mode (steals base RAM, supports EBIOS etc.)
43FLG_ROMVARS_LATE EQU (1<<1) ; Late initialization
44FLG_ROMVARS_DRVXLAT EQU (1<<2) ; Enable drive number translation
45FLG_ROMVARS_ROMBOOT EQU (1<<3) ; Include ROMBOOT to boot menu
46FLG_ROMVARS_DRVNFO EQU (1<<4) ; Display drive info on boot menu
47FLG_ROMVARS_MAXSIZE EQU (1<<5) ; Maximize size by sacrificing compatibility with some old BIOSes
48
49; Bootloader types for ROMVARS.bBootLdrType
50BOOTLOADER_TYPE_MENU EQU (0<<1) ; Display boot menu on boot loader
51BOOTLOADER_TYPE_SIMPLE EQU (1<<1) ; Simple bootloader without menu
52BOOTLOADER_TYPE_NONE EQU (3<<1) ; Do not install boot loader
53
54
55; Controller specific variables
56struc IDEVARS
57 .wPort resb 2 ; IDE Base Port for Command Block (usual) Registers
58 .wPortCtrl resb 2 ; IDE Base Port for Control Block Registers
59 .bBusType resb 1 ; Bus type
60 .bIRQ resb 1 ; Interrupt Request Number
61 resb 4 ; Reserved
62 .drvParamsMaster resb DRVPARAMS_size
63 .drvParamsSlave resb DRVPARAMS_size
64endstruc
65
66; Bus types for IDEVARS.bBusType
67BUS_TYPE_8_DUAL EQU (0<<1) ; XTIDE transfers with two 8-bit data ports
68BUS_TYPE_16 EQU (1<<1) ; Normal 16-bit AT-IDE transfers
69BUS_TYPE_32 EQU (2<<1) ; 32-bit VLB and PCI transfers
70BUS_TYPE_8_SINGLE EQU (3<<1) ; 8-bit transfers with single 8-bit data port
71
72
73; Master/Slave drive specific parameters
74struc DRVPARAMS
75 .wFlags resb 2 ; Drive flags
76 resb 2 ; Reserved
77 .wCylinders resb 2 ; User specified cylinders (1...16383)
78 .wSectAndHeads:
79 .bSect resb 1 ; User specified Sectors per track (1...63)
80 .bHeads resb 1 ; User specified Heads (1...16)
81endstruc
82
83; Bit defines for DRVPARAMS.wFlags
84FLG_DRVPARAMS_USERCHS EQU (1<<0) ; User specified P-CHS values
85FLG_DRVPARAMS_BLOCKMODE EQU (1<<1) ; Enable Block mode transfers
86
87
88%endif ; ROMVARS_INC
Note: See TracBrowser for help on using the repository browser.