Changeset 4512d7e in mainline for arch/sparc64/src/mm/tlb.c


Ignore:
Timestamp:
2006-01-19T22:17:47Z (19 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
6461d67c
Parents:
64c44e8
Message:

New ASID management subsystem (initial work, more is required).
Some TLB invalidation changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • arch/sparc64/src/mm/tlb.c

    r64c44e8 r4512d7e  
    166166}
    167167
    168 /** Invalidate all ITLB and DLTB entries for specified page in specified address space.
     168/** Invalidate all ITLB and DTLB entries for specified page range in specified address space.
    169169 *
    170170 * @param asid Address Space ID.
    171  * @param page Page which to sweep out from ITLB and DTLB.
     171 * @param page First page which to sweep out from ITLB and DTLB.
     172 * @param cnt Number of ITLB and DTLB entries to invalidate.
    172173 */
    173 void tlb_invalidate_page(asid_t asid, __address page)
     174void tlb_invalidate_pages(asid_t asid, __address page, count_t cnt)
    174175{
    175         /* TODO: write asid to some Context register and encode the register in second parameter below. */
    176         itlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, page);
    177         dtlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, page);
     176        int i;
     177       
     178        for (i = 0; i < cnt; i++) {
     179                /* TODO: write asid to some Context register and encode the register in second parameter below. */
     180                itlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, page + i * PAGE_SIZE);
     181                dtlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, page + i * PAGE_SIZE);
     182        }
    178183}
Note: See TracChangeset for help on using the changeset viewer.