Looks good. I apologize to weijin and ming_zym for being too distracted to look closely at those even though I meant to do so. Not being able to replicate the problem even on old code bases made it problematic as well.
Sunday, March 25, 2012, 5:56:01 PM, you wrote: > I found the problem and it has nothing to do with any of this. The > problem, as quite rightly pointed out by weijin is that when the closed > flag by one thread, another thread can delete the NetVC. This is expected > and desirable, however, unfortunately do_io_close() is accessing the "nh" > variable (which happens to be in the NetVC), and it is dereferencing it to > get the mutex to check to see if it is running in the same thread as the > NetVC and it is doing so after the closed flag is set. > The simple solution is to move the read of nh->mutex->thread_holding above > the setting of "closed". > Please see patch TS-857-jp1.patch attached to TS-857.