-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2100 from ghaerr/bootopts
[boot] Expand /bootopts to 1023 bytes
- Loading branch information
Showing
8 changed files
with
94 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,10 +7,9 @@ | |
! both setup.s and system has been loaded by the bootblock. | ||
! | ||
! This code asks the bios for memory/disk/other parameters, and | ||
! puts them in a "safe" place: INITSEG:0-INITSEG:01FF, ie where the | ||
! boot-block used to be. It is then up to the protected mode | ||
! system to read them from there before the area is overwritten | ||
! for buffer-blocks. | ||
! puts them in a "safe" place: REL_INITSEG:0-REL_INITSEG:01FF, ie where | ||
! the boot-block used to be. It is then up to the kernel to read them | ||
! from there before the area is released to the main memory allocator. | ||
! | ||
! Move PS/2 aux init code to psaux.c | ||
! ([email protected]) 03Oct92 | ||
|
@@ -36,7 +35,7 @@ | |
! | ||
! index | ||
! ... | ||
! 4: display page | ||
! 4: display page, 1 byte UNUSED | ||
! 6: video mode, 1 byte | ||
! 7: screen_cols, 1 byte | ||
! 8: video data, 2 bytes | ||
|
@@ -899,7 +898,6 @@ novga: mov %al,14 // CGA 25 rows | |
|
||
mov $0x0f,%ah | ||
int $0x10 | ||
mov %bx,4 // bh = display page | ||
mov %ax,6 // al = video mode, ah = window width | ||
|
||
call getcpu // implemented in cputype.S | ||
|
@@ -946,7 +944,10 @@ putc: push %ax | |
|
||
#ifdef CONFIG_BOOTOPTS | ||
// | ||
// load /bootopts for FAT filesystem boot | ||
// load /bootopts file for FAT filesystem boot | ||
// If size > 512 bytes, both sectors must be contiguous. | ||
// This is currently guaranteed by providing a 1K /bootopts in | ||
// distribution images, so later edits will remain contiguous. | ||
// | ||
// Uses previous boot sector's BPB contents for disk geometry | ||
// and previous boot sector's buffer which still holds root directory sector. | ||
|
@@ -990,20 +991,19 @@ bootopts: | |
xor %bp,%bp | ||
|
||
mov root_dev,%al // Physical Device Address | ||
mov $0xD6,%ah // Read Data | ||
mov $512,%bx | ||
test $0x10,%al // Check Floppy Disk or Hard Disk | ||
mov $0xD6,%ah // Read Data | ||
mov $1024,%bx // 1K bytes | ||
test $0x10,%al // Check Floppy Disk or Hard Disk | ||
jz pc98_int1b | ||
#ifdef CONFIG_IMG_FD1232 | ||
mov $1024,%bx | ||
mov $0x03,%ch // 1024 Bytes per sector | ||
inc %dl // sector number for PC_98 Floppy Disk | ||
mov $0x03,%ch // 1024 Bytes per sector | ||
inc %dl // sector number for PC_98 Floppy Disk | ||
#else | ||
mov $0x02,%ch // 512 Bytes per sector | ||
inc %dl // sector number for PC_98 Floppy Disk | ||
mov $0x02,%ch // 512 Bytes per sector | ||
inc %dl // sector number for PC_98 Floppy Disk | ||
#endif | ||
pc98_int1b: | ||
int $0x1B // BIOS disk interrupt | ||
int $0x1B // BIOS disk interrupt | ||
pop %bp | ||
#else | ||
mov $INITSEG,%ax | ||
|
@@ -1013,7 +1013,7 @@ pc98_int1b: | |
mov $DEF_OPTSEG,%ax // ES:BX = DEF_OPTSEG:0 | ||
mov %ax,%es | ||
xor %bx,%bx | ||
mov $0x0201,%ax // BIOS read disk, 1 sector | ||
mov $0x0202,%ax // BIOS read disk, 2 sectors | ||
int $0x13 // BIOS disk interrupt | ||
#endif | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.