aboutsummaryrefslogtreecommitdiff
path: root/arch/s390/include/asm/tlbflush.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-08-24 10:43:08 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2010-08-24 10:43:08 -0700
commitf4e385ccfc10f44364101b126d1ac52b4c806f1d (patch)
tree05b8d1c55900e46d034cf11809ef9990ec48cdae /arch/s390/include/asm/tlbflush.h
parent32e2f63bcc8903487975506d8db5931a8c4bbb1f (diff)
parent050eef364ad700590a605a0749f825cab4834b1e (diff)
Merge branch 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6
* 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6: [S390] fix tlb flushing vs. concurrent /proc accesses [S390] s390: fix build error (sys_execve)
Diffstat (limited to 'arch/s390/include/asm/tlbflush.h')
-rw-r--r--arch/s390/include/asm/tlbflush.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/arch/s390/include/asm/tlbflush.h b/arch/s390/include/asm/tlbflush.h
index 304cffa623e..29d5d6d4bec 100644
--- a/arch/s390/include/asm/tlbflush.h
+++ b/arch/s390/include/asm/tlbflush.h
@@ -94,8 +94,12 @@ static inline void __tlb_flush_mm(struct mm_struct * mm)
static inline void __tlb_flush_mm_cond(struct mm_struct * mm)
{
- if (atomic_read(&mm->mm_users) <= 1 && mm == current->active_mm)
+ spin_lock(&mm->page_table_lock);
+ if (mm->context.flush_mm) {
__tlb_flush_mm(mm);
+ mm->context.flush_mm = 0;
+ }
+ spin_unlock(&mm->page_table_lock);
}
/*