[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <443175c77873b6b86d01b8df8fc5d5aeba6748f0.1658192351.git.Thinh.Nguyen@synopsys.com>
Date: Mon, 18 Jul 2022 18:27:32 -0700
From: Thinh Nguyen <Thinh.Nguyen@...opsys.com>
To: Felipe Balbi <balbi@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Thinh Nguyen <Thinh.Nguyen@...opsys.com>,
linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org,
Dmitry Bogdanov <d.bogdanov@...ro.com>,
Nicholas Bellinger <nab@...ux-iscsi.org>,
Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Cc: linux-scsi@...r.kernel.org, target-devel@...r.kernel.org,
Alan Stern <stern@...land.harvard.edu>,
Christoph Hellwig <hch@....de>
Subject: [PATCH v2 14/25] usb: gadget: f_tcm: Translate error to sense
When respond with check_condition error status, clear from_transport
input so the target layer can translate the sense reason reported by
f_tcm.
Fixes: c52661d60f63 ("usb-gadget: Initial merge of target module for UASP + BOT")
Signed-off-by: Thinh Nguyen <Thinh.Nguyen@...opsys.com>
---
Changes in v2:
- None
drivers/usb/gadget/function/f_tcm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/gadget/function/f_tcm.c b/drivers/usb/gadget/function/f_tcm.c
index cace5746c0f9..28b560ab44fd 100644
--- a/drivers/usb/gadget/function/f_tcm.c
+++ b/drivers/usb/gadget/function/f_tcm.c
@@ -1044,7 +1044,7 @@ static void usbg_cmd_work(struct work_struct *work)
out:
transport_send_check_condition_and_sense(se_cmd,
- TCM_UNSUPPORTED_SCSI_OPCODE, 1);
+ TCM_UNSUPPORTED_SCSI_OPCODE, 0);
}
static struct usbg_cmd *usbg_get_cmd(struct f_uas *fu,
@@ -1160,7 +1160,7 @@ static void bot_cmd_work(struct work_struct *work)
out:
transport_send_check_condition_and_sense(se_cmd,
- TCM_UNSUPPORTED_SCSI_OPCODE, 1);
+ TCM_UNSUPPORTED_SCSI_OPCODE, 0);
transport_generic_free_cmd(&cmd->se_cmd, 0);
}
--
2.28.0
Powered by blists - more mailing lists