]> Pileus Git - ~andy/linux/commit
target: add a parse_cdb method to the backend drivers
authorChristoph Hellwig <hch@infradead.org>
Sun, 20 May 2012 15:59:14 +0000 (11:59 -0400)
committerNicholas Bellinger <nab@linux-iscsi.org>
Tue, 17 Jul 2012 00:25:56 +0000 (17:25 -0700)
commitd6e0175cf3f9737a760482d185bb73566bcc9331
tree99ca8361ebc8c4e83f8335193963faa3f30007b5
parent88455ec4be02c395820b1ff57656b0844ec03ac3
target: add a parse_cdb method to the backend drivers

Instead of trying to handle all SCSI command sets in one function
(transport_generic_cmd_sequencer) call out to the backend driver to perform
this functionality.  For pSCSI a copy of the existing code is used, but for
all virtual backends we can use a new parse_sbc_cdb helper is used to
provide a simple SBC emulation.

For now this setups means a fair amount of duplication between pSCSI and the
SBC library, but patches later in this series will sort out that problem.

(nab: Fix up build failure in target_core_pscsi.c)

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/Makefile
drivers/target/target_core_file.c
drivers/target/target_core_iblock.c
drivers/target/target_core_internal.h
drivers/target/target_core_pscsi.c
drivers/target/target_core_rd.c
drivers/target/target_core_sbc.c [new file with mode: 0644]
drivers/target/target_core_spc.c
drivers/target/target_core_transport.c
include/target/target_core_backend.h