qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH][RESEND] ide: fix ATAPI read drive structure com


From: Alex Williamson
Subject: Re: [Qemu-devel] [PATCH][RESEND] ide: fix ATAPI read drive structure command (v3)
Date: Tue, 10 Jun 2008 06:21:20 -0600

Hi Carlo,

On Mon, 2008-06-09 at 03:52 -0500, Carlo Marcelo Arenas Belon wrote:
> On Sun, Jun 08, 2008 at 08:14:05PM -0600, Alex Williamson wrote:
> > Hi,
> > 
> > Resend of patch from last week.  This has been review by Alexander Graf
> > and Anthony Liguori.  The patch fixes diskpart.exe working in Vista when
> > a DVD image is loaded.  Please apply to trunk.  Thanks,
> 
> Tested it with Linux/OpenSolaris guests and confirmed no obvious regressions
> but I haven't traced specifically calls to this function (as used by diskpart
> in Vista).

Thanks for testing.

> > +            if (format < 0xff && media_is_cd(s)) {
> >                  ide_atapi_cmd_error(s, SENSE_ILLEGAL_REQUEST,
> > -                                    ASC_INV_FIELD_IN_CMD_PACKET);
> > +                                    ASC_INCOMPATIBLE_FORMAT);
> > +                break;
> 
> couldn't find a reference to this in MMC6's READ DISK STRUCTURE command, why
> is format = 0xff allowed if the media is a CD, what about when there is no
> media?

>From mmc-6r1 draft, section 6.22.3.1.7 (Format Code FFh: Disc Structure
List):

        This Disc Structure is generated by the Drive rather than read
        from the medium. Consequently, this structure shall be returned
        regardless of media presence.

Drive implementations that I tested with sg_raw seem to vary quite a bit
here.  One drive I had on hand behaved as I would expect and returned
data for format 0xff with CD or DVD media or empty.  Another only
returned data if DVD media was loaded.  I think the patch implements it
per the spec.  Let me know if you disagree.  Thanks,

        Alex

-- 
Alex Williamson                             HP Open Source & Linux Org.





reply via email to

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