From 37fcf2909492f7075bf6d42e7fd1f78345527048 Mon Sep 17 00:00:00 2001 From: "Samuel J. Greear" Date: Wed, 14 Jul 2010 19:24:30 +0000 Subject: [PATCH] kernel - Add missing KNOTE's * Place a KNOTE call anywhere there is currently a call to selwakeup. --- sys/bus/firewire/firewire.c | 1 + sys/bus/usb/usb.c | 1 + sys/dev/misc/cmx/cmx.c | 4 ++++ sys/dev/misc/hotplug/hotplug.c | 1 + sys/dev/misc/kbd/kbd.c | 2 ++ sys/dev/misc/mse/mse.c | 1 + sys/dev/misc/nmdm/nmdm.c | 2 ++ sys/dev/misc/psm/psm.c | 1 + sys/dev/misc/snp/snp.c | 2 ++ sys/dev/misc/spic/spic.c | 1 + sys/dev/misc/tw/tw.c | 1 + sys/dev/raid/aac/aac.c | 1 + sys/dev/serial/stl/stallion.c | 1 + sys/dev/serial/stli/istallion.c | 1 + sys/dev/sound/pcm/buffer.c | 4 +++- sys/dev/usbmisc/ucom/ucom.c | 1 + sys/dev/usbmisc/ugen/ugen.c | 3 +++ sys/dev/usbmisc/uhid/uhid.c | 1 + sys/dev/video/bktr/bktr_core.c | 2 +- sys/dev/video/cxm/cxm.c | 1 + sys/kern/kern_udev.c | 1 + sys/kern/subr_bus.c | 1 + sys/kern/subr_log.c | 1 + sys/kern/sys_mqueue.c | 4 ++++ sys/net/bpf.c | 1 + sys/net/i4b/driver/i4b_rbch.c | 3 +++ sys/net/i4b/driver/i4b_tel.c | 5 +++++ sys/net/i4b/layer4/i4b_i4bdrv.c | 2 ++ sys/net/tap/if_tap.c | 1 + sys/net/tun/if_tun.c | 3 +++ sys/platform/pc32/apm/apm.c | 1 + sys/platform/pc32/isa/asc.c | 1 + sys/platform/pc64/apm/apm.c | 1 + sys/platform/pc64/isa/asc.c | 1 + 34 files changed, 56 insertions(+), 2 deletions(-) diff --git a/sys/bus/firewire/firewire.c b/sys/bus/firewire/firewire.c index 6dffc25b88..145caa7352 100644 --- a/sys/bus/firewire/firewire.c +++ b/sys/bus/firewire/firewire.c @@ -1956,6 +1956,7 @@ fw_rcv(struct fw_rcv_buf *rb) if (SEL_WAITING(&xferq->rsel)) #endif selwakeuppri(&xferq->rsel, FWPRI); + KNOTE(&xferq->rsel.si_note, 0); if (xferq->flag & FWXFERQ_WAKEUP) { xferq->flag &= ~FWXFERQ_WAKEUP; wakeup((caddr_t)xferq); diff --git a/sys/bus/usb/usb.c b/sys/bus/usb/usb.c index 35f3b74eb7..8c0b5710a8 100644 --- a/sys/bus/usb/usb.c +++ b/sys/bus/usb/usb.c @@ -871,6 +871,7 @@ usb_add_event(int type, struct usb_event *uep) usb_nevents++; wakeup(&usb_events); selwakeup(&usb_selevent); + KNOTE(&usb_selevent.si_note, 0); if (usb_async_proc != NULL) { ksignal(usb_async_proc, SIGIO); } diff --git a/sys/dev/misc/cmx/cmx.c b/sys/dev/misc/cmx/cmx.c index 16e138a9e2..54ccb3eb0a 100644 --- a/sys/dev/misc/cmx/cmx.c +++ b/sys/dev/misc/cmx/cmx.c @@ -282,6 +282,7 @@ cmx_detach(device_t dev) sc->polling = 0; CMX_UNLOCK(sc); selwakeup(&sc->sel); + KNOTE(&sc->sel.si_note, 0); } else { CMX_UNLOCK(sc); } @@ -405,6 +406,7 @@ cmx_tick(void *xsc) if (cmx_test(bsr, BSR_BULK_IN_FULL, 1)) { sc->polling = 0; selwakeup(&sc->sel); + KNOTE(&sc->sel.si_note, 0); } else { callout_reset(&sc->ch, POLL_TICKS, cmx_tick, sc); } @@ -463,6 +465,7 @@ cmx_close(struct dev_close_args *ap) sc->polling = 0; CMX_UNLOCK(sc); selwakeup(&sc->sel); + KNOTE(&sc->sel.si_note, 0); CMX_LOCK(sc); } sc->open = 0; @@ -504,6 +507,7 @@ cmx_read(struct dev_read_args *ap) sc->polling = 0; CMX_UNLOCK(sc); selwakeup(&sc->sel); + KNOTE(&sc->sel.si_note, 0); } else { CMX_UNLOCK(sc); } diff --git a/sys/dev/misc/hotplug/hotplug.c b/sys/dev/misc/hotplug/hotplug.c index 043e92fea2..a16d719fca 100644 --- a/sys/dev/misc/hotplug/hotplug.c +++ b/sys/dev/misc/hotplug/hotplug.c @@ -222,6 +222,7 @@ hotplug_put_event(struct hotplug_event *he) wakeup(&hpsc); lockmgr(&hpsc.lock, LK_RELEASE); selwakeup(&hpsc.sel); + KNOTE(&hpsc.sel.si_note, 0); return (0); } diff --git a/sys/dev/misc/kbd/kbd.c b/sys/dev/misc/kbd/kbd.c index 1d86f1fe10..eb1437ae01 100644 --- a/sys/dev/misc/kbd/kbd.c +++ b/sys/dev/misc/kbd/kbd.c @@ -837,6 +837,7 @@ genkbd_event(keyboard_t *kbd, int event, void *arg) wakeup((caddr_t)sc); } selwakeup(&sc->gkb_rsel); + KNOTE(&sc->gkb_rsel.si_note, 0); return 0; default: return EINVAL; @@ -907,6 +908,7 @@ genkbd_event(keyboard_t *kbd, int event, void *arg) wakeup((caddr_t)sc); } selwakeup(&sc->gkb_rsel); + KNOTE(&sc->gkb_rsel.si_note, 0); } return 0; diff --git a/sys/dev/misc/mse/mse.c b/sys/dev/misc/mse/mse.c index 3d660dd92f..a14a7a81b8 100644 --- a/sys/dev/misc/mse/mse.c +++ b/sys/dev/misc/mse/mse.c @@ -758,6 +758,7 @@ mseintr(void *arg) wakeup((caddr_t)sc); } selwakeup(&sc->sc_selp); + KNOTE(&sc->sc_selp.si_note, 0); } } diff --git a/sys/dev/misc/nmdm/nmdm.c b/sys/dev/misc/nmdm/nmdm.c index 7bd4375b3f..f07a9219ea 100644 --- a/sys/dev/misc/nmdm/nmdm.c +++ b/sys/dev/misc/nmdm/nmdm.c @@ -443,10 +443,12 @@ wakeup_other(struct tty *tp, int flag) if (flag & FREAD) { selwakeup(&otherpart->nm_tty.t_rsel); wakeup(TSA_PTC_READ((&otherpart->nm_tty))); + KNOTE(&otherpart->nm_tty.t_rsel.si_note, 0); } if (flag & FWRITE) { selwakeup(&otherpart->nm_tty.t_wsel); wakeup(TSA_PTC_WRITE((&otherpart->nm_tty))); + KNOTE(&otherpart->nm_tty.t_wsel.si_note, 0); } } diff --git a/sys/dev/misc/psm/psm.c b/sys/dev/misc/psm/psm.c index 3e69ec680c..2e63d76b4c 100644 --- a/sys/dev/misc/psm/psm.c +++ b/sys/dev/misc/psm/psm.c @@ -2378,6 +2378,7 @@ psmintr(void *arg) wakeup((caddr_t) sc); } selwakeup(&sc->rsel); + KNOTE(&sc->rsel.si_note, 0); } } diff --git a/sys/dev/misc/snp/snp.c b/sys/dev/misc/snp/snp.c index de5487a9e0..003f4c5e04 100644 --- a/sys/dev/misc/snp/snp.c +++ b/sys/dev/misc/snp/snp.c @@ -367,6 +367,7 @@ snp_in(struct snoop *snp, char *buf, int n) } selwakeup(&snp->snp_sel); snp->snp_sel.si_pid = 0; + KNOTE(&snp->snp_sel.si_note, 0); return (n); } @@ -440,6 +441,7 @@ snp_detach(struct snoop *snp) detach_notty: selwakeup(&snp->snp_sel); snp->snp_sel.si_pid = 0; + KNOTE(&snp->snp_sel.si_note, 0); if ((snp->snp_flags & SNOOP_OPEN) == 0) kfree(snp, M_SNP); diff --git a/sys/dev/misc/spic/spic.c b/sys/dev/misc/spic/spic.c index 40d5516156..9e1ae0b077 100644 --- a/sys/dev/misc/spic/spic.c +++ b/sys/dev/misc/spic/spic.c @@ -439,6 +439,7 @@ spictimeout(void *arg) wakeup((caddr_t) sc); } selwakeup(&sc->sc_rsel); + KNOTE(&sc->sc_rsel.si_note, 0); } spic_call2(sc, 0x81, 0xff); /* Clear event */ diff --git a/sys/dev/misc/tw/tw.c b/sys/dev/misc/tw/tw.c index 12a1915daf..72d4468c82 100644 --- a/sys/dev/misc/tw/tw.c +++ b/sys/dev/misc/tw/tw.c @@ -883,6 +883,7 @@ twputpkt(struct tw_sc *sc, u_char *p) wakeup((caddr_t)(&sc->sc_buf)); } selwakeup(&sc->sc_selp); + KNOTE(&sc->sc_selp.si_note, 0); return(0); } diff --git a/sys/dev/raid/aac/aac.c b/sys/dev/raid/aac/aac.c index bc4bd1bf88..ec2453e054 100644 --- a/sys/dev/raid/aac/aac.c +++ b/sys/dev/raid/aac/aac.c @@ -3380,6 +3380,7 @@ aac_handle_aif(struct aac_softc *sc, struct aac_fib *fib) /* token may have been lost */ /* Wakeup any poll()ers */ selwakeup(&sc->rcv_select); + KNOTE(&sc->rcv_select.si_note, 0); /* token may have been lost */ } AAC_LOCK_RELEASE(&sc->aac_aifq_lock); diff --git a/sys/dev/serial/stl/stallion.c b/sys/dev/serial/stl/stallion.c index 4fa3d6d054..460fd57df9 100644 --- a/sys/dev/serial/stl/stallion.c +++ b/sys/dev/serial/stl/stallion.c @@ -1635,6 +1635,7 @@ static void stl_start(struct tty *tp) wakeup(&tp->t_outq); } selwakeup(&tp->t_wsel); + KNOTE(&tp->t_wsel.si_note, 0); } #endif diff --git a/sys/dev/serial/stli/istallion.c b/sys/dev/serial/stli/istallion.c index ddde4099bf..6500412d44 100644 --- a/sys/dev/serial/stli/istallion.c +++ b/sys/dev/serial/stli/istallion.c @@ -1671,6 +1671,7 @@ static void stli_start(struct tty *tp) wakeup(&tp->t_outq); } selwakeup(&tp->t_wsel); + KNOTE(&tp->t_wsel.si_note, 0); } #endif diff --git a/sys/dev/sound/pcm/buffer.c b/sys/dev/sound/pcm/buffer.c index 1581806c97..a6ae30824d 100644 --- a/sys/dev/sound/pcm/buffer.c +++ b/sys/dev/sound/pcm/buffer.c @@ -45,8 +45,10 @@ static void sndbuf_seltask(void *context, int pending) { struct snd_dbuf *b = context; + struct selinfo *si = sndbuf_getsel(b); - selwakeup(sndbuf_getsel(b)); + selwakeup(si); + KNOTE(&si->si_note, 0); } struct snd_dbuf * diff --git a/sys/dev/usbmisc/ucom/ucom.c b/sys/dev/usbmisc/ucom/ucom.c index 3500f83156..3df457e17f 100644 --- a/sys/dev/usbmisc/ucom/ucom.c +++ b/sys/dev/usbmisc/ucom/ucom.c @@ -875,6 +875,7 @@ ucomstart(struct tty *tp) wakeup(TSA_OLOWAT(tp)); } selwakeup(&tp->t_wsel); + KNOTE(&tp->t_wsel.si_note, 0); if (tp->t_outq.c_cc == 0) { if (ISSET(tp->t_state, TS_BUSY | TS_SO_OCOMPLETE) == TS_SO_OCOMPLETE && tp->t_outq.c_cc == 0) { diff --git a/sys/dev/usbmisc/ugen/ugen.c b/sys/dev/usbmisc/ugen/ugen.c index 58f2d0ec03..4f02193a78 100644 --- a/sys/dev/usbmisc/ugen/ugen.c +++ b/sys/dev/usbmisc/ugen/ugen.c @@ -915,6 +915,7 @@ ugen_detach(device_t self) if (sce && sce->pipeh) usbd_abort_pipe(sce->pipeh); selwakeup(&sce->rsel); + KNOTE(&sce->rsel.si_note, 0); } } crit_enter(); @@ -969,6 +970,7 @@ ugenintr(usbd_xfer_handle xfer, usbd_private_handle addr, usbd_status status) wakeup(sce); } selwakeup(&sce->rsel); + KNOTE(&sce->rsel.si_note, 0); } static void @@ -1029,6 +1031,7 @@ ugen_isoc_rintr(usbd_xfer_handle xfer, usbd_private_handle addr, wakeup(sce); } selwakeup(&sce->rsel); + KNOTE(&sce->rsel.si_note, 0); } static usbd_status diff --git a/sys/dev/usbmisc/uhid/uhid.c b/sys/dev/usbmisc/uhid/uhid.c index 16243e8504..a49a36d4f4 100644 --- a/sys/dev/usbmisc/uhid/uhid.c +++ b/sys/dev/usbmisc/uhid/uhid.c @@ -334,6 +334,7 @@ uhid_intr(usbd_xfer_handle xfer, usbd_private_handle addr, usbd_status status) wakeup(&sc->sc_q); } selwakeup(&sc->sc_rsel); + KNOTE(&sc->sc_rsel.si_note, 0); if (sc->sc_async != NULL) { DPRINTFN(3, ("uhid_intr: sending SIGIO %p\n", sc->sc_async)); ksignal(sc->sc_async, SIGIO); diff --git a/sys/dev/video/bktr/bktr_core.c b/sys/dev/video/bktr/bktr_core.c index 47228268b9..40492ad131 100644 --- a/sys/dev/video/bktr/bktr_core.c +++ b/sys/dev/video/bktr/bktr_core.c @@ -717,7 +717,7 @@ common_bktr_intr( void *arg ) if (bktr->vbi_select.si_pid) { selwakeup(&bktr->vbi_select); } - + KNOTE(&bktr->vbi_select.si_note, 0); } UNLOCK_VBI(bktr); diff --git a/sys/dev/video/cxm/cxm.c b/sys/dev/video/cxm/cxm.c index cac3903d47..1c608cc7c9 100644 --- a/sys/dev/video/cxm/cxm.c +++ b/sys/dev/video/cxm/cxm.c @@ -1371,6 +1371,7 @@ cxm_encoder_dma_done(struct cxm_softc *sc) /* wakeup anyone polling for data */ selwakeup(&sc->enc_sel); + KNOTE(&sc->enc_sel.si_note, 0); } diff --git a/sys/kern/kern_udev.c b/sys/kern/kern_udev.c index 010bebfa99..fe1339d157 100644 --- a/sys/kern/kern_udev.c +++ b/sys/kern/kern_udev.c @@ -423,6 +423,7 @@ udev_event_insert(int ev_type, prop_dictionary_t dict) wakeup(&udevctx); selwakeup(&udevctx.sel); + KNOTE(&udevctx.sel.si_note, 0); } static struct udev_event_kernel * diff --git a/sys/kern/subr_bus.c b/sys/kern/subr_bus.c index 534b7aa5c2..baff226040 100644 --- a/sys/kern/subr_bus.c +++ b/sys/kern/subr_bus.c @@ -368,6 +368,7 @@ devctl_queue_data(char *data) lockmgr(&devsoftc.lock, LK_RELEASE); get_mplock(); /* XXX */ selwakeup(&devsoftc.sel); + KNOTE(&devsoftc.sel.si_note, 0); rel_mplock(); /* XXX */ p = devsoftc.async_proc; if (p != NULL) diff --git a/sys/kern/subr_log.c b/sys/kern/subr_log.c index 46ac56e3f3..6de6e59daf 100644 --- a/sys/kern/subr_log.c +++ b/sys/kern/subr_log.c @@ -224,6 +224,7 @@ logtimeout(void *arg) } msgbuftrigger = 0; selwakeup(&logsoftc.sc_selp); + KNOTE(&logsoftc.sc_selp.si_note, 0); if ((logsoftc.sc_state & LOG_ASYNC) && logsoftc.sc_sigio != NULL) pgsigio(logsoftc.sc_sigio, SIGIO, 0); if (logsoftc.sc_state & LOG_RDWAIT) { diff --git a/sys/kern/sys_mqueue.c b/sys/kern/sys_mqueue.c index 56ba8af3d1..61da303d3d 100644 --- a/sys/kern/sys_mqueue.c +++ b/sys/kern/sys_mqueue.c @@ -638,6 +638,7 @@ mq_receive1(struct lwp *l, mqd_t mqdes, void *msg_ptr, size_t msg_len, /* Ready for sending now */ get_mplock(); selwakeup(&mq->mq_wsel); + KNOTE(&mq->mq_wsel.si_note, 0); rel_mplock(); error: lockmgr(&mq->mq_mtx, LK_RELEASE); @@ -829,6 +830,7 @@ mq_send1(struct lwp *l, mqd_t mqdes, const char *msg_ptr, size_t msg_len, /* Ready for receiving now */ get_mplock(); selwakeup(&mq->mq_rsel); + KNOTE(&mq->mq_rsel.si_note, 0); rel_mplock(); error: lockmgr(&mq->mq_mtx, LK_RELEASE); @@ -1055,6 +1057,8 @@ sys_mq_unlink(struct mq_unlink_args *uap) get_mplock(); selwakeup(&mq->mq_rsel); selwakeup(&mq->mq_wsel); + KNOTE(&mq->mq_rsel.si_note, 0); + KNOTE(&mq->mq_wsel.si_note, 0); rel_mplock(); refcnt = mq->mq_refcnt; diff --git a/sys/net/bpf.c b/sys/net/bpf.c index 456ca3bf17..e5ba0fa090 100644 --- a/sys/net/bpf.c +++ b/sys/net/bpf.c @@ -522,6 +522,7 @@ bpf_wakeup(struct bpf_d *d) get_mplock(); selwakeup(&d->bd_sel); + KNOTE(&d->bd_sel.si_note, 0); rel_mplock(); /* XXX */ d->bd_sel.si_pid = 0; diff --git a/sys/net/i4b/driver/i4b_rbch.c b/sys/net/i4b/driver/i4b_rbch.c index bb6db28004..7a3956b847 100644 --- a/sys/net/i4b/driver/i4b_rbch.c +++ b/sys/net/i4b/driver/i4b_rbch.c @@ -813,6 +813,7 @@ rbch_rx_data_rdy(int unit) NDBGL4(L4_RBCHDBG, "unit %d, NO wakeup", unit); } selwakeup(&rbch_softc[unit].selp); + KNOTE(&rbch_softc[unit].selp.si_note, 0); } /*---------------------------------------------------------------------------* @@ -834,6 +835,7 @@ rbch_tx_queue_empty(int unit) NDBGL4(L4_RBCHDBG, "unit %d, NO wakeup", unit); } selwakeup(&rbch_softc[unit].selp); + KNOTE(&rbch_softc[unit].selp.si_note, 0); } /*---------------------------------------------------------------------------* @@ -846,6 +848,7 @@ rbch_activity(int unit, int rxtx) if (rbch_softc[unit].sc_cd) rbch_softc[unit].sc_cd->last_active_time = SECOND; selwakeup(&rbch_softc[unit].selp); + KNOTE(&rbch_softc[unit].selp.si_note, 0); } /*---------------------------------------------------------------------------* diff --git a/sys/net/i4b/driver/i4b_tel.c b/sys/net/i4b/driver/i4b_tel.c index b9b5a6783d..7b276d527c 100644 --- a/sys/net/i4b/driver/i4b_tel.c +++ b/sys/net/i4b/driver/i4b_tel.c @@ -854,6 +854,7 @@ tel_connect(int unit, void *cdp) wakeup((caddr_t) &sc->result); } selwakeup(&sc->selp); + KNOTE(&sc->selp.si_note, 0); } } @@ -897,6 +898,7 @@ tel_disconnect(int unit, void *cdp) wakeup((caddr_t) &sc->result); } selwakeup(&sc->selp); + KNOTE(&sc->selp.si_note, 0); if (sc->devstate & ST_TONE) { sc->devstate &= ~ST_TONE; @@ -925,6 +927,7 @@ tel_dialresponse(int unit, int status, cause_t cause) wakeup((caddr_t) &sc->result); } selwakeup(&sc->selp); + KNOTE(&sc->selp.si_note, 0); } } @@ -952,6 +955,7 @@ tel_rx_data_rdy(int unit) wakeup((caddr_t) &sc->isdn_linktab->rx_queue); } selwakeup(&sc->selp); + KNOTE(&sc->selp.si_note, 0); } /*---------------------------------------------------------------------------* @@ -973,6 +977,7 @@ tel_tx_queue_empty(int unit) tel_tone(sc); } else { selwakeup(&sc->selp); + KNOTE(&sc->selp.si_note, 0); } } diff --git a/sys/net/i4b/layer4/i4b_i4bdrv.c b/sys/net/i4b/layer4/i4b_i4bdrv.c index 2577f44070..6dbf67f05c 100644 --- a/sys/net/i4b/layer4/i4b_i4bdrv.c +++ b/sys/net/i4b/layer4/i4b_i4bdrv.c @@ -830,6 +830,7 @@ i4bputqueue(struct mbuf *m) } selwakeup(&select_rd_info); + KNOTE(&select_rd_info.si_note, 0); } /*---------------------------------------------------------------------------* @@ -865,6 +866,7 @@ i4bputqueue_hipri(struct mbuf *m) } selwakeup(&select_rd_info); + KNOTE(&select_rd_info.si_note, 0); } #endif /* NI4B > 0 */ diff --git a/sys/net/tap/if_tap.c b/sys/net/tap/if_tap.c index d22362516b..732c64dc9d 100644 --- a/sys/net/tap/if_tap.c +++ b/sys/net/tap/if_tap.c @@ -429,6 +429,7 @@ tapclose(struct dev_close_args *ap) funsetown(tp->tap_sigio); tp->tap_sigio = NULL; selwakeup(&tp->tap_rsel); + KNOTE(&tp->tap_rsel.si_note, 0); tp->tap_flags &= ~TAP_OPEN; funsetown(tp->tap_sigtd); diff --git a/sys/net/tun/if_tun.c b/sys/net/tun/if_tun.c index 8f6ab099a4..c72ad37ccb 100644 --- a/sys/net/tun/if_tun.c +++ b/sys/net/tun/if_tun.c @@ -219,6 +219,7 @@ tunclose(struct dev_close_args *ap) funsetown(tp->tun_sigio); selwakeup(&tp->tun_rsel); + KNOTE(&tp->tun_rsel.si_note, 0); TUNDEBUG(ifp, "closed\n"); #if 0 @@ -398,6 +399,7 @@ tunoutput_serialized(struct ifnet *ifp, struct mbuf *m0, struct sockaddr *dst, if (tp->tun_flags & TUN_ASYNC && tp->tun_sigio) pgsigio(tp->tun_sigio, SIGIO, 0); selwakeup(&tp->tun_rsel); + KNOTE(&tp->tun_rsel.si_note, 0); rel_mplock(); } return (error); @@ -797,5 +799,6 @@ tunstart(struct ifnet *ifp) if (tp->tun_flags & TUN_ASYNC && tp->tun_sigio) pgsigio(tp->tun_sigio, SIGIO, 0); selwakeup(&tp->tun_rsel); + KNOTE(&tp->tun_rsel.si_note, 0); } } diff --git a/sys/platform/pc32/apm/apm.c b/sys/platform/pc32/apm/apm.c index e4c0980b07..97775b247d 100644 --- a/sys/platform/pc32/apm/apm.c +++ b/sys/platform/pc32/apm/apm.c @@ -905,6 +905,7 @@ apm_record_event(struct apm_softc *sc, u_int event_type) evp->type = event_type; evp->index = ++apm_evindex; selwakeup(&sc->sc_rsel); + KNOTE(&sc->sc_rsel.si_note, 0); return (sc->sc_flags & SCFLAG_OCTL) ? 0 : 1; /* user may handle */ } diff --git a/sys/platform/pc32/isa/asc.c b/sys/platform/pc32/isa/asc.c index 47421a77f7..b65f6fabf2 100644 --- a/sys/platform/pc32/isa/asc.c +++ b/sys/platform/pc32/isa/asc.c @@ -525,6 +525,7 @@ ascintr(void *arg) scu->selp.si_pid=(pid_t)0; scu->selp.si_flags = 0; } + KNOTE(&scu->selp.si_note, 0); } } diff --git a/sys/platform/pc64/apm/apm.c b/sys/platform/pc64/apm/apm.c index a77e830ee0..5f80ccad88 100644 --- a/sys/platform/pc64/apm/apm.c +++ b/sys/platform/pc64/apm/apm.c @@ -905,6 +905,7 @@ apm_record_event(struct apm_softc *sc, u_int event_type) evp->type = event_type; evp->index = ++apm_evindex; selwakeup(&sc->sc_rsel); + KNOTE(&sc->sc_rsel.si_note, 0); return (sc->sc_flags & SCFLAG_OCTL) ? 0 : 1; /* user may handle */ } diff --git a/sys/platform/pc64/isa/asc.c b/sys/platform/pc64/isa/asc.c index cd2789f574..e8b3c1178b 100644 --- a/sys/platform/pc64/isa/asc.c +++ b/sys/platform/pc64/isa/asc.c @@ -524,6 +524,7 @@ ascintr(void *arg) scu->selp.si_pid=(pid_t)0; scu->selp.si_flags = 0; } + KNOTE(&scu->selp.si_note, 0); } } -- 2.41.0