diff options
author | Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br> | 2007-10-17 12:04:41 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@inhelltoy.tec.linutronix.de> | 2007-10-17 14:17:05 -0400 |
commit | de8aacbe6a3f3dd7104da09a5535232cd385fdd6 (patch) | |
tree | 89c6dc0070ab30b4e6ecaa6269bfd54320a400c7 /arch/x86/kernel/ptrace_32.c | |
parent | 32c464f5d9701db45bc1673288594e664065388e (diff) |
x86: convert mm_context_t semaphore to a mutex
convert mm_context_t semaphore to a mutex.
Signed-off-by: Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br>
Cc: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/ptrace_32.c')
-rw-r--r-- | arch/x86/kernel/ptrace_32.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kernel/ptrace_32.c b/arch/x86/kernel/ptrace_32.c index 8622b9cd3e38..99102ec5fade 100644 --- a/arch/x86/kernel/ptrace_32.c +++ b/arch/x86/kernel/ptrace_32.c | |||
@@ -165,7 +165,7 @@ static unsigned long convert_eip_to_linear(struct task_struct *child, struct pt_ | |||
165 | 165 | ||
166 | seg &= ~7UL; | 166 | seg &= ~7UL; |
167 | 167 | ||
168 | down(&child->mm->context.sem); | 168 | mutex_lock(&child->mm->context.lock); |
169 | if (unlikely((seg >> 3) >= child->mm->context.size)) | 169 | if (unlikely((seg >> 3) >= child->mm->context.size)) |
170 | addr = -1L; /* bogus selector, access would fault */ | 170 | addr = -1L; /* bogus selector, access would fault */ |
171 | else { | 171 | else { |
@@ -179,7 +179,7 @@ static unsigned long convert_eip_to_linear(struct task_struct *child, struct pt_ | |||
179 | addr &= 0xffff; | 179 | addr &= 0xffff; |
180 | addr += base; | 180 | addr += base; |
181 | } | 181 | } |
182 | up(&child->mm->context.sem); | 182 | mutex_unlock(&child->mm->context.lock); |
183 | } | 183 | } |
184 | return addr; | 184 | return addr; |
185 | } | 185 | } |