On Wed, Apr 13, 2016 at 5:31 PM, Taylor R Campbell <campbell+netbsd-source-change...@mumble.net> wrote: > Date: Wed, 13 Apr 2016 16:46:17 +0900 > From: Ryota Ozaki <ozak...@netbsd.org> > > I'm trying to apply psref to bridge(4) and it's mostly done (*). > > Nice! I'll take a look when I have some time.
Thanks! > > However, I have an issue; I got a KASSERT failure in psref_held > with the following output (I added thread names to the KASSERTMSG > for debugging): > > panic: kernel diagnostic assertion "(psref->psref_lwp == curlwp)" > [...] > > It seems that the assertion depends on a xcall handler > runs on a lwp that holds a reference to a target object, > however, in reality the xcall handler runs on its own lwp. > > I think the assertion is invalid and we should get rid of it. > Am I correct? > > Not quite. The assertion is correct for all other uses of psref_held, > just not the one internal use of it. I split it into a separate local > subroutine. I see. The new one should work for me (I'll test later). Thanks, ozaki-r