[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM sup
From: |
Carlo Marcelo Arenas Belon |
Subject: |
Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support |
Date: |
Sat, 5 Jan 2008 20:22:33 -0600 |
User-agent: |
Mutt/1.4.1i |
On Sat, Jan 05, 2008 at 10:28:34AM +0000, Stuart Brady wrote:
> On Fri, Jan 04, 2008 at 09:53:09PM -0600, Rob Landley wrote:
> > Except that according to http://en.wikipedia.org/wiki/CD-ROM it's actually
> > 703
> > and 1/8 binary megabytes (360,000 sectors *2048 bytes), which would be
> > 1440000.
>
> Apparently that value comes from 75 sectors per second * 80 minutes...
> 75*80*60 = 360000, and of course, 360000*2048/512 = 1440000, although
> it actually seems that it should be one sector less than 80 minutes,
> which is 359999 2048-byte sectors or 1439996 512-byte chunks.
>
> BTW, there are/were also 90 and 99 minute 'CD-Rs' -- Wikipedia's page on
> CD-Rs describes them, but they were never very popular, and a lot of
> drives can't read the discs.
the exact number of sectors is really not that relevant, as the whole point
here is to try to detect if it is a CD (700MB) or a DVD (4.7GB) and the logic
is just assuming that if it has more sectors than you should normally expect
in a CD, then it is a DVD.
attached the program I used in the guests (only works on Linux) to poke the
emulated drive (or a physical drive if you feel like) and compare the responses
(you will need to take a look at the SPEC tables to interpret the data though)
for my own tests (using a linux guest with -cdrom /dev/cdrom in my linux
host that has a DVD-+RW drive) :
700MB CD-R = 1374880 (with FreeSBIE 2.0.1)
4.7GB DVD-R = 6939520 (with SXDE 9/07)
feel free to report back with the value to use then if you happen to have a CD
that is completely full but I had already enough problems trying to get this
merged without trying to change the code that much to try to guess a better
magic number than the one was originally used (I like 1440000 though)
Carlo
ide-atapi.c
Description: Text document
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Carlo Marcelo Arenas Belon, 2008/01/04
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Rob Landley, 2008/01/04
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Stuart Brady, 2008/01/04
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Stuart Brady, 2008/01/04
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Carlo Marcelo Arenas Belon, 2008/01/04
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Rob Landley, 2008/01/04
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Stuart Brady, 2008/01/05
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support,
Carlo Marcelo Arenas Belon <=
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Stuart Brady, 2008/01/06
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Andreas Färber, 2008/01/06
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Carlo Marcelo Arenas Belon, 2008/01/06
- Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Carlo Marcelo Arenas Belon, 2008/01/06
Re: [Qemu-devel] [RESEND] [PATCH] ide: fix GET_CONFIGURATION DVD-ROM support, Carlo Marcelo Arenas Belon, 2008/01/04