diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-02 07:46:41 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-02 07:46:41 -0700 |
commit | 4c61f72c72e0e1181f91831f106c5f7306238706 (patch) | |
tree | 448350a5bf4a8b53417cfa97ad234be05c2a4590 /arch/sparc64/mm/tlb.c | |
parent | 2f819ae8816990aaad46dd6d1748a096d136df68 (diff) | |
parent | c819914e0d5cc85cccf5fe7542fcb9586286bc28 (diff) | |
download | op-kernel-dev-4c61f72c72e0e1181f91831f106c5f7306238706.zip op-kernel-dev-4c61f72c72e0e1181f91831f106c5f7306238706.tar.gz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
sparc64: remove unused calc_npages() in iommu_common.h
sparc64: add the segment boundary checking to IOMMUs while merging SG entries
[SPARC64]: Don't open-code {get,put}_cpu_var() in flush_tlb_pending().
Diffstat (limited to 'arch/sparc64/mm/tlb.c')
-rw-r--r-- | arch/sparc64/mm/tlb.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/arch/sparc64/mm/tlb.c b/arch/sparc64/mm/tlb.c index a0f000b..ae24919 100644 --- a/arch/sparc64/mm/tlb.c +++ b/arch/sparc64/mm/tlb.c @@ -23,11 +23,8 @@ DEFINE_PER_CPU(struct mmu_gather, mmu_gathers) = { 0, }; void flush_tlb_pending(void) { - struct mmu_gather *mp; + struct mmu_gather *mp = &get_cpu_var(mmu_gathers); - preempt_disable(); - - mp = &__get_cpu_var(mmu_gathers); if (mp->tlb_nr) { flush_tsb_user(mp); @@ -43,7 +40,7 @@ void flush_tlb_pending(void) mp->tlb_nr = 0; } - preempt_enable(); + put_cpu_var(mmu_gathers); } void tlb_batch_add(struct mm_struct *mm, unsigned long vaddr, pte_t *ptep, pte_t orig) |