Am 07.01.2016 um 11:07 schrieb Paolo Bonzini: > > On 06/01/2016 18:57, John Snow wrote: >> Ronnie: Thanks for the explanation! >> >> Zhu: In light of this, can the patch be reworked slightly to explicitly >> check *why* READCAPACITY16 failed and only attempt the READCAPACITY10 as >> a fallback if it receives INVALID_OPCODE? >> >> If it fails for any other reason it's probably best to report the error >> and let QEMU decide what to do about it. > Any other failure probably would happen for READ CAPACITY(10) as well, so > it's okay to ignore it for READ CAPACITY(16). > > Zhu's patch matches what Linux does by default, it seems okay. The only > change needed is to retry READ CAPACITY(16) if there is a UNIT ATTENTION > sense: > > + if (task != NULL && task->status == SCSI_STATUS_CHECK_CONDITION > + && task->sense.key == SCSI_SENSE_UNIT_ATTENTION) { > + break; > + } > > Paolo
Paolo, Ronnie, do you know what Readcapacity(10) returns if the target blocks count is greater than what can be described in 32bit? Anyway, is there a new version of this patch? I would also like to have a look before it is commited. Thanks, Peter