mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2025-01-23 20:50:32 +07:00
target: Fix sense data for out-of-bounds IO operations
We're supposed to return LOGICAL BLOCK ADDRESS OUT OF RANGE, not INVALID FIELD IN CDB. Signed-off-by: Roland Dreier <roland@purestorage.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
This commit is contained in:
parent
bbf344e54e
commit
33633676df
@ -486,7 +486,7 @@ sbc_parse_cdb(struct se_cmd *cmd, struct sbc_ops *ops)
|
||||
*/
|
||||
if (cmd->t_task_lba || sectors) {
|
||||
if (sbc_check_valid_sectors(cmd) < 0)
|
||||
return TCM_INVALID_CDB_FIELD;
|
||||
return TCM_ADDRESS_OUT_OF_RANGE;
|
||||
}
|
||||
cmd->execute_cmd = ops->execute_sync_cache;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user