qemu-block
[Top][All Lists]
Advanced

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

Re: [Qemu-block] [PATCH 1/2] iscsi: Translate scsi sense into error code


From: Paolo Bonzini
Subject: Re: [Qemu-block] [PATCH 1/2] iscsi: Translate scsi sense into error code
Date: Thu, 22 Oct 2015 11:56:15 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0


On 22/10/2015 11:51, Fam Zheng wrote:
> > > 
> > > +    switch (sense->key) {
> > > +    case SCSI_SENSE_NO_SENSE:
> > > +        return 0;
> > > +        break;
> > > +    case SCSI_SENSE_NOT_READY:
> > > +        return -EBUSY;
> > > +        break;
> > > +    case SCSI_SENSE_DATA_PROTECTION:
> > > +        return -EACCES;
> > 
> > Probably EPERM, not EACCES.
> 
> The comment of bdrv_write says -EACCES for read-only device, shoudn't this be
> the same?

Oh, then that's fine.  I was looking at the write(2) man page.



reply via email to

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