Changeset 06e1e95 in mainline for kernel/arch/sparc64


Ignore:
Timestamp:
2006-09-14T17:09:21Z (19 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
f1d1f5d3
Parents:
e5ecc02
Message:

C99 compliant header guards (hopefully) everywhere in the kernel.
Formatting and indentation changes.
Small improvements in sparc64.

Location:
kernel/arch/sparc64
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/sparc64/Makefile.inc

    re5ecc02 r06e1e95  
    7878        DEFS += -DKBD_ADDR_OVRD=0x1fff13083f8ULL
    7979       
    80         DEFS += -DFB_INVERT_COLORS
    8180endif
    8281
  • kernel/arch/sparc64/include/atomic.h

    re5ecc02 r06e1e95  
    5151{
    5252        uint64_t a, b;
    53         volatile uint64_t x = (uint64_t) &val->count;
    5453
    55         __asm__ volatile (
    56                 "0:\n"
    57                 "ldx %0, %1\n"
    58                 "add %1, %3, %2\n"
    59                 "casx %0, %1, %2\n"
    60                 "cmp %1, %2\n"
    61                 "bne 0b\n"              /* The operation failed and must be attempted again if a != b. */
    62                 "nop\n"
    63                 : "=m" (*((uint64_t *)x)), "=r" (a), "=r" (b)
    64                 : "r" (i)
    65         );
     54        do {
     55                volatile uintptr_t x = (uint64_t) &val->count;
     56
     57                a = *((uint64_t *) x);
     58                b = a + i;
     59                __asm__ volatile ("casx %0, %1, %2\n": "+m" (*((uint64_t *)x)), "+r" (a), "+r" (b));
     60        } while (a != b);
    6661
    6762        return a;
  • kernel/arch/sparc64/include/context_offset.h

    re5ecc02 r06e1e95  
    2020#define OFFSET_L7       0x88
    2121#define OFFSET_CLEANWIN 0x98
    22 
  • kernel/arch/sparc64/include/trap/trap_table.h

    re5ecc02 r06e1e95  
    107107/** @}
    108108 */
    109 
  • kernel/arch/sparc64/src/console.c

    re5ecc02 r06e1e95  
    116116#endif
    117117}
     118
    118119/** @}
    119120 */
  • kernel/arch/sparc64/src/mm/as.c

    re5ecc02 r06e1e95  
    6363/** @}
    6464 */
    65 
  • kernel/arch/sparc64/src/mm/page.c

    re5ecc02 r06e1e95  
    9191                order = 0;
    9292        else
    93                 order = (fnzb32(size - 1) + 1) - FRAME_WIDTH;
     93                order = (fnzb64(size - 1) + 1) - FRAME_WIDTH;
    9494
    9595        /*
  • kernel/arch/sparc64/src/trap/syscall.c

    re5ecc02 r06e1e95  
    4343unative_t syscall(int n, istate_t *istate, unative_t a1, unative_t a2, unative_t a3, unative_t a4)
    4444{
    45         if (n >= TT_TRAP_INSTRUCTION(0) && n <= TT_TRAP_INSTRUCTION_LAST)
    46                 return syscall_table[n - TT_TRAP_INSTRUCTION(0)](a1, a2, a3, a4);
    47         else
    48                 panic("Undefined syscall %d\n", n - TT_TRAP_INSTRUCTION(0));
     45        return syscall_handler(a1, a2, a3, a4, n - TT_TRAP_INSTRUCTION(0));
    4946}
    5047
  • kernel/arch/sparc64/src/trap/trap.c

    re5ecc02 r06e1e95  
    5454/** @}
    5555 */
    56 
Note: See TracChangeset for help on using the changeset viewer.