• Hannes Reinecke's avatar
    virtio_blk: SG_IO passthru support · 1cde26f9
    Hannes Reinecke authored
    Add support for SG_IO passthru to virtio_blk.  We add the scsi command
    block after the normal outhdr, and the scsi inhdr with full status
    information aswell as the sense buffer before the regular inhdr.
    
    [hch: forward ported, added the VIRTIO_BLK_F_SCSI flags, some comments
     and tested the whole beast]
    [axboe: updated to use ->resid and not dual-path the byte count]
    Signed-off-by: default avatarHannes Reinecke <hare@suse.de>
    Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
    Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (+ checkpatch.pl tweak)
    Signed-off-by: default avatarJens Axboe <jens.axboe@oracle.com>
    1cde26f9
virtio_blk.c 10.4 KB