Date: Wed, 10 Aug 2016 15:24:16 +0000 (UTC) From: Mateusz Guzik <mjg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r303921 - head/sys/kern Message-ID: <201608101524.u7AFOGW7015920@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mjg Date: Wed Aug 10 15:24:15 2016 New Revision: 303921 URL: https://svnweb.freebsd.org/changeset/base/303921 Log: sigio: do a lockless check in funsetownlist There is no need to grab the lock first to see if sigio is used, and it typically is not. Modified: head/sys/kern/kern_descrip.c Modified: head/sys/kern/kern_descrip.c ============================================================================== --- head/sys/kern/kern_descrip.c Wed Aug 10 15:16:28 2016 (r303920) +++ head/sys/kern/kern_descrip.c Wed Aug 10 15:24:15 2016 (r303921) @@ -942,6 +942,8 @@ funsetown(struct sigio **sigiop) { struct sigio *sigio; + if (*sigiop == NULL) + return; SIGIO_LOCK(); sigio = *sigiop; if (sigio == NULL) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608101524.u7AFOGW7015920>