:Thanks. Regarding MP Lock, i was actually going through lwkt_switch() function
:in lwkt_thread.c. there mpheld is used and MP_LOCK_HELD()assign value to that 
variable. The 
:paragraph above it tries to explain it, but it confused me.
:
:So i was asking when MP Lock comes into play? when to check if mp lock is held 
or not and so on.
:
:--Mayur

    That's code you will only see in the lwkt_switch() code, and nowhere
    else.  The lwkt_switch code has to match up the actual state of the MP
    lock against the state recorded in the thread it is switching into.

    In all other code the actual state of the MP lock will match the state
    recorded in the thread (as part of td_pri).

                                        -Matt
                                        Matthew Dillon 
                                        <[EMAIL PROTECTED]>

Reply via email to