diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-11 22:21:23 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-11 22:21:23 -0400 |
commit | dd6d1844af33acb4edd0a40b1770d091a22c94be (patch) | |
tree | e6bd3549919773a13b770324a4dddb51b194b452 /include/asm-mips/semaphore.h | |
parent | 19f71153b9be219756c6b2757921433a69b7975c (diff) | |
parent | aaf76a3245c02faba51c96b9a340c14d6bb0dcc0 (diff) |
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: (80 commits)
[MIPS] tlbex.c: Cleanup __init usage.
[MIPS] WRPPMC serial support move to platform device
[MIPS] R1: Fix hazard barriers to make kernels work on R2 also.
[MIPS] VPE: reimplement ELF loader.
[MIPS] cleanup WRPPMC include files
[MIPS] Add BUG_ON assertion for attempt to run kernel on the wrong CPU type.
[MIPS] SMP: Use ISO C struct initializer for local structs.
[MIPS] SMP: Kill useless casts.
[MIPS] Kill num_online_cpus() loops.
[MIPS] SMP: Implement smp_call_function_mask().
[MIPS] Make facility to convert CPU types to strings generally available.
[MIPS] Convert list of CPU types from #define to enum.
[MIPS] Optimize get_unaligned / put_unaligned implementations.
[MIPS] checkfiles: Fix "need space after that ','" errors.
[MIPS] Fix "no space between function name and open parenthesis" warnings.
[MIPS] Allow hardwiring of the CPU type to a single type for optimization.
[MIPS] tlbex: Size optimize code by declaring a few functions inline.
[MIPS] pg-r4k.c: Dump the generated code
[MIPS] Cobalt: Remove cobalt_machine_power_off()
[MIPS] Cobalt: Move reset port definition to arch/mips/cobalt/reset.c
...
Diffstat (limited to 'include/asm-mips/semaphore.h')
-rw-r--r-- | include/asm-mips/semaphore.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/include/asm-mips/semaphore.h b/include/asm-mips/semaphore.h index 3d6aa7c7ea81..080daa77f867 100644 --- a/include/asm-mips/semaphore.h +++ b/include/asm-mips/semaphore.h | |||
@@ -46,23 +46,23 @@ struct semaphore { | |||
46 | } | 46 | } |
47 | 47 | ||
48 | #define __DECLARE_SEMAPHORE_GENERIC(name, count) \ | 48 | #define __DECLARE_SEMAPHORE_GENERIC(name, count) \ |
49 | struct semaphore name = __SEMAPHORE_INITIALIZER(name,count) | 49 | struct semaphore name = __SEMAPHORE_INITIALIZER(name, count) |
50 | 50 | ||
51 | #define DECLARE_MUTEX(name) __DECLARE_SEMAPHORE_GENERIC(name, 1) | 51 | #define DECLARE_MUTEX(name) __DECLARE_SEMAPHORE_GENERIC(name, 1) |
52 | #define DECLARE_MUTEX_LOCKED(name) __DECLARE_SEMAPHORE_GENERIC(name, 0) | 52 | #define DECLARE_MUTEX_LOCKED(name) __DECLARE_SEMAPHORE_GENERIC(name, 0) |
53 | 53 | ||
54 | static inline void sema_init (struct semaphore *sem, int val) | 54 | static inline void sema_init(struct semaphore *sem, int val) |
55 | { | 55 | { |
56 | atomic_set(&sem->count, val); | 56 | atomic_set(&sem->count, val); |
57 | init_waitqueue_head(&sem->wait); | 57 | init_waitqueue_head(&sem->wait); |
58 | } | 58 | } |
59 | 59 | ||
60 | static inline void init_MUTEX (struct semaphore *sem) | 60 | static inline void init_MUTEX(struct semaphore *sem) |
61 | { | 61 | { |
62 | sema_init(sem, 1); | 62 | sema_init(sem, 1); |
63 | } | 63 | } |
64 | 64 | ||
65 | static inline void init_MUTEX_LOCKED (struct semaphore *sem) | 65 | static inline void init_MUTEX_LOCKED(struct semaphore *sem) |
66 | { | 66 | { |
67 | sema_init(sem, 0); | 67 | sema_init(sem, 0); |
68 | } | 68 | } |