[Top][All Lists]

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

Re: [Qemu-ppc] [PATCH] scsi-bus: fix endianness bug in store_lun()

From: Benjamin Herrenschmidt
Subject: Re: [Qemu-ppc] [PATCH] scsi-bus: fix endianness bug in store_lun()
Date: Sun, 17 Mar 2013 02:32:06 +0100

On Sat, 2013-03-16 at 14:09 +0100, Paolo Bonzini wrote:

> > The confusion comes from the old SCSI protocol LUN as a 2 bytes number
> > identifying a unit for a given bus/device and the "new style" LUN as a
> > more generic concept such as used in SRP (ie vscsi is SRP) which
> > encompass the bus, ID and LUN in one big number.
> > 
> > The actual type of LUN returned by REPORT_LUN depends on the
> > SELECT_REPORT field (I don't remember the details, but the doco you
> > point to say to see what's in SAM-4) and the result is *variable* in
> > size, so it should be kosher for qemu to just return 2 bytes as long as
> > the LUN_LIST_LENGTH field of the reply is correct.
> No, that's wrong.  Each LUN returned by REPORT LUNS is always 8 bytes.
> The field tells you if you are reporting all LUNs, only well-known LUNs,
> etc.

Ok, my bad then, I misread the spec even more badly than Alexey did ;-)
Anyway, the fix needs to be in SLOF.


reply via email to

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