Ignore:
Timestamp:
Dec 20, 2017, 4:51:09 PM (4 years ago)
Author:
alain
Message:

Fix bugs in exec

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/libk/spinlock.h

    r14 r409  
    5555/*******************************************************************************************
    5656 * This structure defines a local spinlock.
     57 * The "owner" and "list" are optionnal fields used for debug.
     58 * It register the list of all spinlocks taken by a given thread.
    5759 ******************************************************************************************/
    5860
     
    6062{
    6163        uint32_t            taken;             /*! state : free if zero / taken if non zero  */
     64
     65#if CONFIG_LOCKS_DEBUG
    6266        struct thread_s   * owner;             /*! pointer on curent owner thread            */
    63     list_entry_t        list;              /*! list of all locks taken by owner          */
     67    list_entry_t        list;              /*! member of list of locks taken by owner    */
     68#endif
     69
    6470}
    6571spinlock_t;
     
    96102/*******************************************************************************************
    97103 * This blocking function locks a local spinlock.
    98  * If the lock is already taken, the calling thread deschedules and retries when
    99  * it is rescheduled, until success.
     104 * If the lock is already taken, the calling thread deschedules without blocking,
     105 * and retries when it is rescheduled, until success.
    100106 * It increments the calling thread local_locks count when the lock has been taken.
    101107 *******************************************************************************************
Note: See TracChangeset for help on using the changeset viewer.