== model: buggy detach, foreign list empty == [empty] knote inserted on rkq only (midi.c:911-916); wkq empty=1 [empty] calling buggy midi_filter_detach()... [empty] SIGSEGV at faulting address 0x0 (kernel equivalent: page fault on unmapped low page => panic) exit=99 == model: buggy detach, foreign list holds a peer knote == [peer] knote inserted on rkq only (midi.c:911-916); wkq empty=1 [peer] peer knote inserted on wkq (different knote!) [peer] calling buggy midi_filter_detach()... [peer] SIGSEGV at faulting address 0x0 (kernel equivalent: page fault on unmapped low page => panic) exit=99 == model: fixed detach (fix.diff semantics) == [fixed] knote inserted on rkq only (midi.c:911-916); wkq empty=1 [fixed] calling fixed detach_read()... [fixed] clean: knote removed from its owning list, no foreign-list walk exit=0 == model: control (membership holds) == [control] knote inserted on rkq only (midi.c:911-916); wkq empty=1 [control] control ok exit=0 == live guest: kevent add/delete mechanics on /dev/midistat == kevent add: Operation not supported by device EV_ADD EVFILT_READ on /dev/midistat -> -1 EV_DELETE EVFILT_READ -> -1 (filter detach invoked) close(kq) with attached knote (kqueue_terminate path) done TRIGGER-MECHANICS-OK on /dev/midistat (guest still alive) exit=0