Skip to content

tcm/tcm_loop: Add BIDI support and XDWRITE_READ_10 emulation

Nicholas A. Bellinger linux-scsi lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 4 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2tcm: Add support for BIDI operation and XDWRITE_READ_10 emulationdrivers/target/target_core_transport.c include/target/target_core_base.h include/target/target_core_transport.h+261 -402 replies
2/2tcm_loop: Add DMA_BIDIRECTIONAL CDB supportdrivers/target/tcm_loop/tcm_loop_fabric_scsi.c+36 -122 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] tcm/tcm_loop: Add BIDI support and XDWRITE_READ_10 emulation

From: Nicholas Bellinger <[email protected]>

Greetings Boaz, Tomo-san and Co,

This series adds initial support for functional bidirectional CDBs into TCM_Core and the TCM_Loop fabric module. So far this is limited to XDWRITE_READ_10 emulation following scsi_debug.c, but everything appears to now be functioning as expected.

This first patch adds support for BIDI operations and XDWRITE_READ_10 emulation into TCM_Core for the individual I/O descriptor setup, memory mapping, callback and release codepaths.

The second patch enables BIDI operations with the TCM_Loop Virtual SCSI LLD fabric module using the updated callers.

So far this has been lightly tested on v2.6.36-rc3 HVM using custom userspace BSG code to issue XDWRITE_READ_10 I/O into TCM_Loop LUNs using FILEIO backstores. Support for BIDI CDBs will also extend to LIO-Target and other TCM fabric modules in the near future.

Comments are welcome!

Nicholas Bellinger (2):
tcm: Add support for BIDI operation and XDWRITE_READ_10 emulation
tcm_loop: Add DMA_BIDIRECTIONAL CDB support

 drivers/target/target_core_transport.c         |  282 +++++++++++++++++++++---
 drivers/target/tcm_loop/tcm_loop_fabric_scsi.c |   48 +++-
 include/target/target_core_base.h              |    9 +-
 include/target/target_core_transport.h         |   10 +-
 4 files changed, 297 insertions(+), 52 deletions(-)