diff options
author | phk <phk@FreeBSD.org> | 1999-11-16 10:56:05 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-11-16 10:56:05 +0000 |
commit | 8fca18de89986d6275d0502af100b97274c4bab5 (patch) | |
tree | d8a3cb26e484830479c8386ecba6b7d0157acc06 /sys/kern/subr_devstat.c | |
parent | 520fff788fc8f2154247a6cff986abf634fdbb51 (diff) | |
download | FreeBSD-src-8fca18de89986d6275d0502af100b97274c4bab5.zip FreeBSD-src-8fca18de89986d6275d0502af100b97274c4bab5.tar.gz |
This is a partial commit of the patch from PR 14914:
Alot of the code in sys/kern directly accesses the *Q_HEAD and *Q_ENTRY
structures for list operations. This patch makes all list operations
in sys/kern use the queue(3) macros, rather than directly accessing the
*Q_{HEAD,ENTRY} structures.
This batch of changes compile to the same object files.
Reviewed by: phk
Submitted by: Jake Burkholder <jake@checker.org>
PR: 14914
Diffstat (limited to 'sys/kern/subr_devstat.c')
-rw-r--r-- | sys/kern/subr_devstat.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/subr_devstat.c b/sys/kern/subr_devstat.c index 23b397a..b04662b 100644 --- a/sys/kern/subr_devstat.c +++ b/sys/kern/subr_devstat.c @@ -281,9 +281,9 @@ sysctl_devstat SYSCTL_HANDLER_ARGS /* * Now push out all the devices. */ - for (i = 0, nds = devstat_head->stqh_first; + for (i = 0, nds = STAILQ_FIRST(devstat_head); (nds != NULL) && (i < devstat_num_devs) && (error == 0); - nds = nds->dev_links.stqe_next, i++) + nds = STAILQ_NEXT(nds, dev_links), i++) error = SYSCTL_OUT(req, nds, sizeof(struct devstat)); return(error); |