Sun Nov 1 20:56:13 2020 UTC ()
turned sleepq_destroy this into a macro


(christos)
diff -r1.33 -r1.34 src/sys/sys/sleepq.h

cvs diff -r1.33 -r1.34 src/sys/sys/sleepq.h (expand / switch to unified diff)

--- src/sys/sys/sleepq.h 2020/11/01 20:55:15 1.33
+++ src/sys/sys/sleepq.h 2020/11/01 20:56:13 1.34
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: sleepq.h,v 1.33 2020/11/01 20:55:15 christos Exp $ */ 1/* $NetBSD: sleepq.h,v 1.34 2020/11/01 20:56:13 christos Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 2002, 2006, 2007, 2008, 2009, 2019, 2020 4 * Copyright (c) 2002, 2006, 2007, 2008, 2009, 2019, 2020
5 * The NetBSD Foundation, Inc. 5 * The NetBSD Foundation, Inc.
6 * All rights reserved. 6 * All rights reserved.
7 * 7 *
8 * This code is derived from software contributed to The NetBSD Foundation 8 * This code is derived from software contributed to The NetBSD Foundation
9 * by Jason R. Thorpe and Andrew Doran. 9 * by Jason R. Thorpe and Andrew Doran.
10 * 10 *
11 * Redistribution and use in source and binary forms, with or without 11 * Redistribution and use in source and binary forms, with or without
12 * modification, are permitted provided that the following conditions 12 * modification, are permitted provided that the following conditions
13 * are met: 13 * are met:
14 * 1. Redistributions of source code must retain the above copyright 14 * 1. Redistributions of source code must retain the above copyright
@@ -38,27 +38,26 @@ @@ -38,27 +38,26 @@
38#include <sys/pool.h> 38#include <sys/pool.h>
39#include <sys/queue.h> 39#include <sys/queue.h>
40#include <sys/sched.h> 40#include <sys/sched.h>
41#include <sys/syncobj.h> 41#include <sys/syncobj.h>
42#include <sys/param.h> 42#include <sys/param.h>
43 43
44/* 44/*
45 * Generic sleep queues. 45 * Generic sleep queues.
46 */ 46 */
47 47
48typedef struct sleepq sleepq_t; 48typedef struct sleepq sleepq_t;
49 49
50void sleepq_init(sleepq_t *); 50void sleepq_init(sleepq_t *);
51void sleepq_destroy(sleepq_t *); 
52void sleepq_remove(sleepq_t *, lwp_t *); 51void sleepq_remove(sleepq_t *, lwp_t *);
53void sleepq_enqueue(sleepq_t *, wchan_t, const char *, struct syncobj *, 52void sleepq_enqueue(sleepq_t *, wchan_t, const char *, struct syncobj *,
54 bool); 53 bool);
55void sleepq_transfer(lwp_t *, sleepq_t *, sleepq_t *, wchan_t, const char *, 54void sleepq_transfer(lwp_t *, sleepq_t *, sleepq_t *, wchan_t, const char *,
56 struct syncobj *, kmutex_t *, bool); 55 struct syncobj *, kmutex_t *, bool);
57void sleepq_uncatch(lwp_t *); 56void sleepq_uncatch(lwp_t *);
58void sleepq_unsleep(lwp_t *, bool); 57void sleepq_unsleep(lwp_t *, bool);
59void sleepq_timeout(void *); 58void sleepq_timeout(void *);
60void sleepq_wake(sleepq_t *, wchan_t, u_int, kmutex_t *); 59void sleepq_wake(sleepq_t *, wchan_t, u_int, kmutex_t *);
61int sleepq_abort(kmutex_t *, int); 60int sleepq_abort(kmutex_t *, int);
62void sleepq_changepri(lwp_t *, pri_t); 61void sleepq_changepri(lwp_t *, pri_t);
63void sleepq_lendpri(lwp_t *, pri_t); 62void sleepq_lendpri(lwp_t *, pri_t);
64int sleepq_block(int, bool); 63int sleepq_block(int, bool);