Re: Raise spl for updating kn_status

2020-02-16 Thread Visa Hankala
On Sat, Feb 15, 2020 at 09:42:53PM +0100, Martin Pieuchot wrote: > On 15/02/20(Sat) 16:56, Visa Hankala wrote: > > When I added the knote_acquire() call in kqueue_register(), I overlooked > > the fact that the knote could be modified by a (soft) interrupt. > > Interrupts have to be blocked when

Re: Raise spl for updating kn_status

2020-02-15 Thread Martin Pieuchot
On 15/02/20(Sat) 16:56, Visa Hankala wrote: > When I added the knote_acquire() call in kqueue_register(), I overlooked > the fact that the knote could be modified by a (soft) interrupt. > Interrupts have to be blocked when changing kn_status. Otherwise the > state could become confused. Can the

Raise spl for updating kn_status

2020-02-15 Thread Visa Hankala
When I added the knote_acquire() call in kqueue_register(), I overlooked the fact that the knote could be modified by a (soft) interrupt. Interrupts have to be blocked when changing kn_status. Otherwise the state could become confused. The diff below adds splhigh() where kn_status is modified.