Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/sys sys/sleepq.h: Get cold from sys/kernel.h.



details:   https://anonhg.NetBSD.org/src/rev/14ed901897ec
branches:  trunk
changeset: 372066:14ed901897ec
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Wed Oct 26 23:24:59 2022 +0000

description:
sys/sleepq.h: Get cold from sys/kernel.h.

diffstat:

 sys/sys/sleepq.h |  7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diffs (35 lines):

diff -r db5dd13681db -r 14ed901897ec sys/sys/sleepq.h
--- a/sys/sys/sleepq.h  Wed Oct 26 23:24:21 2022 +0000
+++ b/sys/sys/sleepq.h  Wed Oct 26 23:24:59 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sleepq.h,v 1.35 2022/06/29 22:27:01 riastradh Exp $    */
+/*     $NetBSD: sleepq.h,v 1.36 2022/10/26 23:24:59 riastradh Exp $    */
 
 /*-
  * Copyright (c) 2002, 2006, 2007, 2008, 2009, 2019, 2020
@@ -63,6 +63,9 @@
 int    sleepq_block(int, bool, struct syncobj *);
 
 #ifdef _KERNEL
+
+#include <sys/kernel.h>
+
 typedef union {
        kmutex_t        lock;
        uint8_t         pad[COHERENCY_UNIT];
@@ -76,7 +79,6 @@
 static __inline bool
 sleepq_dontsleep(lwp_t *l)
 {
-       extern int cold;
 
        return cold || (doing_shutdown && (panicstr || CURCPU_IDLE_P()));
 }
@@ -97,6 +99,7 @@
        lwp_unlock_to(l, mp);
        KERNEL_UNLOCK_ALL(NULL, &l->l_biglocks);
 }
+
 #endif
 
 #include <sys/sleeptab.h>



Home | Main Index | Thread Index | Old Index