summaryrefslogtreecommitdiffstats
path: root/sys/dev/mps/mps.c
diff options
context:
space:
mode:
authorscottl <scottl@FreeBSD.org>2013-08-09 01:09:02 +0000
committerscottl <scottl@FreeBSD.org>2013-08-09 01:09:02 +0000
commitd1c9a480cbae281f1f04c590e3a63b8fa0cfb03b (patch)
treeac7cfbf26f838c299a9cfa43cf4d82c7be05d44e /sys/dev/mps/mps.c
parent40b11a17462845928214986df55e541227bdeda1 (diff)
downloadFreeBSD-src-d1c9a480cbae281f1f04c590e3a63b8fa0cfb03b.zip
FreeBSD-src-d1c9a480cbae281f1f04c590e3a63b8fa0cfb03b.tar.gz
Sometimes a device misbehaves so badly that it disrupts the entire system.
Add a tunable that allows such a device to be excluded from the driver. The id parameter is the target id that the driver assigns to a given device. dev.mps.X.exclude_ids=<id>,<id> Obtained from: Netflix MFC after: 3 days
Diffstat (limited to 'sys/dev/mps/mps.c')
-rw-r--r--sys/dev/mps/mps.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/dev/mps/mps.c b/sys/dev/mps/mps.c
index b6c549a..5a6718f 100644
--- a/sys/dev/mps/mps.c
+++ b/sys/dev/mps/mps.c
@@ -1371,6 +1371,11 @@ mps_get_tunables(struct mps_softc *sc)
snprintf(tmpstr, sizeof(tmpstr), "dev.mps.%d.max_chains",
device_get_unit(sc->mps_dev));
TUNABLE_INT_FETCH(tmpstr, &sc->max_chains);
+
+ bzero(sc->exclude_ids, sizeof(sc->exclude_ids));
+ snprintf(tmpstr, sizeof(tmpstr), "dev.mps.%d.exclude_ids",
+ device_get_unit(sc->mps_dev));
+ TUNABLE_STR_FETCH(tmpstr, sc->exclude_ids, sizeof(sc->exclude_ids));
}
static void
OpenPOWER on IntegriCloud