Changeset 771cd22 in mainline for kernel/arch/sparc64/src/mm/as.c


Ignore:
Timestamp:
2006-12-16T19:07:02Z (19 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
7e7c8747
Parents:
1ecdbb0
Message:

Formatting and indentation changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/sparc64/src/mm/as.c

    r1ecdbb0 r771cd22  
    6262{
    6363#ifdef CONFIG_TSB
    64         int order = fnzb32(((ITSB_ENTRY_COUNT+DTSB_ENTRY_COUNT)*sizeof(tsb_entry_t))>>FRAME_WIDTH);
     64        int order = fnzb32(((ITSB_ENTRY_COUNT + DTSB_ENTRY_COUNT) *
     65                sizeof(tsb_entry_t)) >> FRAME_WIDTH);
    6566        uintptr_t tsb = (uintptr_t) frame_alloc(order, flags | FRAME_KA);
    6667
     
    6970
    7071        as->arch.itsb = (tsb_entry_t *) tsb;
    71         as->arch.dtsb = (tsb_entry_t *) (tsb + ITSB_ENTRY_COUNT * sizeof(tsb_entry_t));
    72         memsetb((uintptr_t) as->arch.itsb, (ITSB_ENTRY_COUNT+DTSB_ENTRY_COUNT)*sizeof(tsb_entry_t), 0);
     72        as->arch.dtsb = (tsb_entry_t *) (tsb + ITSB_ENTRY_COUNT *
     73                sizeof(tsb_entry_t));
     74        memsetb((uintptr_t) as->arch.itsb, (ITSB_ENTRY_COUNT + DTSB_ENTRY_COUNT)
     75                * sizeof(tsb_entry_t), 0);
    7376#endif
    7477        return 0;
     
    7881{
    7982#ifdef CONFIG_TSB
    80         count_t cnt = ((ITSB_ENTRY_COUNT+DTSB_ENTRY_COUNT)*sizeof(tsb_entry_t))>>FRAME_WIDTH;
     83        count_t cnt = ((ITSB_ENTRY_COUNT + DTSB_ENTRY_COUNT) *
     84                sizeof(tsb_entry_t)) >> FRAME_WIDTH;
    8185        frame_free(KA2PA((uintptr_t) as->arch.itsb));
    8286        return cnt;
     
    100104}
    101105
    102 /** Perform sparc64-specific tasks when an address space becomes active on the processor.
     106/** Perform sparc64-specific tasks when an address space becomes active on the
     107 * processor.
    103108 *
    104109 * Install ASID and map TSBs.
     
    135140        uintptr_t tsb = (uintptr_t) as->arch.itsb;
    136141               
    137         if (!overlaps(tsb, 8*PAGE_SIZE, base, 1 << KERNEL_PAGE_WIDTH)) {
     142        if (!overlaps(tsb, 8 * PAGE_SIZE, base, 1 << KERNEL_PAGE_WIDTH)) {
    138143                /*
    139144                 * TSBs were allocated from memory not covered
     
    161166}
    162167
    163 /** Perform sparc64-specific tasks when an address space is removed from the processor.
     168/** Perform sparc64-specific tasks when an address space is removed from the
     169 * processor.
    164170 *
    165171 * Demap TSBs.
     
    184190        uintptr_t tsb = (uintptr_t) as->arch.itsb;
    185191               
    186         if (!overlaps(tsb, 8*PAGE_SIZE, base, 1 << KERNEL_PAGE_WIDTH)) {
     192        if (!overlaps(tsb, 8 * PAGE_SIZE, base, 1 << KERNEL_PAGE_WIDTH)) {
    187193                /*
    188194                 * TSBs were allocated from memory not covered
Note: See TracChangeset for help on using the changeset viewer.