From: Nicholas Bellinger Date: Tue, 1 Oct 2013 23:46:37 +0000 (-0700) Subject: target: Reset data_length for COMPARE_AND_WRITE to NoLB * block_size X-Git-Tag: v3.12-rc4~2^2~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b7191253b302a9b98758c3616761ae111b6264b9;p=pandora-kernel.git target: Reset data_length for COMPARE_AND_WRITE to NoLB * block_size This patch resets se_cmd->data_length for COMPARE_AND_WRITE emulation within sbc_compare_and_write() to NoLB * block_size in order to address a bug with FILEIO backends where a I/O failure will occur when data_length does not match the I/O size being actually dispatched for the individual per block READs + WRITEs. This is done late enough in sbc_compare_and_write() after the memory allocations have occured in transport_generic_new_cmd() to not cause any unwanted side-effects. Reported-by: Thomas Glanzmann Tested-by: Thomas Glanzmann Signed-off-by: Nicholas Bellinger --- Reading git-diff-tree failed