Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch Use sel{record,remove}_knote().
details: https://anonhg.NetBSD.org/src/rev/99f905bde0b9
branches: trunk
changeset: 947879:99f905bde0b9
user: thorpej <thorpej%NetBSD.org@localhost>
date: Sat Dec 19 15:12:17 2020 +0000
description:
Use sel{record,remove}_knote().
diffstat:
sys/arch/amiga/dev/event.c | 10 ++++------
sys/arch/arc/dev/opms.c | 10 ++++------
2 files changed, 8 insertions(+), 12 deletions(-)
diffs (98 lines):
diff -r dc78c0920e90 -r 99f905bde0b9 sys/arch/amiga/dev/event.c
--- a/sys/arch/amiga/dev/event.c Sat Dec 19 13:31:37 2020 +0000
+++ b/sys/arch/amiga/dev/event.c Sat Dec 19 15:12:17 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: event.c,v 1.14 2017/10/25 08:12:37 maya Exp $ */
+/* $NetBSD: event.c,v 1.15 2020/12/19 15:12:17 thorpej Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -43,7 +43,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: event.c,v 1.14 2017/10/25 08:12:37 maya Exp $");
+__KERNEL_RCSID(0, "$NetBSD: event.c,v 1.15 2020/12/19 15:12:17 thorpej Exp $");
/*
* Internal `Firm_event' interface for the keyboard and mouse drivers.
@@ -167,7 +167,7 @@
int s;
s = splev();
- SLIST_REMOVE(&ev->ev_sel.sel_klist, kn, knote, kn_selnext);
+ selremove_knote(&ev->ev_sel, kn);
splx(s);
}
@@ -200,12 +200,10 @@
int
ev_kqfilter(struct evvar *ev, struct knote *kn)
{
- struct klist *klist;
int s;
switch (kn->kn_filter) {
case EVFILT_READ:
- klist = &ev->ev_sel.sel_klist;
kn->kn_fop = &ev_filtops;
break;
@@ -216,7 +214,7 @@
kn->kn_hook = ev;
s = splev();
- SLIST_INSERT_HEAD(klist, kn, kn_selnext);
+ selrecord_knote(&ev->ev_sel, kn);
splx(s);
return (0);
diff -r dc78c0920e90 -r 99f905bde0b9 sys/arch/arc/dev/opms.c
--- a/sys/arch/arc/dev/opms.c Sat Dec 19 13:31:37 2020 +0000
+++ b/sys/arch/arc/dev/opms.c Sat Dec 19 15:12:17 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: opms.c,v 1.23 2018/09/03 16:29:22 riastradh Exp $ */
+/* $NetBSD: opms.c,v 1.24 2020/12/19 15:15:04 thorpej Exp $ */
/* $OpenBSD: pccons.c,v 1.22 1999/01/30 22:39:37 imp Exp $ */
/* NetBSD: pms.c,v 1.21 1995/04/18 02:25:18 mycroft Exp */
@@ -80,7 +80,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: opms.c,v 1.23 2018/09/03 16:29:22 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: opms.c,v 1.24 2020/12/19 15:15:04 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -459,7 +459,7 @@
int s;
s = spltty();
- SLIST_REMOVE(&sc->sc_rsel.sel_klist, kn, knote, kn_selnext);
+ selremove_knote(&sc->sc_rsel, kn);
splx(s);
}
@@ -483,12 +483,10 @@
opmskqfilter(dev_t dev, struct knote *kn)
{
struct opms_softc *sc = device_lookup_private(&opms_cd, PMSUNIT(dev));
- struct klist *klist;
int s;
switch (kn->kn_filter) {
case EVFILT_READ:
- klist = &sc->sc_rsel.sel_klist;
kn->kn_fop = &opmsread_filtops;
break;
@@ -499,7 +497,7 @@
kn->kn_hook = sc;
s = spltty();
- SLIST_INSERT_HEAD(klist, kn, kn_selnext);
+ selrecord_knote(&sc->sc_rsel, kn);
splx(s);
return 0;
Home |
Main Index |
Thread Index |
Old Index