diff options
author | Hannes Reinecke <hare@suse.de> | 2013-03-04 14:08:06 +0100 |
---|---|---|
committer | Nicholas Bellinger <nab@linux-iscsi.org> | 2013-03-18 12:31:16 -0700 |
commit | 882e3f8e6966109ad837cfe79e97cf3deb3ae19b (patch) | |
tree | 9444371cf1d794d85b7611fe90fe7c8e8d4974cf | |
parent | a937536b868b8369b98967929045f1df54234323 (diff) | |
download | kernel_goldelico_gta04-882e3f8e6966109ad837cfe79e97cf3deb3ae19b.zip kernel_goldelico_gta04-882e3f8e6966109ad837cfe79e97cf3deb3ae19b.tar.gz kernel_goldelico_gta04-882e3f8e6966109ad837cfe79e97cf3deb3ae19b.tar.bz2 |
target_core_sbc: use noop for SYNCHRONIZE_CACHE
Windows does not expect SYNCHRONIZE_CACHE to be not supported,
and will generate a BSOD upon shutdown when using rd_mcp backend.
So better use a noop here.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
-rw-r--r-- | drivers/target/target_core_sbc.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/target/target_core_sbc.c b/drivers/target/target_core_sbc.c index 290230d..60d4b51 100644 --- a/drivers/target/target_core_sbc.c +++ b/drivers/target/target_core_sbc.c @@ -464,8 +464,11 @@ sbc_parse_cdb(struct se_cmd *cmd, struct sbc_ops *ops) break; case SYNCHRONIZE_CACHE: case SYNCHRONIZE_CACHE_16: - if (!ops->execute_sync_cache) - return TCM_UNSUPPORTED_SCSI_OPCODE; + if (!ops->execute_sync_cache) { + size = 0; + cmd->execute_cmd = sbc_emulate_noop; + break; + } /* * Extract LBA and range to be flushed for emulated SYNCHRONIZE_CACHE |