* grub-core/boot/i386/pc/boot.S: Fix floppy probe. Due to missing
%dx restore the probe worked on non-existant drive. Reorganize the code a little bit to free 2 bytes necessary for push/pop.
This commit is contained in:
parent
9eec9699b9
commit
6f2e82be3a
2 changed files with 12 additions and 4 deletions
|
@ -1,3 +1,9 @@
|
||||||
|
2013-11-24 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
|
* grub-core/boot/i386/pc/boot.S: Fix floppy probe. Due to missing
|
||||||
|
%dx restore the probe worked on non-existant drive. Reorganize the
|
||||||
|
code a little bit to free 2 bytes necessary for push/pop.
|
||||||
|
|
||||||
2013-11-23 Vladimir Serbinenko <phcoder@gmail.com>
|
2013-11-23 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
* grub-core/kern/mips/arc/init.c (grub_machine_get_bootlocation):
|
* grub-core/kern/mips/arc/init.c (grub_machine_get_bootlocation):
|
||||||
|
|
|
@ -35,6 +35,7 @@ probe_values:
|
||||||
.byte 36, 18, 15, 9, 0
|
.byte 36, 18, 15, 9, 0
|
||||||
|
|
||||||
LOCAL(floppy_probe):
|
LOCAL(floppy_probe):
|
||||||
|
pushw %dx
|
||||||
/*
|
/*
|
||||||
* Perform floppy probe.
|
* Perform floppy probe.
|
||||||
*/
|
*/
|
||||||
|
@ -50,8 +51,8 @@ LOCAL(probe_loop):
|
||||||
movb (%si), %cl
|
movb (%si), %cl
|
||||||
|
|
||||||
/* if number of sectors is 0, display error and die */
|
/* if number of sectors is 0, display error and die */
|
||||||
cmpb $0, %cl
|
testb %cl, %cl
|
||||||
jne 1f
|
jnz 1f
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Floppy disk probe failure.
|
* Floppy disk probe failure.
|
||||||
|
@ -318,11 +319,12 @@ LOCAL(chs_mode):
|
||||||
int $0x13
|
int $0x13
|
||||||
jnc LOCAL(final_init)
|
jnc LOCAL(final_init)
|
||||||
|
|
||||||
|
popw %dx
|
||||||
/*
|
/*
|
||||||
* The call failed, so maybe use the floppy probe instead.
|
* The call failed, so maybe use the floppy probe instead.
|
||||||
*/
|
*/
|
||||||
testb $GRUB_BOOT_MACHINE_BIOS_HD_FLAG, %dl
|
testb %dl, %dl
|
||||||
jz LOCAL(floppy_probe)
|
jnb LOCAL(floppy_probe)
|
||||||
|
|
||||||
/* Nope, we definitely have a hard disk, and we're screwed. */
|
/* Nope, we definitely have a hard disk, and we're screwed. */
|
||||||
ERR(hd_probe_error_string)
|
ERR(hd_probe_error_string)
|
||||||
|
|
Loading…
Reference in a new issue