qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Floppy geometry detection and INT 13,8


From: Frode Vatvedt Fjeld
Subject: [Qemu-devel] Floppy geometry detection and INT 13,8
Date: Wed, 07 Mar 2007 23:35:33 -0000
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3

I stumbled upon a problem when trying to get Qemu to boot my homebrew
kernel image. For certain sizes of floppy image files, the (still
homebrew) bootloader failed to load the kernel properly.

After quite a bit of searching, I believe I pinned the problem down to
the fact that Qemu tries to adjust the geometry of the floppy to the
size of the image file. The kernel loaded fine when the floppy
geometry was determined to be "1.44 MB 3"1/2 floppy disk (2 h 80 t 18
s) rw", while it failed miserably when it was detected as "880 kB
5"1/4 floppy disk (2 h 80 t 11 s) rw". (The change was triggered by a
tiny change in file-size.)

I expected Qemu to emulate the 1.44 MB standard geometry regardless,
so this was quite surprising. I'd like to suggest that it would be
better to base the floppy geometry on user configuration rather than
auto-detection, because this can cause surprising behaviour and
confusion.

However, when I tried to take this variable floppy geometry into
account in my bootloader, by using the in 13,8 BIOS service, it didn't
work. This service reports 15 sectors/track rather than 11 as stated
above. Also, when I read the floppy (using in 13,2), it behaves
consistently with 11 sectors/track. So I'm unable to write a
bootloader that works with Qemu. This appears to me to be a bug in
Qemu, although I am no expert in how these BIOS services are supposed
to work.

Regards,
-- 
Frode Vatvedt Fjeld





reply via email to

[Prev in Thread] Current Thread [Next in Thread]