diff options
author | Visa Hankala <visa@cvs.openbsd.org> | 2020-04-07 13:27:53 +0000 |
---|---|---|
committer | Visa Hankala <visa@cvs.openbsd.org> | 2020-04-07 13:27:53 +0000 |
commit | 31b8aeb32e081f42e1ec7f34094de4351458aed3 (patch) | |
tree | 620f7a0227efbc1b17d8b8e8b070acdf3c1c0436 /sys/arch/macppc | |
parent | a469bdd2f75259dda9613501bb83503033815c3c (diff) |
Abstract the head of knote lists. This allows extending the lists,
for example, with locking assertions.
OK mpi@, anton@
Diffstat (limited to 'sys/arch/macppc')
-rw-r--r-- | sys/arch/macppc/dev/apm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/macppc/dev/apm.c b/sys/arch/macppc/dev/apm.c index 743dc53fc7b..c99d3a14cdc 100644 --- a/sys/arch/macppc/dev/apm.c +++ b/sys/arch/macppc/dev/apm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: apm.c,v 1.21 2020/02/20 16:56:51 visa Exp $ */ +/* $OpenBSD: apm.c,v 1.22 2020/04/07 13:27:50 visa Exp $ */ /*- * Copyright (c) 2001 Alexander Guy. All rights reserved. @@ -305,7 +305,7 @@ filt_apmrdetach(struct knote *kn) { struct apm_softc *sc = (struct apm_softc *)kn->kn_hook; - SLIST_REMOVE(&sc->sc_note, kn, knote, kn_selnext); + klist_remove(&sc->sc_note, kn); } int @@ -337,7 +337,7 @@ apmkqfilter(dev_t dev, struct knote *kn) } kn->kn_hook = (caddr_t)sc; - SLIST_INSERT_HEAD(&sc->sc_note, kn, kn_selnext); + klist_insert(&sc->sc_note, kn); return (0); } |