kernel: Improve rw_spinlock implementation
* Add more debug checks * Reduce the number of executed instructions that lock the bus.
This commit is contained in:
@@ -100,8 +100,6 @@ release_spinlock_inline(spinlock* lock)
|
||||
#define acquire_spinlock(lock) acquire_spinlock_inline(lock)
|
||||
#define release_spinlock(lock) release_spinlock_inline(lock)
|
||||
|
||||
#endif // !DEBUG_SPINLOCKS && !B_DEBUG_SPINLOCK_CONTENTION
|
||||
|
||||
|
||||
static inline bool
|
||||
try_acquire_write_spinlock_inline(rw_spinlock* lock)
|
||||
@@ -207,4 +205,7 @@ release_read_seqlock_inline(seqlock* lock, uint32 count) {
|
||||
release_read_seqlock_inline(lock, count)
|
||||
|
||||
|
||||
#endif // !DEBUG_SPINLOCKS && !B_DEBUG_SPINLOCK_CONTENTION
|
||||
|
||||
|
||||
#endif /* KERNEL_SMP_H */
|
||||
|
||||
Reference in New Issue
Block a user