aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/isp
diff options
context:
space:
mode:
authorAlexander Motin <mav@FreeBSD.org>2017-02-26 14:29:09 +0000
committerAlexander Motin <mav@FreeBSD.org>2017-02-26 14:29:09 +0000
commit2d4a5bcccb8c188be88465a659278344ed36c49d (patch)
tree00e2295b192fc13b09ceb19baeb60fbdb0a49970 /sys/dev/isp
parent645b154260f89e2a40b16981bfa49eb45fa42ee6 (diff)
Notes
Diffstat (limited to 'sys/dev/isp')
-rw-r--r--sys/dev/isp/isp.c9
-rw-r--r--sys/dev/isp/isp_freebsd.h1
2 files changed, 6 insertions, 4 deletions
diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c
index ee11ddc4b896..af2c600cf948 100644
--- a/sys/dev/isp/isp.c
+++ b/sys/dev/isp/isp.c
@@ -4317,7 +4317,7 @@ isp_start(XS_T *xs)
if (XS_CDBLEN(xs) > (IS_FC(isp)? 16 : 44) || XS_CDBLEN(xs) == 0) {
isp_prt(isp, ISP_LOGERR, "unsupported cdb length (%d, CDB[0]=0x%x)", XS_CDBLEN(xs), XS_CDBP(xs)[0] & 0xff);
- XS_SETERR(xs, HBA_BOTCH);
+ XS_SETERR(xs, HBA_REQINVAL);
return (CMD_COMPLETE);
}
@@ -4494,7 +4494,7 @@ isp_start(XS_T *xs)
if (IS_SCSI(isp)) {
if (cdblen > sizeof (reqp->req_cdb)) {
isp_prt(isp, ISP_LOGERR, "Command Length %u too long for this chip", cdblen);
- XS_SETERR(xs, HBA_BOTCH);
+ XS_SETERR(xs, HBA_REQINVAL);
return (CMD_COMPLETE);
}
reqp->req_target = target | (XS_CHANNEL(xs) << 7);
@@ -4506,7 +4506,7 @@ isp_start(XS_T *xs)
if (cdblen > sizeof (t7->req_cdb)) {
isp_prt(isp, ISP_LOGERR, "Command Length %u too long for this chip", cdblen);
- XS_SETERR(xs, HBA_BOTCH);
+ XS_SETERR(xs, HBA_REQINVAL);
return (CMD_COMPLETE);
}
@@ -4539,7 +4539,7 @@ isp_start(XS_T *xs)
if (cdblen > sizeof t2->req_cdb) {
isp_prt(isp, ISP_LOGERR, "Command Length %u too long for this chip", cdblen);
- XS_SETERR(xs, HBA_BOTCH);
+ XS_SETERR(xs, HBA_REQINVAL);
return (CMD_COMPLETE);
}
if (FCPARAM(isp, XS_CHANNEL(xs))->fctape_enabled && (lp->prli_word3 & PRLI_WD3_RETRY)) {
@@ -6567,6 +6567,7 @@ isp_parse_status(ispsoftc_t *isp, ispstatusreq_t *sp, XS_T *xs, long *rp)
case RQCS_PORT_BUSY:
isp_prt(isp, ISP_LOGWARN, "port busy for target %d", XS_TGT(xs));
if (XS_NOERR(xs)) {
+ *XS_STSP(xs) = SCSI_BUSY;
XS_SETERR(xs, HBA_TGTBSY);
}
return;
diff --git a/sys/dev/isp/isp_freebsd.h b/sys/dev/isp/isp_freebsd.h
index e50ee16d1030..8bd16a86b4d2 100644
--- a/sys/dev/isp/isp_freebsd.h
+++ b/sys/dev/isp/isp_freebsd.h
@@ -574,6 +574,7 @@ default: \
# define HBA_CMDTIMEOUT CAM_CMD_TIMEOUT
# define HBA_SELTIMEOUT CAM_SEL_TIMEOUT
# define HBA_TGTBSY CAM_SCSI_STATUS_ERROR
+# define HBA_REQINVAL CAM_REQ_INVALID
# define HBA_BUSRESET CAM_SCSI_BUS_RESET
# define HBA_ABORTED CAM_REQ_ABORTED
# define HBA_DATAOVR CAM_DATA_RUN_ERR