aboutsummaryrefslogtreecommitdiff
path: root/sys/cam/cam_xpt.c
diff options
context:
space:
mode:
authorScott Long <scottl@FreeBSD.org>2000-10-30 23:30:28 +0000
committerScott Long <scottl@FreeBSD.org>2000-10-30 23:30:28 +0000
commit8c7a96c55bd0b2b4a7c7ac881257e9877a9692f4 (patch)
treecdc4fa03bde397a7ab52ce78e2b293d1d0774e11 /sys/cam/cam_xpt.c
parentaac62dffff425883fc2222161edaf0c19ea768bc (diff)
downloadsrc-8c7a96c55bd0b2b4a7c7ac881257e9877a9692f4.tar.gz
src-8c7a96c55bd0b2b4a7c7ac881257e9877a9692f4.zip
Allow XPT_PATH_INQ to be performed on the XPT device, as per the CAM spec.
Return ENOTSUP for XPT_ENG_INQ and XPT_ENG_EXEC when performed on the XPT device. Reviewed by: gibbs
Notes
Notes: svn path=/head/; revision=68009
Diffstat (limited to 'sys/cam/cam_xpt.c')
-rw-r--r--sys/cam/cam_xpt.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/cam/cam_xpt.c b/sys/cam/cam_xpt.c
index 018ee5a19447..ad65b71961d2 100644
--- a/sys/cam/cam_xpt.c
+++ b/sys/cam/cam_xpt.c
@@ -956,7 +956,8 @@ xptioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, struct proc *p)
/*
* For the transport layer CAMIOCOMMAND ioctl, we really only want
* to accept CCB types that don't quite make sense to send through a
- * passthrough driver.
+ * passthrough driver. XPT_PATH_INQ is an exception to this, as stated
+ * in the CAM spec.
*/
case CAMIOCOMMAND: {
union ccb *ccb;
@@ -973,6 +974,7 @@ xptioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, struct proc *p)
break;
}
/* FALLTHROUGH */
+ case XPT_PATH_INQ:
case XPT_SCAN_LUN:
ccb = xpt_alloc_ccb();
@@ -1087,6 +1089,10 @@ xptioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, struct proc *p)
error = 0;
break;
}
+ case XPT_ENG_INQ:
+ case XPT_ENG_EXEC:
+ error = ENOTSUP;
+ break;
default:
error = EINVAL;
break;