On 5/10/2018 10:55 AM, Matt Macy wrote: > Author: mmacy > Date: Thu May 10 17:55:24 2018 > New Revision: 333466 > URL: https://svnweb.freebsd.org/changeset/base/333466 > > Log: > Add simple preempt safe epoch API > > Read locking is over used in the kernel to guarantee liveness. This API > makes > it easy to provide livenes guarantees without atomics. > > Includes epoch_test kernel module to stress test the API. > > Documentation will follow initial use case. > > Test case and improvements to preemption handling in response to discussion > with mjg@ > > Reviewed by: imp@, shurd@ > Approved by: sbruno@ > > Added: > head/sys/kern/subr_epoch.c (contents, props changed) > head/sys/modules/epoch_test/ > head/sys/modules/epoch_test/Makefile (contents, props changed) > head/sys/sys/epoch.h (contents, props changed) > head/sys/tests/epoch/ > head/sys/tests/epoch/epoch_test.c (contents, props changed) > Modified: > head/contrib/bmake/job.c > head/sys/conf/files > head/sys/conf/kern.pre.mk > head/sys/kern/kern_malloc.c > head/sys/kern/kern_synch.c > head/sys/kern/subr_trap.c > head/sys/kern/subr_turnstile.c > head/sys/sys/proc.h > head/sys/sys/turnstile.h > > Modified: head/contrib/bmake/job.c > ============================================================================== > --- head/contrib/bmake/job.c Thu May 10 17:22:04 2018 (r333465) > +++ head/contrib/bmake/job.c Thu May 10 17:55:24 2018 (r333466) > @@ -2121,13 +2121,15 @@ Job_CatchOutput(void) > { > int nready; > Job *job; > - int i; > + int i, pollToken; > > (void)fflush(stdout); > > + pollToken = 0; > + > /* The first fd in the list is the job token pipe */ > do { > - nready = poll(fds + 1 - wantToken, nfds - 1 + wantToken, POLL_MSEC); > + nready = poll(fds + 1 - pollToken, nfds - 1 + pollToken, POLL_MSEC); > } while (nready < 0 && errno == EINTR); > > if (nready < 0)
What's up with this? -- Regards, Bryan Drewery
signature.asc
Description: OpenPGP digital signature