Read bootorder file into memory.
[seabios.git] / src / boot.h
1 // Storage for boot definitions.
2 #ifndef __BOOT_H
3 #define __BOOT_H
4
5
6 /****************************************************************
7  * Initial Program Load (IPL)
8  ****************************************************************/
9
10 struct ipl_entry_s {
11     u16 type;
12     u16 subchoice;
13     u32 vector;
14     const char *description;
15 };
16
17 struct ipl_s {
18     struct ipl_entry_s bev[8];
19     struct ipl_entry_s bcv[8];
20     int bevcount, bcvcount;
21     u32 bootorder;
22     int checkfloppysig;
23     char **fw_bootorder;
24     int fw_bootorder_count;
25 };
26
27 #define IPL_TYPE_FLOPPY      0x01
28 #define IPL_TYPE_HARDDISK    0x02
29 #define IPL_TYPE_CDROM       0x03
30 #define IPL_TYPE_CBFS        0x20
31 #define IPL_TYPE_BEV         0x80
32
33 #define BCV_TYPE_EXTERNAL    0x80
34 #define BCV_TYPE_INTERNAL    0x02
35
36
37 /****************************************************************
38  * Function defs
39  ****************************************************************/
40
41 // boot.c
42 extern struct ipl_s IPL;
43 void boot_setup(void);
44 void add_bev(u16 seg, u16 bev, u16 desc);
45 void add_bcv(u16 seg, u16 ip, u16 desc);
46 struct drive_s;
47 void add_bcv_internal(struct drive_s *drive_g);
48 void add_baid_cdrom(struct drive_s *drive_g);
49
50 void boot_prep(void);
51
52 #endif // __BOOT_H