From 6ee273fcd7d5fd22582d9e17e8f6c3a085bb31ca Mon Sep 17 00:00:00 2001 From: jhb Date: Fri, 5 Mar 2004 22:41:22 +0000 Subject: Lock Giant around the body of the adlink_loran() function used by the adlink device kthreads. --- sys/dev/adlink/adlink.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sys') diff --git a/sys/dev/adlink/adlink.c b/sys/dev/adlink/adlink.c index f8a7253..a66ccf5 100644 --- a/sys/dev/adlink/adlink.c +++ b/sys/dev/adlink/adlink.c @@ -221,6 +221,7 @@ adlink_loran(void *arg) sc = arg; idx = 0; + mtx_lock(&Giant); for (;;) { while (sc->stat[idx] == 0) msleep(sc, NULL, PRIBIO, "loran", 1); @@ -234,6 +235,7 @@ adlink_loran(void *arg) idx++; idx %= NRING; } + mtx_unlock(&Giant); kthread_exit(0); } -- cgit v1.1