Sorry, haven't had time yet to do a full review, but I spot at least one problem that means this won't fly as is: kqueue_register and kqueue_scan both call filter_touch under a spin lock, but with your patch filter_touch now takes an rwlock -- which is forbidden under a spin lock (and it'll crash under LOCKDEBUG).
- Problem with outstanding knotes and device detach - and ... Jason Thorpe
- Re: Problem with outstanding knotes and device deta... Jason Thorpe
- Re: Problem with outstanding knotes and device ... Jason Thorpe
- Re: Problem with outstanding knotes and device deta... Jason Thorpe
- Re: Problem with outstanding knotes and device deta... Taylor R Campbell
- Re: Problem with outstanding knotes and device ... Jason Thorpe
- Re: Problem with outstanding knotes and dev... Jason Thorpe
- Re: Problem with outstanding knotes and... Jason Thorpe
- Re: Problem with outstanding knote... Taylor R Campbell
- Re: Problem with outstanding k... Jason Thorpe