diff options
author | Matt Jacob <mjacob@FreeBSD.org> | 1999-10-16 23:31:34 +0000 |
---|---|---|
committer | Matt Jacob <mjacob@FreeBSD.org> | 1999-10-16 23:31:34 +0000 |
commit | 0642b69a16bb31a2993d93ee39f7daeea3b50a01 (patch) | |
tree | 25c7042abb3441cd1bf7ea2b0ddf71d71867f920 /sys/cam/cam_xpt.c | |
parent | c98a6e4f7b73c299131e03f8c21d1c303ca265ce (diff) | |
download | src-0642b69a16bb31a2993d93ee39f7daeea3b50a01.tar.gz src-0642b69a16bb31a2993d93ee39f7daeea3b50a01.zip |
Protect xpt_run_dev_sendq in xpt_release_devq_device with splsoftcam. This
seems to handle the case of timeouts firing during probe but after a device
has gone away. It really does help.
Obtained from:gibbs@freebsd.org
Notes
Notes:
svn path=/head/; revision=52324
Diffstat (limited to 'sys/cam/cam_xpt.c')
-rw-r--r-- | sys/cam/cam_xpt.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/cam/cam_xpt.c b/sys/cam/cam_xpt.c index 03ba677aa176..466af408b2cd 100644 --- a/sys/cam/cam_xpt.c +++ b/sys/cam/cam_xpt.c @@ -4350,10 +4350,11 @@ static void xpt_release_devq_device(struct cam_ed *dev, u_int count, int run_queue) { int rundevq; - int s; + int s0, s1; rundevq = 0; - s = splcam(); + s0 = splsoftcam(); + s1 = splcam(); if (dev->qfrozen_cnt > 0) { count = (count > dev->qfrozen_cnt) ? dev->qfrozen_cnt : count; @@ -4388,9 +4389,10 @@ xpt_release_devq_device(struct cam_ed *dev, u_int count, int run_queue) } } } - splx(s); + splx(s1); if (rundevq != 0) xpt_run_dev_sendq(dev->target->bus); + splx(s0); } void |