Re: Query about bhyve's blockif_cancel and the signalling mechanisms

2016-12-14 Thread Ian Campbell via freebsd-virtualization
On 13 December 2016 at 06:32, Peter Grehan wrote: >> I've dug around in the FreeBSD kevent and signal man pages but I >> cannot find any part which describes anything of the semantics which >> bhyve seems to be relying on (which seems to be that the system call >> in the target thread will return

Re: Query about bhyve's blockif_cancel and the signalling mechanisms

2016-12-14 Thread Ian Campbell via freebsd-virtualization
On 14 December 2016 at 00:05, Tycho Nightingale wrote: > On Dec 13, 2016, at 1:32 AM, Peter Grehan wrote: >>> I have a secondary concern which is what happens if the IO thread is >>> on its way to making a blocking system call in blockif_proc but has >>> not actually done so when the signal is de

Re: Query about bhyve's blockif_cancel and the signalling mechanisms

2016-12-13 Thread Tycho Nightingale
Hi, On Dec 13, 2016, at 1:32 AM, Peter Grehan wrote: > Hi Ian, > >> To recap my understanding of the mechanisms at work (glossing over the >> queue handling and condvars involved etc), the bhyve block_if >> infrastructure registers a callback for SIGCONT with the mevent >> subsystem, which is

Re: Query about bhyve's blockif_cancel and the signalling mechanisms

2016-12-12 Thread Peter Grehan
Hi Ian, To recap my understanding of the mechanisms at work (glossing over the queue handling and condvars involved etc), the bhyve block_if infrastructure registers a callback for SIGCONT with the mevent subsystem, which is a kevent/kqueue thing which delivers events to the main thread (mevent_