svn commit: r349011 - head/sys/dev/ciss
Warner Losh
imp at FreeBSD.org
Thu Jun 13 05:19:50 UTC 2019
Author: imp
Date: Thu Jun 13 05:19:42 2019
New Revision: 349011
URL: https://svnweb.freebsd.org/changeset/base/349011
Log:
Don't print the request we may be aborting in ciss_notify_abort as
part of ciss_detach. It's a left-over debug that isn't needed and also
discloses a kernel address. Only root could provoke as part of a
devctl or kldunload.
Submitted by: Fuqian Huang
MFC After: 1 week
Modified:
head/sys/dev/ciss/ciss.c
Modified: head/sys/dev/ciss/ciss.c
==============================================================================
--- head/sys/dev/ciss/ciss.c Thu Jun 13 05:19:36 2019 (r349010)
+++ head/sys/dev/ciss/ciss.c Thu Jun 13 05:19:42 2019 (r349011)
@@ -107,6 +107,10 @@
#include <dev/ciss/cissio.h>
#include <dev/ciss/cissvar.h>
+#ifdef CISS_DEBUG
+#include "opt_ddb.h"
+#endif
+
static MALLOC_DEFINE(CISS_MALLOC_CLASS, "ciss_data",
"ciss internal data buffers");
@@ -197,7 +201,9 @@ static void ciss_notify_logical(struct ciss_softc *sc,
static void ciss_notify_physical(struct ciss_softc *sc, struct ciss_notify *cn);
/* debugging output */
+#ifdef DDB
static void ciss_print_request(struct ciss_request *cr);
+#endif
static void ciss_print_ldrive(struct ciss_softc *sc, struct ciss_ldrive *ld);
static const char *ciss_name_ldrive_status(int status);
static int ciss_decode_ldrive_status(int status);
@@ -3811,8 +3817,9 @@ ciss_notify_abort(struct ciss_softc *sc)
cnc->opcode = CISS_OPCODE_WRITE;
cnc->command = CISS_COMMAND_ABORT_NOTIFY;
cnc->length = htonl(CISS_NOTIFY_DATA_SIZE);
-
+#if 0
ciss_print_request(cr);
+#endif
/*
* Submit the request and wait for it to complete.
@@ -4237,6 +4244,7 @@ ciss_kill_notify_thread(struct ciss_softc *sc)
/************************************************************************
* Print a request.
*/
+#ifdef DDB
static void
ciss_print_request(struct ciss_request *cr)
{
@@ -4290,6 +4298,7 @@ ciss_print_request(struct ciss_request *cr)
}
}
}
+#endif
/************************************************************************
* Print information about the status of a logical drive.
@@ -4353,8 +4362,6 @@ ciss_print_ldrive(struct ciss_softc *sc, struct ciss_l
}
}
-#ifdef CISS_DEBUG
-#include "opt_ddb.h"
#ifdef DDB
#include <ddb/ddb.h>
/************************************************************************
@@ -4408,7 +4415,6 @@ DB_COMMAND(ciss_prt, db_ciss_prt)
ciss_print_adapter(sc);
}
}
-#endif
#endif
/************************************************************************
More information about the svn-src-head
mailing list