[PATCH 0/2] tcm/iblock: SCSI LBA -> block_lba conversion for non 512-byte block_size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Nicholas Bellinger <nab@xxxxxxxxxxxxxxx>

Greetings hch, Jens and Co,

This patch adds support for TCM/IBLOCK backstores doing proper non 512-byte native TCM
struct se_task SCSI LBA conversion into 512-byte units in iblock_map_task_SG() for the
starting and subsequent struct bio->bi_sector going into bio_add_page().  The second patch
converts the same function to use for_each_sg() to follow mainline SGL walking conventions.

So far I have been testing these two with TCM_Loop virtual SCSI on top and scsi_debug
below with non 512-byte sector_sized struct scsi_devices, which now appears to be
functioning as expected.  I will need to test this with more combinations of scsi_debug
max_sectors (and will need a patch to make that a module parameter too.. ;) to ensure
N struct se_task mapping in transport_do_se_mem_map() -> transport_map_mem_to_sg() is
functioning as expected for these > 512-byte block_size / sector_size cases.

Please have a look at let me know what you think, and please let me know if there is
anything else that should be considered for this one.

Thanks!

Signed-off-by: Nicholas A. Bellinger <nab@xxxxxxxxxxxxxxx>

Nicholas Bellinger (2):
  tcm/iblock: Add SCSI LBA -> block_lba conversion for non 512-byte
    block_size
  tcm/iblock: Convert iblock_map_task_SG() to use for_each_sg()

 drivers/target/target_core_iblock.c |   50 +++++++++++++++++++++++-----------
 1 files changed, 34 insertions(+), 16 deletions(-)

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux