summaryrefslogtreecommitdiffstats
path: root/drivers/target
diff options
context:
space:
mode:
authorNicholas Bellinger <nab@linux-iscsi.org>2012-11-06 20:59:41 -0800
committerNicholas Bellinger <nab@linux-iscsi.org>2012-11-07 20:12:10 -0800
commit1920ed61fbbbb38919edfb2427b0b1fd4e4ad8d9 (patch)
treea9eb198ed8f04e64679236802da719a6261d090d /drivers/target
parent314da1aa57c3f2be8a07f3d944a541b595e8cb7d (diff)
downloadlinux-stable-1920ed61fbbbb38919edfb2427b0b1fd4e4ad8d9.tar.gz
linux-stable-1920ed61fbbbb38919edfb2427b0b1fd4e4ad8d9.tar.bz2
linux-stable-1920ed61fbbbb38919edfb2427b0b1fd4e4ad8d9.zip
target: Change sbc_emulate_noop to return sense_reason_t
As reported by Fengguang Wu + 0 day build team, the sense_reason_t conversion in for-next did not catch the recent sbc_emulate_noop() addition in mainline, producing the following build warning in auto-next: drivers/target/target_core_sbc.c: In function ‘sbc_parse_cdb’: drivers/target/target_core_sbc.c:555: warning: assignment from incompatible pointer type Go ahead and remove duplicate sbc_emulate_verify(), and change VERIFY to use sbc_emulate_noop() as well. Reported-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/target')
-rw-r--r--drivers/target/target_core_sbc.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/target/target_core_sbc.c b/drivers/target/target_core_sbc.c
index 3929fa201088..b8024219cd4f 100644
--- a/drivers/target/target_core_sbc.c
+++ b/drivers/target/target_core_sbc.c
@@ -134,13 +134,7 @@ int spc_get_write_same_sectors(struct se_cmd *cmd)
EXPORT_SYMBOL(spc_get_write_same_sectors);
static sense_reason_t
-sbc_emulate_verify(struct se_cmd *cmd)
-{
- target_complete_cmd(cmd, GOOD);
- return 0;
-}
-
-static int sbc_emulate_noop(struct se_cmd *cmd)
+sbc_emulate_noop(struct se_cmd *cmd)
{
target_complete_cmd(cmd, GOOD);
return 0;
@@ -540,7 +534,7 @@ sbc_parse_cdb(struct se_cmd *cmd, struct sbc_ops *ops)
break;
case VERIFY:
size = 0;
- cmd->execute_cmd = sbc_emulate_verify;
+ cmd->execute_cmd = sbc_emulate_noop;
break;
case REZERO_UNIT:
case SEEK_6: