summaryrefslogtreecommitdiffstats
path: root/sys/dev/isp/isp_freebsd.c
diff options
context:
space:
mode:
authormjacob <mjacob@FreeBSD.org>2010-03-26 15:13:31 +0000
committermjacob <mjacob@FreeBSD.org>2010-03-26 15:13:31 +0000
commit8e6a6c380c1336a18e76be1d009aed8c83774fd1 (patch)
tree62486c3713e125e6e81bed2c7daf1a095db545ba /sys/dev/isp/isp_freebsd.c
parentd82aae616f1807273da2d6c2f38d74a63752642e (diff)
downloadFreeBSD-src-8e6a6c380c1336a18e76be1d009aed8c83774fd1.zip
FreeBSD-src-8e6a6c380c1336a18e76be1d009aed8c83774fd1.tar.gz
Clean up some printing stuff so that we can have a bit finer control
on debug output. Add a new platform function requirement to allow for printing based upon the ITL nexus instead of the isp unit plus channel, target and lun. This allows some printouts and error messages from the core code to appear in the same format as the platform's subsystem (in FreeBSD's case, CAM path). MFC after: 1 week
Diffstat (limited to 'sys/dev/isp/isp_freebsd.c')
-rw-r--r--sys/dev/isp/isp_freebsd.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/sys/dev/isp/isp_freebsd.c b/sys/dev/isp/isp_freebsd.c
index ca459f3..5f64bcd 100644
--- a/sys/dev/isp/isp_freebsd.c
+++ b/sys/dev/isp/isp_freebsd.c
@@ -5432,6 +5432,20 @@ isp_prt(ispsoftc_t *isp, int level, const char *fmt, ...)
printf("\n");
}
+void
+isp_xs_prt(ispsoftc_t *isp, XS_T *xs, int level, const char *fmt, ...)
+{
+ va_list ap;
+ if (level != ISP_LOGALL && (level & isp->isp_dblev) == 0) {
+ return;
+ }
+ xpt_print_path(xs->ccb_h.path);
+ va_start(ap, fmt);
+ vprintf(fmt, ap);
+ va_end(ap);
+ printf("\n");
+}
+
uint64_t
isp_nanotime_sub(struct timespec *b, struct timespec *a)
{
OpenPOWER on IntegriCloud