Author: gonzo Date: Tue Sep 6 19:36:28 2016 New Revision: 305492 URL: https://svnweb.freebsd.org/changeset/base/305492
Log: Let knlist_add do the locking part Remove explicit mtx_lock/mtx_unlock around knlist_add and pass 0 as locked parameter so knlist_add does the locking itself Suggested by: kib@ Modified: head/sys/arm/ti/ti_pruss.c Modified: head/sys/arm/ti/ti_pruss.c ============================================================================== --- head/sys/arm/ti/ti_pruss.c Tue Sep 6 19:29:14 2016 (r305491) +++ head/sys/arm/ti/ti_pruss.c Tue Sep 6 19:36:28 2016 (r305492) @@ -310,9 +310,7 @@ ti_pruss_kqfilter(struct cdev *cdev, str case EVFILT_READ: kn->kn_hook = sc; kn->kn_fop = &ti_pruss_kq_read; - mtx_lock(&sc->sc_mtx); - knlist_add(&sc->sc_selinfo.si_note, kn, 1); - mtx_unlock(&sc->sc_mtx); + knlist_add(&sc->sc_selinfo.si_note, kn, 0); break; default: return (EINVAL); _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"