From: Nicholas Bellinger Date: Sat, 14 Feb 2015 02:05:31 +0000 (+0000) Subject: target: Set LBPWS10 bit in Logical Block Provisioning EVPD X-Git-Tag: firefly_0821_release~176^2~2250^2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=aa04dae454d087376d97f44710c4422df030a8f2;p=firefly-linux-kernel-4.4.55.git target: Set LBPWS10 bit in Logical Block Provisioning EVPD This patch sets the missing LBPWS10 bit within spc_emulate_evpd_b2() in order to signal WRITE_SAME (10) w/ UNMAP support, following the existing LBPWS bit to signal WRITE_SAME (16) w/ UNMAP support. Cc: Martin Petersen Cc: Christoph Hellwig Signed-off-by: Nicholas Bellinger --- diff --git a/drivers/target/target_core_spc.c b/drivers/target/target_core_spc.c index 1307600fe726..f041f936a6cd 100644 --- a/drivers/target/target_core_spc.c +++ b/drivers/target/target_core_spc.c @@ -650,7 +650,7 @@ spc_emulate_evpd_b2(struct se_cmd *cmd, unsigned char *buf) * support the use of the WRITE SAME (16) command to unmap LBAs. */ if (dev->dev_attrib.emulate_tpws != 0) - buf[5] |= 0x40; + buf[5] |= 0x40 | 0x20; return 0; }