[ofw] patch: Fix a race in the cl_timer code that caused deadlocks in opensm

Hefty, Sean sean.hefty at intel.com
Wed Jun 23 11:55:17 PDT 2010


> Forgot to mention, you should use the cb_serialize lock to protect setting
> the thread ID too.

The thread ID needs to be protected using 'spinlock', since that lock is held when reading it later.  Or maybe cb_serialize would work, as long as thread_id is cleared after the callback returns...

Actually, I think setting thread_id = 0 is required, since its purpose is to see if timer_stop is being called from the callback.



More information about the ofw mailing list