Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 312698
b: refs/heads/master
c: 7409a66
h: refs/heads/master
v: v3
  • Loading branch information
Roland Dreier authored and Nicholas Bellinger committed Jul 17, 2012
1 parent 72e2c27 commit c021e4f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b7fc7f3777582dea85156a821d78a522a0c083aa
refs/heads/master: 7409a6657aebf8be74c21d0eded80709b27275cb
5 changes: 5 additions & 0 deletions trunk/drivers/target/target_core_iblock.c
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,11 @@ static int iblock_execute_unmap(struct se_cmd *cmd)
bd_dl = get_unaligned_be16(&buf[2]);

size = min(size - 8, bd_dl);
if (size / 16 > dev->se_sub_dev->se_dev_attrib.max_unmap_block_desc_count) {
cmd->scsi_sense_reason = TCM_INVALID_PARAMETER_LIST;
ret = -EINVAL;
goto err;
}

/* First UNMAP block descriptor starts at 8 byte offset */
ptr = &buf[8];
Expand Down

0 comments on commit c021e4f

Please sign in to comment.