pseries: rework PAPR virtual SCSI
commit8ca8a17c9a16eb3b2fedb3c74687c429e9cfc6aa
authorAlexey Kardashevskiy <aik@ozlabs.ru>
Thu, 18 Jul 2013 19:32:59 +0000 (18 14:32 -0500)
committerAnthony Liguori <aliguori@us.ibm.com>
Mon, 29 Jul 2013 15:37:08 +0000 (29 10:37 -0500)
tree029df6f90eaa71ba5e2a8895917ae970462c2b93
parenta83000f5e3fac30a7f213af1ba6a8f827622854d
pseries: rework PAPR virtual SCSI

The patch reimplements handling of indirect requests in order to
simplify upcoming live migration support.
- all pointers (except SCSIRequest*) were replaces with integer
indexes and offsets;
- DMA'ed srp_direct_buf kept untouched (ie. BE format);
- vscsi_fetch_desc() is added, now it is the only place where
descriptors are fetched and byteswapped;
- vscsi_req struct fields converted to migration-friendly types;
- many dprintf()'s fixed.

This also removed an unused field 'lun' from the spapr_vscsi device
which is assigned, but never used.  So, remove it.

[David Gibson: removed unused 'lun']
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Message-id: 1374175984-8930-7-git-send-email-aliguori@us.ibm.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw/scsi/spapr_vscsi.c