diff options
| author | perry <perry@NetBSD.org> | 2005-12-24 19:12:23 +0000 |
|---|---|---|
| committer | perry <perry@NetBSD.org> | 2005-12-24 19:12:23 +0000 |
| commit | a2cd732268201e59a69ccf2bfd390176b5c270a6 (patch) | |
| tree | 3fbe88dade8c0e10a65f49e4e1b6790bed8b75e3 /sys | |
| parent | e14523e9437df221f7befdd807dec1d60740c4e1 (diff) | |
Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete.
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/kern/bufq_priocscan.c | 12 | ||||
| -rw-r--r-- | sys/kern/init_main.c | 6 | ||||
| -rw-r--r-- | sys/kern/kern_descrip.c | 10 | ||||
| -rw-r--r-- | sys/kern/kern_kcont.c | 10 | ||||
| -rw-r--r-- | sys/kern/kern_ktrace.c | 6 | ||||
| -rw-r--r-- | sys/kern/kern_lock.c | 48 | ||||
| -rw-r--r-- | sys/kern/kern_proc.c | 6 | ||||
| -rw-r--r-- | sys/kern/kern_sa.c | 28 | ||||
| -rw-r--r-- | sys/kern/kern_sig.c | 8 | ||||
| -rw-r--r-- | sys/kern/kern_synch.c | 26 | ||||
| -rw-r--r-- | sys/kern/subr_autoconf.c | 6 | ||||
| -rw-r--r-- | sys/kern/subr_extent.c | 6 | ||||
| -rw-r--r-- | sys/kern/subr_pool.c | 28 | ||||
| -rw-r--r-- | sys/kern/sys_pipe.c | 8 | ||||
| -rw-r--r-- | sys/kern/uipc_sem.c | 8 | ||||
| -rw-r--r-- | sys/kern/uipc_socket2.c | 6 | ||||
| -rw-r--r-- | sys/kern/vfs_bio.c | 28 | ||||
| -rw-r--r-- | sys/kern/vfs_cache.c | 8 | ||||
| -rw-r--r-- | sys/kern/vfs_lockf.c | 6 |
19 files changed, 132 insertions, 132 deletions
diff --git a/sys/kern/bufq_priocscan.c b/sys/kern/bufq_priocscan.c index e16f72bff72..9c382f746d0 100644 --- a/sys/kern/bufq_priocscan.c +++ b/sys/kern/bufq_priocscan.c @@ -1,4 +1,4 @@ -/* $NetBSD: bufq_priocscan.c,v 1.6 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: bufq_priocscan.c,v 1.7 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c)2004 YAMAMOTO Takashi, @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: bufq_priocscan.c,v 1.6 2005/12/11 12:24:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: bufq_priocscan.c,v 1.7 2005/12/24 19:12:23 perry Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -47,12 +47,12 @@ struct cscan_queue { daddr_t cq_lastrawblkno; /* b_rawblkno of the last request */ }; -static int __inline cscan_empty(const struct cscan_queue *); +static int inline cscan_empty(const struct cscan_queue *); static void cscan_put(struct cscan_queue *, struct buf *, int); static struct buf *cscan_get(struct cscan_queue *, int); static void cscan_init(struct cscan_queue *); -static __inline int +static inline int cscan_empty(const struct cscan_queue *q) { @@ -170,10 +170,10 @@ static struct buf *bufq_priocscan_get(struct bufq_state *, int); BUFQ_DEFINE(priocscan, 40, bufq_priocscan_init); -static __inline struct cscan_queue *bufq_priocscan_selectqueue( +static inline struct cscan_queue *bufq_priocscan_selectqueue( struct bufq_priocscan *, const struct buf *); -static __inline struct cscan_queue * +static inline struct cscan_queue * bufq_priocscan_selectqueue(struct bufq_priocscan *q, const struct buf *bp) { static const int priocscan_priomap[] = { diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c index ab022a5f7a0..6db96662c75 100644 --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -1,4 +1,4 @@ -/* $NetBSD: init_main.c,v 1.260 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: init_main.c,v 1.261 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1991, 1992, 1993 @@ -71,7 +71,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.260 2005/12/11 12:24:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.261 2005/12/24 19:12:23 perry Exp $"); #include "opt_ipsec.h" #include "opt_sysv.h" @@ -182,7 +182,7 @@ int cold = 1; /* still working on startup */ struct timeval boottime; time_t rootfstime; /* recorded root fs time, if known */ -__volatile int start_init_exec; /* semaphore for start_init() */ +volatile int start_init_exec; /* semaphore for start_init() */ static void check_console(struct lwp *l); static void start_init(void *); diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c index c8f72ab5d44..9950246fffb 100644 --- a/sys/kern/kern_descrip.c +++ b/sys/kern/kern_descrip.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_descrip.c,v 1.138 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: kern_descrip.c,v 1.139 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1991, 1993 @@ -37,7 +37,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_descrip.c,v 1.138 2005/12/11 12:24:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_descrip.c,v 1.139 2005/12/24 19:12:23 perry Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -83,7 +83,7 @@ MALLOC_DEFINE(M_FILE, "file", "Open file structure"); MALLOC_DEFINE(M_FILEDESC, "file desc", "Open file descriptor table"); MALLOC_DEFINE(M_IOCTLOPS, "ioctlops", "ioctl data buffer"); -static __inline int +static inline int find_next_zero(uint32_t *bitmap, int want, u_int bits) { int i, off, maxoff; @@ -139,7 +139,7 @@ find_last_set(struct filedesc *fd, int last) return (i); } -static __inline void +static inline void fd_used(struct filedesc *fdp, int fd) { u_int off = fd >> NDENTRYSHIFT; @@ -158,7 +158,7 @@ fd_used(struct filedesc *fdp, int fd) fdp->fd_lastfile = fd; } -static __inline void +static inline void fd_unused(struct filedesc *fdp, int fd) { u_int off = fd >> NDENTRYSHIFT; diff --git a/sys/kern/kern_kcont.c b/sys/kern/kern_kcont.c index 1ac20c3873a..3536212b566 100644 --- a/sys/kern/kern_kcont.c +++ b/sys/kern/kern_kcont.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_kcont.c,v 1.12 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: kern_kcont.c,v 1.13 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright 2003 Jonathan Stone. @@ -37,7 +37,7 @@ /* */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_kcont.c,v 1.12 2005/12/11 12:24:29 christos Exp $ "); +__KERNEL_RCSID(0, "$NetBSD: kern_kcont.c,v 1.13 2005/12/24 19:12:23 perry Exp $ "); #include <sys/types.h> #include <sys/param.h> @@ -85,7 +85,7 @@ static kcq_t kcq_process_ctxt; * For fine-grained SMP, both enqueueing and dequeueing will * need a locking mechanism. */ -static __inline void +static inline void kcont_enqueue_atomic(kcq_t *kcq, struct kc *kc) { int s; @@ -95,7 +95,7 @@ kcont_enqueue_atomic(kcq_t *kcq, struct kc *kc) splx(s); } -static __inline struct kc * +static inline struct kc * kcont_dequeue_atomic(kcq_t *kcq) { struct kc *kc; @@ -116,7 +116,7 @@ kcont_dequeue_atomic(kcq_t *kcq) * Used by functions that are about call an asynchronous operation, * to build a continuation to be called once the operation completes. */ -static __inline struct kc * +static inline struct kc * kc_set(struct kc *kc, void (*func)(void *, void *, int), void *env_arg, int ipl) { diff --git a/sys/kern/kern_ktrace.c b/sys/kern/kern_ktrace.c index 80b0c33fb27..0d52df137b8 100644 --- a/sys/kern/kern_ktrace.c +++ b/sys/kern/kern_ktrace.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_ktrace.c,v 1.99 2005/12/13 13:12:18 reinoud Exp $ */ +/* $NetBSD: kern_ktrace.c,v 1.100 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1989, 1993 @@ -32,7 +32,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_ktrace.c,v 1.99 2005/12/13 13:12:18 reinoud Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_ktrace.c,v 1.100 2005/12/24 19:12:23 perry Exp $"); #include "opt_ktrace.h" #include "opt_compat_mach.h" @@ -152,7 +152,7 @@ MALLOC_DEFINE(M_KTRACE, "ktrace", "ktrace data buffer"); POOL_INIT(kte_pool, sizeof(struct ktrace_entry), 0, 0, 0, "ktepl", &pool_allocator_nointr); -static __inline void +static inline void ktd_wakeup(struct ktr_desc *ktd) { diff --git a/sys/kern/kern_lock.c b/sys/kern/kern_lock.c index 5a5deb7e057..5bd89c15357 100644 --- a/sys/kern/kern_lock.c +++ b/sys/kern/kern_lock.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_lock.c,v 1.90 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: kern_lock.c,v 1.91 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 1999, 2000 The NetBSD Foundation, Inc. @@ -76,7 +76,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_lock.c,v 1.90 2005/12/11 12:24:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_lock.c,v 1.91 2005/12/24 19:12:23 perry Exp $"); #include "opt_multiprocessor.h" #include "opt_lockdebug.h" @@ -100,7 +100,7 @@ __KERNEL_RCSID(0, "$NetBSD: kern_lock.c,v 1.90 2005/12/11 12:24:29 christos Exp void lock_printf(const char *fmt, ...) __attribute__((__format__(__printf__,1,2))); -static int acquire(__volatile struct lock **, int *, int, int, int); +static int acquire(volatile struct lock **, int *, int, int, int); int lock_debug_syslog = 0; /* defaults to printf, but can be patched */ @@ -213,11 +213,11 @@ do { \ * Acquire a resource. */ static int -acquire(__volatile struct lock **lkpp, int *s, int extflags, +acquire(volatile struct lock **lkpp, int *s, int extflags, int drain, int wanted) { int error; - __volatile struct lock *lkp = *lkpp; + volatile struct lock *lkp = *lkpp; KASSERT(drain || (wanted & LK_WAIT_NONZERO) == 0); @@ -327,7 +327,7 @@ struct simplelock spinlock_list_slock = SIMPLELOCK_INITIALIZER; #define SPINLOCK_LIST_UNLOCK() /* nothing */ #endif /* MULTIPROCESSOR */ /* } */ -_TAILQ_HEAD(, struct lock, __volatile) spinlock_list = +_TAILQ_HEAD(, struct lock, volatile) spinlock_list = TAILQ_HEAD_INITIALIZER(spinlock_list); #define HAVEIT(lkp) \ @@ -537,10 +537,10 @@ spinlock_switchcheck(void) */ int #if defined(LOCKDEBUG) -_lockmgr(__volatile struct lock *lkp, u_int flags, +_lockmgr(volatile struct lock *lkp, u_int flags, struct simplelock *interlkp, const char *file, int line) #else -lockmgr(__volatile struct lock *lkp, u_int flags, +lockmgr(volatile struct lock *lkp, u_int flags, struct simplelock *interlkp) #endif { @@ -916,9 +916,9 @@ lockmgr(__volatile struct lock *lkp, u_int flags, int #if defined(LOCKDEBUG) -_spinlock_release_all(__volatile struct lock *lkp, const char *file, int line) +_spinlock_release_all(volatile struct lock *lkp, const char *file, int line) #else -spinlock_release_all(__volatile struct lock *lkp) +spinlock_release_all(volatile struct lock *lkp) #endif { int s, count; @@ -969,10 +969,10 @@ spinlock_release_all(__volatile struct lock *lkp) void #if defined(LOCKDEBUG) -_spinlock_acquire_count(__volatile struct lock *lkp, int count, +_spinlock_acquire_count(volatile struct lock *lkp, int count, const char *file, int line) #else -spinlock_acquire_count(__volatile struct lock *lkp, int count) +spinlock_acquire_count(volatile struct lock *lkp, int count) #endif { int s, error; @@ -1022,7 +1022,7 @@ spinlock_acquire_count(__volatile struct lock *lkp, int count) * routines to display ststus about contained locks. */ void -lockmgr_printinfo(__volatile struct lock *lkp) +lockmgr_printinfo(volatile struct lock *lkp) { if (lkp->lk_sharecount) @@ -1043,7 +1043,7 @@ lockmgr_printinfo(__volatile struct lock *lkp) } #if defined(LOCKDEBUG) /* { */ -_TAILQ_HEAD(, struct simplelock, __volatile) simplelock_list = +_TAILQ_HEAD(, struct simplelock, volatile) simplelock_list = TAILQ_HEAD_INITIALIZER(simplelock_list); #if defined(MULTIPROCESSOR) /* { */ @@ -1095,7 +1095,7 @@ do { \ * they are being called. */ void -simple_lock_init(__volatile struct simplelock *alp) +simple_lock_init(volatile struct simplelock *alp) { #if defined(MULTIPROCESSOR) /* { */ @@ -1111,7 +1111,7 @@ simple_lock_init(__volatile struct simplelock *alp) } void -_simple_lock(__volatile struct simplelock *alp, const char *id, int l) +_simple_lock(volatile struct simplelock *alp, const char *id, int l) { cpuid_t cpu_num = cpu_number(); int s; @@ -1163,7 +1163,7 @@ _simple_lock(__volatile struct simplelock *alp, const char *id, int l) } int -_simple_lock_held(__volatile struct simplelock *alp) +_simple_lock_held(volatile struct simplelock *alp) { #if defined(MULTIPROCESSOR) || defined(DIAGNOSTIC) cpuid_t cpu_num = cpu_number(); @@ -1190,7 +1190,7 @@ _simple_lock_held(__volatile struct simplelock *alp) } int -_simple_lock_try(__volatile struct simplelock *alp, const char *id, int l) +_simple_lock_try(volatile struct simplelock *alp, const char *id, int l) { cpuid_t cpu_num = cpu_number(); int s, rv = 0; @@ -1238,7 +1238,7 @@ _simple_lock_try(__volatile struct simplelock *alp, const char *id, int l) } void -_simple_unlock(__volatile struct simplelock *alp, const char *id, int l) +_simple_unlock(volatile struct simplelock *alp, const char *id, int l) { int s; @@ -1283,7 +1283,7 @@ _simple_unlock(__volatile struct simplelock *alp, const char *id, int l) void simple_lock_dump(void) { - __volatile struct simplelock *alp; + volatile struct simplelock *alp; int s; s = spllock(); @@ -1300,14 +1300,14 @@ simple_lock_dump(void) void simple_lock_freecheck(void *start, void *end) { - __volatile struct simplelock *alp; + volatile struct simplelock *alp; int s; s = spllock(); SLOCK_LIST_LOCK(); TAILQ_FOREACH(alp, &simplelock_list, list) { - if ((__volatile void *)alp >= start && - (__volatile void *)alp < end) { + if ((volatile void *)alp >= start && + (volatile void *)alp < end) { lock_printf("freeing simple_lock %p CPU %lu %s:%d\n", alp, alp->lock_holder, alp->lock_file, alp->lock_line); @@ -1332,7 +1332,7 @@ simple_lock_switchcheck(void) void simple_lock_only_held(volatile struct simplelock *lp, const char *where) { - __volatile struct simplelock *alp; + volatile struct simplelock *alp; cpuid_t cpu_num = cpu_number(); int s; diff --git a/sys/kern/kern_proc.c b/sys/kern/kern_proc.c index 6e12c1d270e..9c2f61f3af7 100644 --- a/sys/kern/kern_proc.c +++ b/sys/kern/kern_proc.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_proc.c,v 1.83 2005/11/26 05:26:33 simonb Exp $ */ +/* $NetBSD: kern_proc.c,v 1.84 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 1999 The NetBSD Foundation, Inc. @@ -69,7 +69,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_proc.c,v 1.83 2005/11/26 05:26:33 simonb Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_proc.c,v 1.84 2005/12/24 19:12:23 perry Exp $"); #include "opt_kstack.h" @@ -140,7 +140,7 @@ struct pid_table { struct pgrp *pt_pgrp; }; #if 1 /* strongly typed cast - should be a noop */ -static __inline uint p2u(struct proc *p) { return (uint)(uintptr_t)p; } +static inline uint p2u(struct proc *p) { return (uint)(uintptr_t)p; } #else #define p2u(p) ((uint)p) #endif diff --git a/sys/kern/kern_sa.c b/sys/kern/kern_sa.c index e361a49924b..fad3566f5b8 100644 --- a/sys/kern/kern_sa.c +++ b/sys/kern/kern_sa.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_sa.c,v 1.69 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: kern_sa.c,v 1.70 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 2001, 2004, 2005 The NetBSD Foundation, Inc. @@ -39,7 +39,7 @@ #include <sys/cdefs.h> #include "opt_ktrace.h" -__KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.69 2005/12/11 12:24:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.70 2005/12/24 19:12:23 perry Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -57,21 +57,21 @@ __KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.69 2005/12/11 12:24:29 christos Exp $" #include <uvm/uvm_extern.h> static struct sadata_vp *sa_newsavp(struct sadata *); -static __inline int sa_stackused(struct sastack *, struct sadata *); -static __inline void sa_setstackfree(struct sastack *, struct sadata *); +static inline int sa_stackused(struct sastack *, struct sadata *); +static inline void sa_setstackfree(struct sastack *, struct sadata *); static struct sastack *sa_getstack(struct sadata *); -static __inline struct sastack *sa_getstack0(struct sadata *); -static __inline int sast_compare(struct sastack *, struct sastack *); +static inline struct sastack *sa_getstack0(struct sadata *); +static inline int sast_compare(struct sastack *, struct sastack *); #ifdef MULTIPROCESSOR static int sa_increaseconcurrency(struct lwp *, int); #endif static void sa_setwoken(struct lwp *); static void sa_switchcall(void *); static int sa_newcachelwp(struct lwp *); -static __inline void sa_makeupcalls(struct lwp *); +static inline void sa_makeupcalls(struct lwp *); static struct lwp *sa_vp_repossess(struct lwp *l); -static __inline int sa_pagefault(struct lwp *, ucontext_t *); +static inline int sa_pagefault(struct lwp *, ucontext_t *); static void sa_upcall0(struct sadata_upcall *, int, struct lwp *, struct lwp *, size_t, void *, void (*)(void *)); @@ -263,7 +263,7 @@ sa_release(struct proc *p) } -static __inline int +static inline int sa_stackused(struct sastack *sast, struct sadata *sa) { unsigned int gen; @@ -281,7 +281,7 @@ sa_stackused(struct sastack *sast, struct sadata *sa) return (sast->sast_gen != gen); } -static __inline void +static inline void sa_setstackfree(struct sastack *sast, struct sadata *sa) { @@ -318,7 +318,7 @@ sa_getstack(struct sadata *sa) return sast; } -static __inline struct sastack * +static inline struct sastack * sa_getstack0(struct sadata *sa) { struct sastack *start; @@ -342,7 +342,7 @@ sa_getstack0(struct sadata *sa) return sa->sa_stacknext; } -static __inline int +static inline int sast_compare(struct sastack *a, struct sastack *b) { if ((vaddr_t)a->sast_stack.ss_sp + a->sast_stack.ss_size <= @@ -817,7 +817,7 @@ sa_upcall_getstate(union sau_state *ss, struct lwp *l) * - pagefaults on upcalls are detected by checking if the userspace * thread is running on an upcall stack */ -static __inline int +static inline int sa_pagefault(struct lwp *l, ucontext_t *l_ctx) { struct proc *p; @@ -1302,7 +1302,7 @@ sa_upcall_userret(struct lwp *l) return; } -static __inline void +static inline void sa_makeupcalls(struct lwp *l) { struct lwp *l2, *eventq; diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c index 8ee2c841b6f..3cc37c80792 100644 --- a/sys/kern/kern_sig.c +++ b/sys/kern/kern_sig.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_sig.c,v 1.212 2005/12/11 12:24:29 christos Exp $ */ +/* $NetBSD: kern_sig.c,v 1.213 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1991, 1993 @@ -37,7 +37,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_sig.c,v 1.212 2005/12/11 12:24:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_sig.c,v 1.213 2005/12/24 19:12:23 perry Exp $"); #include "opt_ktrace.h" #include "opt_compat_sunos.h" @@ -1425,9 +1425,9 @@ kpsendsig(struct lwp *l, const ksiginfo_t *ksi, const sigset_t *mask) (*p->p_emul->e_sendsig)(ksi, mask); } -static __inline int firstsig(const sigset_t *); +static inline int firstsig(const sigset_t *); -static __inline int +static inline int firstsig(const sigset_t *ss) { int sig; diff --git a/sys/kern/kern_synch.c b/sys/kern/kern_synch.c index 10c2926ea9f..794bf3c3b28 100644 --- a/sys/kern/kern_synch.c +++ b/sys/kern/kern_synch.c @@ -1,4 +1,4 @@ -/* $NetBSD: kern_synch.c,v 1.157 2005/12/24 12:57:14 yamt Exp $ */ +/* $NetBSD: kern_synch.c,v 1.158 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 1999, 2000, 2004 The NetBSD Foundation, Inc. @@ -76,7 +76,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: kern_synch.c,v 1.157 2005/12/24 12:57:14 yamt Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_synch.c,v 1.158 2005/12/24 19:12:23 perry Exp $"); #include "opt_ddb.h" #include "opt_ktrace.h" @@ -127,7 +127,7 @@ int rrticks; /* number of hardclock ticks per roundrobin() */ * The global scheduler state. */ struct prochd sched_qs[RUNQUE_NQS]; /* run queues */ -__volatile u_int32_t sched_whichqs; /* bitmap of non-empty queues */ +volatile u_int32_t sched_whichqs; /* bitmap of non-empty queues */ struct slpque sched_slpque[SLPQUE_TABLESIZE]; /* sleep queues */ struct simplelock sched_lock = SIMPLELOCK_INITIALIZER; @@ -136,8 +136,8 @@ void schedcpu(void *); void updatepri(struct lwp *); void endtsleep(void *); -__inline void sa_awaken(struct lwp *); -__inline void awaken(struct lwp *); +inline void sa_awaken(struct lwp *); +inline void awaken(struct lwp *); struct callout schedcpu_ch = CALLOUT_INITIALIZER_SETFUNC(schedcpu, NULL); static unsigned int schedcpu_ticks; @@ -430,8 +430,8 @@ int safepri; * interlock will always be unlocked upon return. */ int -ltsleep(__volatile const void *ident, int priority, const char *wmesg, int timo, - __volatile struct simplelock *interlock) +ltsleep(volatile const void *ident, int priority, const char *wmesg, int timo, + volatile struct simplelock *interlock) { struct lwp *l = curlwp; struct proc *p = l ? l->l_proc : NULL; @@ -675,7 +675,7 @@ unsleep(struct lwp *l) } } -__inline void +inline void sa_awaken(struct lwp *l) { @@ -688,7 +688,7 @@ sa_awaken(struct lwp *l) /* * Optimized-for-wakeup() version of setrunnable(). */ -__inline void +inline void awaken(struct lwp *l) { @@ -738,7 +738,7 @@ sched_lock_idle(void) */ void -wakeup(__volatile const void *ident) +wakeup(volatile const void *ident) { int s; @@ -750,7 +750,7 @@ wakeup(__volatile const void *ident) } void -sched_wakeup(__volatile const void *ident) +sched_wakeup(volatile const void *ident) { struct slpque *qp; struct lwp *l, **q; @@ -784,7 +784,7 @@ sched_wakeup(__volatile const void *ident) * identifier runnable. */ void -wakeup_one(__volatile const void *ident) +wakeup_one(volatile const void *ident) { struct slpque *qp; struct lwp *l, **q; @@ -1055,7 +1055,7 @@ rqinit() (struct lwp *)&sched_qs[i]; } -static __inline void +static inline void resched_proc(struct lwp *l, u_char pri) { struct cpu_info *ci; diff --git a/sys/kern/subr_autoconf.c b/sys/kern/subr_autoconf.c index 53432308c73..a0ea943394a 100644 --- a/sys/kern/subr_autoconf.c +++ b/sys/kern/subr_autoconf.c @@ -1,4 +1,4 @@ -/* $NetBSD: subr_autoconf.c,v 1.102 2005/12/20 04:39:36 thorpej Exp $ */ +/* $NetBSD: subr_autoconf.c,v 1.103 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1996, 2000 Christopher G. Demetriou @@ -77,7 +77,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: subr_autoconf.c,v 1.102 2005/12/20 04:39:36 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: subr_autoconf.c,v 1.103 2005/12/24 19:12:23 perry Exp $"); #include "opt_ddb.h" @@ -170,7 +170,7 @@ static int config_finalize_done; /* list of all devices */ struct devicelist alldevs; -__volatile int config_pending; /* semaphore for mountroot */ +volatile int config_pending; /* semaphore for mountroot */ #define STREQ(s1, s2) \ (*(s1) == *(s2) && strcmp((s1), (s2)) == 0) diff --git a/sys/kern/subr_extent.c b/sys/kern/subr_extent.c index 2e40df5a627..844b48b64c2 100644 --- a/sys/kern/subr_extent.c +++ b/sys/kern/subr_extent.c @@ -1,4 +1,4 @@ -/* $NetBSD: subr_extent.c,v 1.53 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: subr_extent.c,v 1.54 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 1996, 1998 The NetBSD Foundation, Inc. @@ -41,7 +41,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: subr_extent.c,v 1.53 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: subr_extent.c,v 1.54 2005/12/24 19:12:23 perry Exp $"); #ifdef _KERNEL #include "opt_lockdebug.h" @@ -120,7 +120,7 @@ static int expool_initialized; * (This is deferred until one of our callers thinks we can malloc()). */ -static __inline void +static inline void expool_init(void) { diff --git a/sys/kern/subr_pool.c b/sys/kern/subr_pool.c index b316ee26250..e61378c8793 100644 --- a/sys/kern/subr_pool.c +++ b/sys/kern/subr_pool.c @@ -1,4 +1,4 @@ -/* $NetBSD: subr_pool.c,v 1.109 2005/12/20 15:52:14 christos Exp $ */ +/* $NetBSD: subr_pool.c,v 1.110 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 1997, 1999, 2000 The NetBSD Foundation, Inc. @@ -38,7 +38,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: subr_pool.c,v 1.109 2005/12/20 15:52:14 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: subr_pool.c,v 1.110 2005/12/24 19:12:23 perry Exp $"); #include "opt_pool.h" #include "opt_poollog.h" @@ -214,7 +214,7 @@ struct pool_log { int pool_logsize = POOL_LOGSIZE; -static __inline void +static inline void pr_log(struct pool *pp, void *v, int action, const char *file, long line) { int n = pp->pr_curlogentry; @@ -267,7 +267,7 @@ pr_printlog(struct pool *pp, struct pool_item *pi, } } -static __inline void +static inline void pr_enter(struct pool *pp, const char *file, long line) { @@ -283,7 +283,7 @@ pr_enter(struct pool *pp, const char *file, long line) pp->pr_entered_line = line; } -static __inline void +static inline void pr_leave(struct pool *pp) { @@ -296,7 +296,7 @@ pr_leave(struct pool *pp) pp->pr_entered_line = 0; } -static __inline void +static inline void pr_enter_check(struct pool *pp, void (*pr)(const char *, ...)) { @@ -312,7 +312,7 @@ pr_enter_check(struct pool *pp, void (*pr)(const char *, ...)) #define pr_enter_check(pp, pr) #endif /* POOL_DIAGNOSTIC */ -static __inline int +static inline int pr_item_notouch_index(const struct pool *pp, const struct pool_item_header *ph, const void *v) { @@ -331,7 +331,7 @@ pr_item_notouch_index(const struct pool *pp, const struct pool_item_header *ph, #define PR_INDEX_USED ((pool_item_freelist_t)-1) #define PR_INDEX_EOL ((pool_item_freelist_t)-2) -static __inline void +static inline void pr_item_notouch_put(const struct pool *pp, struct pool_item_header *ph, void *obj) { @@ -343,7 +343,7 @@ pr_item_notouch_put(const struct pool *pp, struct pool_item_header *ph, ph->ph_firstfree = idx; } -static __inline void * +static inline void * pr_item_notouch_get(const struct pool *pp, struct pool_item_header *ph) { int idx = ph->ph_firstfree; @@ -356,7 +356,7 @@ pr_item_notouch_get(const struct pool *pp, struct pool_item_header *ph) return ph->ph_page + ph->ph_off + idx * pp->pr_size; } -static __inline int +static inline int phtree_compare(struct pool_item_header *a, struct pool_item_header *b) { if (a->ph_page < b->ph_page) @@ -373,7 +373,7 @@ SPLAY_GENERATE(phtree, pool_item_header, ph_node, phtree_compare); /* * Return the pool page header based on page address. */ -static __inline struct pool_item_header * +static inline struct pool_item_header * pr_find_pagehead(struct pool *pp, caddr_t page) { struct pool_item_header *ph, tmp; @@ -406,7 +406,7 @@ pr_pagelist_free(struct pool *pp, struct pool_pagelist *pq) /* * Remove a page from the pool. */ -static __inline void +static inline void pr_rmpage(struct pool *pp, struct pool_item_header *ph, struct pool_pagelist *pq) { @@ -1894,7 +1894,7 @@ pool_cache_destroy(struct pool_cache *pc) simple_unlock(&pp->pr_slock); } -static __inline void * +static inline void * pcg_get(struct pool_cache_group *pcg, paddr_t *pap) { void *object; @@ -1913,7 +1913,7 @@ pcg_get(struct pool_cache_group *pcg, paddr_t *pap) return (object); } -static __inline void +static inline void pcg_put(struct pool_cache_group *pcg, void *object, paddr_t pa) { u_int idx; diff --git a/sys/kern/sys_pipe.c b/sys/kern/sys_pipe.c index bc9403309b8..f5537c8d191 100644 --- a/sys/kern/sys_pipe.c +++ b/sys/kern/sys_pipe.c @@ -1,4 +1,4 @@ -/* $NetBSD: sys_pipe.c,v 1.69 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: sys_pipe.c,v 1.70 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 2003 The NetBSD Foundation, Inc. @@ -83,7 +83,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: sys_pipe.c,v 1.69 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sys_pipe.c,v 1.70 2005/12/24 19:12:23 perry Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -186,7 +186,7 @@ static void pipeclose(struct file *fp, struct pipe *pipe); static void pipe_free_kmem(struct pipe *pipe); static int pipe_create(struct pipe **pipep, int allockva); static int pipelock(struct pipe *pipe, int catch); -static __inline void pipeunlock(struct pipe *pipe); +static inline void pipeunlock(struct pipe *pipe); static void pipeselwakeup(struct pipe *pipe, struct pipe *sigp, int code); #ifndef PIPE_NODIRECT static int pipe_direct_write(struct file *fp, struct pipe *wpipe, @@ -356,7 +356,7 @@ pipelock(struct pipe *pipe, int catch) /* * unlock a pipe I/O lock */ -static __inline void +static inline void pipeunlock(struct pipe *pipe) { diff --git a/sys/kern/uipc_sem.c b/sys/kern/uipc_sem.c index 72a32015a97..a28268b4565 100644 --- a/sys/kern/uipc_sem.c +++ b/sys/kern/uipc_sem.c @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_sem.c,v 1.11 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: uipc_sem.c,v 1.12 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 2003 The NetBSD Foundation, Inc. @@ -63,7 +63,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: uipc_sem.c,v 1.11 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_sem.c,v 1.12 2005/12/24 19:12:23 perry Exp $"); #include "opt_posix.h" @@ -150,7 +150,7 @@ ksem_free(struct ksem *ks) simple_unlock(&ks->ks_interlock); } -static __inline void +static inline void ksem_addref(struct ksem *ks) { @@ -159,7 +159,7 @@ ksem_addref(struct ksem *ks) KASSERT(ks->ks_ref != 0); /* XXX KDASSERT */ } -static __inline void +static inline void ksem_delref(struct ksem *ks) { diff --git a/sys/kern/uipc_socket2.c b/sys/kern/uipc_socket2.c index 436e4a448be..cef2b332872 100644 --- a/sys/kern/uipc_socket2.c +++ b/sys/kern/uipc_socket2.c @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_socket2.c,v 1.69 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: uipc_socket2.c,v 1.70 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1982, 1986, 1988, 1990, 1993 @@ -32,7 +32,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: uipc_socket2.c,v 1.69 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_socket2.c,v 1.70 2005/12/24 19:12:23 perry Exp $"); #include "opt_mbuftrace.h" #include "opt_sb_max.h" @@ -775,7 +775,7 @@ sbappendaddr(struct sockbuf *sb, const struct sockaddr *asa, struct mbuf *m0, * Helper for sbappendchainaddr: prepend a struct sockaddr* to * an mbuf chain. */ -static __inline struct mbuf * +static inline struct mbuf * m_prepend_sockaddr(struct sockbuf *sb, struct mbuf *m0, const struct sockaddr *asa) { diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c index ef94f219c0e..cb76a9827ab 100644 --- a/sys/kern/vfs_bio.c +++ b/sys/kern/vfs_bio.c @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_bio.c,v 1.147 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: vfs_bio.c,v 1.148 2005/12/24 19:12:23 perry Exp $ */ /*- * Copyright (c) 1982, 1986, 1989, 1993 @@ -81,7 +81,7 @@ #include "opt_softdep.h" #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: vfs_bio.c,v 1.147 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_bio.c,v 1.148 2005/12/24 19:12:23 perry Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -122,16 +122,16 @@ static void buf_setwm(void); static int buf_trim(void); static void *bufpool_page_alloc(struct pool *, int); static void bufpool_page_free(struct pool *, void *); -static __inline struct buf *bio_doread(struct vnode *, daddr_t, int, +static inline struct buf *bio_doread(struct vnode *, daddr_t, int, struct ucred *, int); static int buf_lotsfree(void); static int buf_canrelease(void); -static __inline u_long buf_mempoolidx(u_long); -static __inline u_long buf_roundsize(u_long); -static __inline caddr_t buf_malloc(size_t); +static inline u_long buf_mempoolidx(u_long); +static inline u_long buf_roundsize(u_long); +static inline caddr_t buf_malloc(size_t); static void buf_mrelease(caddr_t, size_t); -static __inline void binsheadfree(struct buf *, struct bqueue *); -static __inline void binstailfree(struct buf *, struct bqueue *); +static inline void binsheadfree(struct buf *, struct bqueue *); +static inline void binstailfree(struct buf *, struct bqueue *); int count_lock_queue(void); /* XXX */ #ifdef DEBUG static int checkfreelist(struct buf *, struct bqueue *); @@ -285,7 +285,7 @@ checkfreelist(struct buf *bp, struct bqueue *dp) * Insq/Remq for the buffer hash lists. * Call with buffer queue locked. */ -static __inline void +static inline void binsheadfree(struct buf *bp, struct bqueue *dp) { @@ -295,7 +295,7 @@ binsheadfree(struct buf *bp, struct bqueue *dp) bp->b_freelistindex = dp - bufqueues; } -static __inline void +static inline void binstailfree(struct buf *bp, struct bqueue *dp) { @@ -504,7 +504,7 @@ buf_canrelease(void) /* * Buffer memory allocation helper functions */ -static __inline u_long +static inline u_long buf_mempoolidx(u_long size) { u_int n = 0; @@ -520,14 +520,14 @@ buf_mempoolidx(u_long size) return n; } -static __inline u_long +static inline u_long buf_roundsize(u_long size) { /* Round up to nearest power of 2 */ return (1 << (buf_mempoolidx(size) + MEMPOOL_INDEX_OFFSET)); } -static __inline caddr_t +static inline caddr_t buf_malloc(size_t size) { u_int n = buf_mempoolidx(size); @@ -565,7 +565,7 @@ buf_mrelease(caddr_t addr, size_t size) /* * bread()/breadn() helper. */ -static __inline struct buf * +static inline struct buf * bio_doread(struct vnode *vp, daddr_t blkno, int size, struct ucred *cred, int async) { diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c index 814bff64934..00de80a21a8 100644 --- a/sys/kern/vfs_cache.c +++ b/sys/kern/vfs_cache.c @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_cache.c,v 1.62 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: vfs_cache.c,v 1.63 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1989, 1993 @@ -32,7 +32,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: vfs_cache.c,v 1.62 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_cache.c,v 1.63 2005/12/24 19:12:23 perry Exp $"); #include "opt_ddb.h" #include "opt_revcache.h" @@ -97,7 +97,7 @@ static struct simplelock namecache_slock = SIMPLELOCK_INITIALIZER; static void cache_remove(struct namecache *); static void cache_free(struct namecache *); -static __inline struct namecache *cache_lookup_entry( +static inline struct namecache *cache_lookup_entry( const struct vnode *, const struct componentname *); static void @@ -136,7 +136,7 @@ cache_free(struct namecache *ncp) numcache--; } -static __inline struct namecache * +static inline struct namecache * cache_lookup_entry(const struct vnode *dvp, const struct componentname *cnp) { struct nchashhead *ncpp; diff --git a/sys/kern/vfs_lockf.c b/sys/kern/vfs_lockf.c index d2d52823891..59c9c1b3984 100644 --- a/sys/kern/vfs_lockf.c +++ b/sys/kern/vfs_lockf.c @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_lockf.c,v 1.47 2005/12/11 12:24:30 christos Exp $ */ +/* $NetBSD: vfs_lockf.c,v 1.48 2005/12/24 19:12:23 perry Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1993 @@ -35,7 +35,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: vfs_lockf.c,v 1.47 2005/12/11 12:24:30 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_lockf.c,v 1.48 2005/12/24 19:12:23 perry Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -509,7 +509,7 @@ lf_setlock(struct lockf *lock, struct lockf **sparelock, if ((lock->lf_flags & F_POSIX) && (block->lf_flags & F_POSIX)) { struct lwp *wlwp; - __volatile const struct lockf *waitblock; + volatile const struct lockf *waitblock; int i = 0; /* |
