OSDN Git Service

scsi: Rename scsi_*_length() to scsi_*_xfer(), add scsi_cdb_length()
authorHannes Reinecke <hare@suse.de>
Wed, 29 Oct 2014 12:00:04 +0000 (13:00 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 31 Oct 2014 10:28:59 +0000 (11:28 +0100)
commit1894df02811f6b79ea3ffbf1084599d96f316173
treea1a5a4c5101cff0f2003ed37aff630e39b3272b8
parent98001e7b085b19b2b03ca5fdf44d063c204cc325
scsi: Rename scsi_*_length() to scsi_*_xfer(), add scsi_cdb_length()

scsi_cdb_length() does not return the length of the cdb, but
the transfersize encoded in the cdb. So rename it to scsi_cdb_xfer()
and also rename all other related functions to end with _xfer.

We can then add a new scsi_cdb_length() which actually does return the
length of the cdb.  With that DEBUG_SCSI can now display the correct
CDB buffer.

Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
hw/scsi/scsi-bus.c
hw/scsi/scsi-disk.c
include/hw/scsi/scsi.h