Skip to content

Commit

Permalink
target/sbc: Check that the LBA and number of blocks are correct in VE…
Browse files Browse the repository at this point in the history
…RIFY

This patch extracts LBA + sectors for VERIFY, and adds a goto check_lba
to perform the end-of-device checking.

(Update patch to drop lba_check usage - nab)

Signed-off-by: Christophe Vu-Brugier <cvubrugier@yahoo.fr>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
  • Loading branch information
Christophe Vu-Brugier authored and Nicholas Bellinger committed Jun 11, 2014
1 parent 6ef31dc commit c52716d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/target/target_core_sbc.c
Original file line number Diff line number Diff line change
Expand Up @@ -914,8 +914,10 @@ sbc_parse_cdb(struct se_cmd *cmd, struct sbc_ops *ops)
break;
case VERIFY:
size = 0;
sectors = transport_get_sectors_10(cdb);
cmd->t_task_lba = transport_lba_32(cdb);
cmd->execute_cmd = sbc_emulate_noop;
break;
goto check_lba;
case REZERO_UNIT:
case SEEK_6:
case SEEK_10:
Expand Down

0 comments on commit c52716d

Please sign in to comment.