From 09b77a6eebe5174ac8b0d2de1ac825f1c0efcc30 Mon Sep 17 00:00:00 2001 From: Stanislaw Gruszka Date: Fri, 4 Apr 2008 11:17:49 +0000 Subject: [PATCH] Do not dump stack when data length is bigger than low level driver can handle. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@323 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- qla_isp/linux/isp_scst.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qla_isp/linux/isp_scst.c b/qla_isp/linux/isp_scst.c index a0f6c18d7..c3f69c973 100644 --- a/qla_isp/linux/isp_scst.c +++ b/qla_isp/linux/isp_scst.c @@ -997,11 +997,11 @@ isp_xmit_response(struct scst_cmd *scst_cmd) if (scst_cmd_get_data_direction(scst_cmd) == SCST_DATA_READ) { unsigned int len = scst_cmd_get_resp_data_len(scst_cmd); if (len > tmd->cd_totlen) { - /* this shouldn't happen */ + /* some broken initiators may send SCSI commands with data load + * larger than underlaying transport specified */ const uint8_t ifailure[TMD_SENSELEN] = { 0xf0, 0, 0x4, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0x44 }; Eprintk("data size too big (totlen %u len %u)\n", tmd->cd_totlen, len); - dump_stack(); memcpy(tmd->cd_sense, ifailure, TMD_SENSELEN); xact->td_hflags |= TDFH_STSVALID;