Skip to contentSkip to conversation

scsi: ufs: Enable quirk to ignore sending WRITE_SAME command

PATCH Applied Asutosh Das 2 participants 2 messages Jan 24, 2018 – Jan 31, 2018 SCSI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scsi: ufs: Enable quirk to ignore sending WRITE_SAME command

From: Sujit Reddy Thumma <[email protected]>

WRITE_SAME command is not supported by UFS. Enable a quirk for the upper level drivers to not send WRITE SAME command.

---
 drivers/scsi/ufs/ufshcd.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/scsi/ufs/ufshcd.c +3 -0
index 8af2af3..5a8dc3b 100644
@@ -4356,6 +4356,9 @@ static int ufshcd_slave_alloc(struct scsi_device *sdev)
 	/* WRITE_SAME command is not supported*/
 	sdev->no_write_same = 1;
 
+	/* WRITE_SAME command is not supported*/
+	sdev->no_write_same = 1;
+
 	ufshcd_set_queue_depth(sdev);
 
 	ufshcd_get_lu_power_on_wp_status(hba, sdev);
Signature · 2 lines
Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center, Inc. 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project.
#1 lore raw

Asutosh,

drivers/scsi/ufs/ufshcd.c static int ufshcd_slave_alloc(struct scsi_device *sdev) · line 4361

Quoted 6 lines
drivers/scsi/ufs/ufshcd.c +3 -0
 	/* WRITE_SAME command is not supported*/
 	sdev->no_write_same = 1;
 
+	/* WRITE_SAME command is not supported*/
+	sdev->no_write_same = 1;
+

Uhm...

I applied this change to 4.16/scsi-fixes by hand.

Signature · 1 line
Martin K. Petersen	Oracle Linux Engineering