Changeset b4ca0a9c in mainline for kernel/generic/src/mm/as.c


Ignore:
Timestamp:
2012-07-10T11:53:50Z (12 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
1e01a35
Parents:
a33706e (diff), 33fc3ae (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/mm/as.c

    ra33706e rb4ca0a9c  
    130130        as_arch_init();
    131131       
    132         as_slab = slab_cache_create("as_slab", sizeof(as_t), 0,
     132        as_slab = slab_cache_create("as_t", sizeof(as_t), 0,
    133133            as_constructor, as_destructor, SLAB_CACHE_MAGDEFERRED);
    134134       
     
    665665               
    666666                page_table_lock(as, false);
    667                
    668                 /*
    669                  * Start TLB shootdown sequence.
    670                  */
    671                 ipl_t ipl = tlb_shootdown_start(TLB_INVL_PAGES, as->asid,
    672                     area->base + P2SZ(pages), area->pages - pages);
    673667               
    674668                /*
     
    726720                                }
    727721                               
     722                                /*
     723                                 * Start TLB shootdown sequence.
     724                                 *
     725                                 * The sequence is rather short and can be
     726                                 * repeated multiple times. The reason is that
     727                                 * we don't want to have used_space_remove()
     728                                 * inside the sequence as it may use a blocking
     729                                 * memory allocation for its B+tree. Blocking
     730                                 * while holding the tlblock spinlock is
     731                                 * forbidden and would hit a kernel assertion.
     732                                 */
     733
     734                                ipl_t ipl = tlb_shootdown_start(TLB_INVL_PAGES,
     735                                    as->asid, area->base + P2SZ(pages),
     736                                    area->pages - pages);
     737               
    728738                                for (; i < size; i++) {
    729739                                        pte_t *pte = page_mapping_find(as,
     
    743753                                        page_mapping_remove(as, ptr + P2SZ(i));
    744754                                }
     755               
     756                                /*
     757                                 * Finish TLB shootdown sequence.
     758                                 */
     759               
     760                                tlb_invalidate_pages(as->asid,
     761                                    area->base + P2SZ(pages),
     762                                    area->pages - pages);
     763               
     764                                /*
     765                                 * Invalidate software translation caches
     766                                 * (e.g. TSB on sparc64, PHT on ppc32).
     767                                 */
     768                                as_invalidate_translation_cache(as,
     769                                    area->base + P2SZ(pages),
     770                                    area->pages - pages);
     771                                tlb_shootdown_finalize(ipl);
    745772                        }
    746773                }
    747                
    748                 /*
    749                  * Finish TLB shootdown sequence.
    750                  */
    751                
    752                 tlb_invalidate_pages(as->asid, area->base + P2SZ(pages),
    753                     area->pages - pages);
    754                
    755                 /*
    756                  * Invalidate software translation caches
    757                  * (e.g. TSB on sparc64, PHT on ppc32).
    758                  */
    759                 as_invalidate_translation_cache(as, area->base + P2SZ(pages),
    760                     area->pages - pages);
    761                 tlb_shootdown_finalize(ipl);
    762                
    763774                page_table_unlock(as, false);
    764775        } else {
Note: See TracChangeset for help on using the changeset viewer.