Changeset 1433ecda in mainline for kernel/arch/mips32


Ignore:
Timestamp:
2018-04-04T15:42:37Z (8 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
2c4e1cc
Parents:
47b2d7e3
Message:

Fix cstyle: make ccheck-fix and commit only files where all the changes are good.

Location:
kernel/arch/mips32
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/mips32/include/arch/atomic.h

    r47b2d7e3 r1433ecda  
    6262
    6363        asm volatile (
    64                 "1:\n"
    65                 "       ll %0, %1\n"
    66                 "       addu %0, %0, %3\n"  /* same as addi, but never traps on overflow */
    67                 "       move %2, %0\n"
    68                 "       sc %0, %1\n"
    69                 "       beq %0, %4, 1b\n"   /* if the atomic operation failed, try again */
    70                 "       nop\n"
    71                 : "=&r" (tmp),
    72                   "+m" (val->count),
    73                   "=&r" (v)
    74                 : "r" (i),
    75                   "i" (0)
     64            "1:\n"
     65            "   ll %0, %1\n"
     66            "   addu %0, %0, %3\n"  /* same as addi, but never traps on overflow */
     67            "   move %2, %0\n"
     68            "   sc %0, %1\n"
     69            "   beq %0, %4, 1b\n"   /* if the atomic operation failed, try again */
     70            "   nop\n"
     71            : "=&r" (tmp),
     72              "+m" (val->count),
     73              "=&r" (v)
     74            : "r" (i),
     75              "i" (0)
    7676        );
    7777
     
    8585
    8686        asm volatile (
    87                 "1:\n"
    88                 "       ll %2, %1\n"
    89                 "       bnez %2, 2f\n"
    90                 "       li %0, %3\n"
    91                 "       sc %0, %1\n"
    92                 "       beqz %0, 1b\n"
    93                 "       nop\n"
    94                 "2:\n"
    95                 : "=&r" (tmp),
    96                   "+m" (val->count),
    97                   "=&r" (v)
    98                 : "i" (1)
     87            "1:\n"
     88            "   ll %2, %1\n"
     89            "   bnez %2, 2f\n"
     90            "   li %0, %3\n"
     91            "   sc %0, %1\n"
     92            "   beqz %0, 1b\n"
     93            "   nop\n"
     94            "2:\n"
     95            : "=&r" (tmp),
     96              "+m" (val->count),
     97              "=&r" (v)
     98            : "i" (1)
    9999        );
    100100
     
    105105{
    106106        do {
    107                 while (val->count);
     107                while (val->count)
     108                        ;
    108109        } while (test_and_set(val));
    109110}
  • kernel/arch/mips32/src/cpu/cpu.c

    r47b2d7e3 r1433ecda  
    8686static struct data_t imp_data80[] = {
    8787        { "MIPS", "4Kc" },  /* 0x80 */
    88         {"Invalid","Invalid"}, /* 0x81 */
    89         {"Invalid","Invalid"}, /* 0x82 */
    90         {"MIPS","4Km & 4Kp"}, /* 0x83 */
    91         { NULL, NULL}
     88        { "Invalid", "Invalid" }, /* 0x81 */
     89        { "Invalid", "Invalid" }, /* 0x82 */
     90        { "MIPS", "4Km & 4Kp" }, /* 0x83 */
     91        { NULL, NULL }
    9292};
    9393
     
    129129
    130130        printf("cpu%u: %s %s (rev=%d.%d, imp=%d)\n",
    131                 m->id, data->vendor, data->model, m->arch.rev_num >> 4,
    132                 m->arch.rev_num & 0x0f, m->arch.imp_num);
     131            m->id, data->vendor, data->model, m->arch.rev_num >> 4,
     132            m->arch.rev_num & 0x0f, m->arch.imp_num);
    133133}
    134134
  • kernel/arch/mips32/src/mach/malta/malta.c

    r47b2d7e3 r1433ecda  
    8484{
    8585
    86         const char ch = (char) wch;
     86        const char ch = (char) wch;
    8787
    88         (*yamon_print_count)(0, &ch, 1);
     88        (*yamon_print_count)(0, &ch, 1);
    8989}
    9090
  • kernel/arch/mips32/src/mips32.c

    r47b2d7e3 r1433ecda  
    7474
    7575/* Stack pointer saved when entering user mode */
    76 uintptr_t supervisor_sp __attribute__ ((section (".text")));
     76uintptr_t supervisor_sp __attribute__((section(".text")));
    7777
    7878size_t cpu_count = 0;
     
    172172            (uintptr_t) kernel_uarg->uspace_entry);
    173173
    174         while (1);
     174        while (1)
     175                ;
    175176}
    176177
     
    194195{
    195196        ___halt();
    196         while (1);
     197        while (1)
     198                ;
    197199}
    198200
  • kernel/arch/mips32/src/mm/frame.c

    r47b2d7e3 r1433ecda  
    290290        for (i = 0; i < phys_regions_count; i++) {
    291291                printf("%#010x %10u\n",
    292                         PFN2ADDR(phys_regions[i].start), PFN2ADDR(phys_regions[i].count));
     292                    PFN2ADDR(phys_regions[i].start), PFN2ADDR(phys_regions[i].count));
    293293        }
    294294}
Note: See TracChangeset for help on using the changeset viewer.