qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Fabrice Bellard <fabrice@bellard.org>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Re: Qemu floppy emulation problems - partially solved
Date: Sun, 03 Oct 2004 23:49:26 +0200	[thread overview]
Message-ID: <416073E6.6080009@bellard.org> (raw)
In-Reply-To: <20040831175536.A29557@edinburgh.cisco.com>

Applied a modified version. Tell me if it works.

Fabrice.

Derek Fawcus wrote:
> On Wed, Aug 18, 2004 at 05:35:19PM +0200, Mike Nordell wrote:
> 
>>Johannes Martin wrote:
>>
>>1. diskette_param_table in rombios.c from Bochs is too short. It neeed two
>>more bytes, else e.g. NT believes the floppy only got 31 cylinders (the code
>>following the table begins with "push ds", 0x1e, and that just happens to be
>>"maximum track" NT expects). Append:
>>db 79
>>db 0
>>
>>This is obvious if looking at the registry value
>>HKLM\HARDWARE\DESCRIPTION\System\MultifunctionAdapter\x\DiskController\y\Flo
>>ppyDiskPeripheral\0\Configuration Data.
>>
>>(x, y was 5 and 0 respectively on a real machine, but you might experience
>>local fluctuations)
>>
>>Compare the last two bytes from a real system (working) with a non-working
>>QEMU-installed system.
> 
> 
> Well that would seem to be an error in the NT code,  or we're triggering
> something in the NT code which makes it seem to think there should be
> a larger table.
> 
> The original table was only 11 bytes (as in the Bochs BIOS),  you can
> look at the interrupt list to see.  It seems there is an enhancement
> that adds an additional 3 bytes.
> 
> However from the layout of the BIOS,  it looks as if there is no room
> to expand the table in place,  one'll have to have the param table pointer
> (int 1e) point somewhere else.
> 
> Anyway,  I hacked something up if you want to try...
> 
> The diff is at http://www.employees.org/~dfawcus/rombios.c-diff,  and the
> rom image is at http://www.employees.org/~dfawcus/bios.bin
> 
> I've not tried your other diffs yet.
> 
> DF
> 
> Format of diskette parameter table:
> Offset  Size    Description     (Table 01264)
>  00h    BYTE    first specify byte
>                 bits 7-4: step rate (Fh=2ms,Eh=4ms,Dh=6ms,etc.)
>                 bits 3-0: head unload time (0Fh = 240 ms)
>  01h    BYTE    second specify byte
>                 bits 7-1: head load time (01h = 4 ms)
>                 bit    0: non-DMA mode (always 0)
>                 Note:   The DOS boot sector sets the head load time to 15ms,
>                           however, one should retry the operation on failure
>  02h    BYTE    delay until motor turned off (in clock ticks)
>  03h    BYTE    bytes per sector (00h = 128, 01h = 256, 02h = 512, 03h = 1024)
>  04h    BYTE    sectors per track (maximum if different for different tracks)
>  05h    BYTE    length of gap between sectors (2Ah for 5.25", 1Bh for 3.5")
>  06h    BYTE    data length (ignored if bytes-per-sector field nonzero)
>  07h    BYTE    gap length when formatting (50h for 5.25", 6Ch for 3.5")
>  08h    BYTE    format filler byte (default F6h)
>  09h    BYTE    head settle time in milliseconds
>  0Ah    BYTE    motor start time in 1/8 seconds
> ---IBM SurePath BIOS---
>  0Bh    BYTE    maximum track number
>  0Ch    BYTE    data transfer rate
>  0Dh    BYTE    drive type in CMOS
> 
> 
> 
> _______________________________________________
> Qemu-devel mailing list
> Qemu-devel@nongnu.org
> http://lists.nongnu.org/mailman/listinfo/qemu-devel
> 
> 

  reply	other threads:[~2004-10-03 21:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-18 15:35 [Qemu-devel] Re: Qemu floppy emulation problems - partially solved Mike Nordell
2004-08-31 16:55 ` Derek Fawcus
2004-10-03 21:49   ` Fabrice Bellard [this message]
2004-10-04 22:00     ` Derek Fawcus
  -- strict thread matches above, loose matches on Subject: below --
2004-10-07 13:37 Mike Nordell
2004-10-07 17:13 ` Derek Fawcus
2004-10-08  9:39 Mike Nordell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=416073E6.6080009@bellard.org \
    --to=fabrice@bellard.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).