Date: Wed, 7 Sep 2016 23:36:47 +0000 (UTC) From: Oleksandr Tymoshenko <gonzo@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r305572 - stable/11/sys/arm/ti Message-ID: <201609072336.u87NaljN033417@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: gonzo Date: Wed Sep 7 23:36:46 2016 New Revision: 305572 URL: https://svnweb.freebsd.org/changeset/base/305572 Log: MFC r305492: 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: stable/11/sys/arm/ti/ti_pruss.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/arm/ti/ti_pruss.c ============================================================================== --- stable/11/sys/arm/ti/ti_pruss.c Wed Sep 7 23:35:38 2016 (r305571) +++ stable/11/sys/arm/ti/ti_pruss.c Wed Sep 7 23:36:46 2016 (r305572) @@ -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);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201609072336.u87NaljN033417>