summaryrefslogtreecommitdiffstats
path: root/sys/cam/cam_periph.h
diff options
context:
space:
mode:
authorgibbs <gibbs@FreeBSD.org>1999-05-22 21:58:47 +0000
committergibbs <gibbs@FreeBSD.org>1999-05-22 21:58:47 +0000
commit95dc85b099eb4f732b322f090ce0abad1280fbfd (patch)
tree84ee71641db91cb247029bd5aa2d5bffd89b16dd /sys/cam/cam_periph.h
parente4dc7e4c0e6535e2f3849d8c0335cbd9e6f86379 (diff)
downloadFreeBSD-src-95dc85b099eb4f732b322f090ce0abad1280fbfd.zip
FreeBSD-src-95dc85b099eb4f732b322f090ce0abad1280fbfd.tar.gz
Add the XPT_PATH_STATS and XPT_GDEV_STATS function codes. These ccb
types allow the reporting of error counts and other statistics. Currently we provide information on the last BDR or bus reset as well as active transaction inforamtion, but this will be expanded as more information is added to aid in error recovery. Use the 'last reset' information to better handle bus settle delays. Peripheral drivers now control whether a bus settle delay occurs and for how long. This allows target mode peripheral drivers to avoid having their device queue frozen by the XPT for what shoudl only be initiator type behavior. Don't perform a bus reset if the target device is incapable of performing transfer negotiation (e.g. Fiber Channel). If we don't perform a bus reset but the controller is capable of transfer negotiations, force negotiations on the first transaction to go to the device. This ensures that we aren't tripped up by a left over negotiation from the prom, BIOS, loader, etc. Add a default async handler funstion to cam_periph.c to remove duplicated code in all initiator type peripheral drivers. Allow mapping of XPT_CONT_TARGET_IO ccbs from userland. They are itentical to XPT_SCSI_IO ccbs as far as data mapping is concerned.
Diffstat (limited to 'sys/cam/cam_periph.h')
-rw-r--r--sys/cam/cam_periph.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/cam/cam_periph.h b/sys/cam/cam_periph.h
index 9bad491..2efee41 100644
--- a/sys/cam/cam_periph.h
+++ b/sys/cam/cam_periph.h
@@ -25,7 +25,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: cam_periph.h,v 1.2 1998/10/13 21:41:32 ken Exp $
+ * $Id: cam_periph.h,v 1.3 1998/10/22 22:16:48 ken Exp $
*/
#ifndef _CAM_CAM_PERIPH_H
@@ -130,9 +130,17 @@ int cam_periph_ioctl(struct cam_periph *periph, int cmd,
int (*error_routine)(union ccb *ccb,
cam_flags camflags,
u_int32_t sense_flags));
+void cam_freeze_devq(struct cam_path *path);
u_int32_t cam_release_devq(struct cam_path *path, u_int32_t relsim_flags,
u_int32_t opening_reduction, u_int32_t timeout,
int getcount_only);
+void cam_periph_async(struct cam_periph *periph, u_int32_t code,
+ struct cam_path *path, void *arg);
+void cam_periph_bus_settle(struct cam_periph *periph,
+ u_int bus_settle_ms);
+void cam_periph_freeze_after_event(struct cam_periph *periph,
+ struct timeval* event_time,
+ u_int duration_ms);
int cam_periph_error(union ccb *ccb, cam_flags camflags,
u_int32_t sense_flags, union ccb *save_ccb);
OpenPOWER on IntegriCloud