projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
915270c
)
target: check DPO/FUA usage for COMPARE AND WRITE
author
David Disseldorp
<ddiss@suse.de>
Thu, 23 Jul 2015 20:33:21 +0000
(22:33 +0200)
committer
Nicholas Bellinger
<nab@linux-iscsi.org>
Fri, 31 Jul 2015 07:22:23 +0000
(
00:22
-0700)
COMPARE AND WRITE requests should fail if DPO or FUA is set, but the
device is not advertising support.
Signed-off-by: David Disseldorp <ddiss@suse.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/target_core_sbc.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/target/target_core_sbc.c
b/drivers/target/target_core_sbc.c
index 4fc8343786f2b94302f9530f5f1514208e9d0fc7..0b4b2a67d9f9ed597479f1f2c0ea356126f55006 100644
(file)
--- a/
drivers/target/target_core_sbc.c
+++ b/
drivers/target/target_core_sbc.c
@@
-992,6
+992,9
@@
sbc_parse_cdb(struct se_cmd *cmd, struct sbc_ops *ops)
" than 1\n", sectors);
return TCM_INVALID_CDB_FIELD;
}
+ if (sbc_check_dpofua(dev, cmd, cdb))
+ return TCM_INVALID_CDB_FIELD;
+
/*
* Double size because we have two buffers, note that
* zero is not an error..