Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 10971
b: refs/heads/master
c: e3c4807
h: refs/heads/master
i:
  10969: 394d90e
  10967: 9a3a417
v: v3
  • Loading branch information
Ralf Baechle committed Oct 29, 2005
1 parent b61a092 commit d3cb351
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f638d1971e3135025471c99bf079a24fbb1f3bfa
refs/heads/master: e3c4807825501f0b445fe34b627669be24b59320
12 changes: 12 additions & 0 deletions trunk/include/asm-mips/spinlock.h
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,18 @@ static inline unsigned int __raw_spin_trylock(raw_spinlock_t *lock)
* read-locks.
*/

/*
* read_can_lock - would read_trylock() succeed?
* @lock: the rwlock in question.
*/
#define __raw_read_can_lock(rw) ((rw)->lock >= 0)

/*
* write_can_lock - would write_trylock() succeed?
* @lock: the rwlock in question.
*/
#define __raw_write_can_lock(rw) (!(rw)->lock)

static inline void __raw_read_lock(raw_rwlock_t *rw)
{
unsigned int tmp;
Expand Down

0 comments on commit d3cb351

Please sign in to comment.