summaryrefslogtreecommitdiffstats
path: root/sys/dev/isp
diff options
context:
space:
mode:
authorken <ken@FreeBSD.org>2013-08-15 16:41:27 +0000
committerken <ken@FreeBSD.org>2013-08-15 16:41:27 +0000
commitc6e2041529c9c69f395d4780ca05dbd3a9d186e5 (patch)
tree25fde034484e9df6eea5a62f451885819ab6f1ac /sys/dev/isp
parentb45bc75e19b0d23a9d666a6755c6d5e7c85934bd (diff)
downloadFreeBSD-src-c6e2041529c9c69f395d4780ca05dbd3a9d186e5.zip
FreeBSD-src-c6e2041529c9c69f395d4780ca05dbd3a9d186e5.tar.gz
Export the maxio field in the CAM XPT_PATH_INQ CCB in the isp(4)
driver. This tells consumers up the stack the maximum I/O size that the controller can handle. The I/O size is bounded by the number of scatter/gather segments the controller can handle and the page size. For an amd64 system, it works out to around 5MB. Reviewed by: mjacob MFC after: 3 days Sponsored by: Spectra Logic
Diffstat (limited to 'sys/dev/isp')
-rw-r--r--sys/dev/isp/isp_freebsd.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/dev/isp/isp_freebsd.c b/sys/dev/isp/isp_freebsd.c
index 167d39d..2d0d64d 100644
--- a/sys/dev/isp/isp_freebsd.c
+++ b/sys/dev/isp/isp_freebsd.c
@@ -5445,6 +5445,11 @@ isp_action(struct cam_sim *sim, union ccb *ccb)
cpi->max_target = ISP_MAX_TARGETS(isp) - 1;
cpi->max_lun = ISP_MAX_LUNS(isp) - 1;
cpi->bus_id = cam_sim_bus(sim);
+ if (isp->isp_osinfo.sixtyfourbit)
+ cpi->maxio = (ISP_NSEG64_MAX - 1) * PAGE_SIZE;
+ else
+ cpi->maxio = (ISP_NSEG_MAX - 1) * PAGE_SIZE;
+
bus = cam_sim_bus(xpt_path_sim(cpi->ccb_h.path));
if (IS_FC(isp)) {
fcparam *fcp = FCPARAM(isp, bus);
OpenPOWER on IntegriCloud