Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 8d2d308f in mainline


Ignore:
Timestamp:
2012-05-08T10:43:55Z (9 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
master
Children:
8264867, d67dfdc
Parents:
311929ec
Message:

Examine the lock→guard in irq_spinlock_trylock() only when the lock is
successfully acquired.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/synch/spinlock.c

    r311929ec r8d2d308f  
    262262        int rc = spinlock_trylock(&(lock->lock));
    263263       
    264         ASSERT_IRQ_SPINLOCK(!lock->guard, lock);
     264        ASSERT_IRQ_SPINLOCK(!rc || !lock->guard, lock);
    265265        return rc;
    266266}
Note: See TracChangeset for help on using the changeset viewer.