Changeset a35b458 in mainline for boot/arch/ia64/src


Ignore:
Timestamp:
2018-03-02T20:10:49Z (7 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
f1380b7
Parents:
3061bc1
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-02-28 17:38:31)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-03-02 20:10:49)
Message:

style: Remove trailing whitespace on _all_ lines, including empty ones, for particular file types.

Command used: tools/srepl '\s\+$' '' -- *.c *.h *.py *.sh *.s *.S *.ag

Currently, whitespace on empty lines is very inconsistent.
There are two basic choices: Either remove the whitespace, or keep empty lines
indented to the level of surrounding code. The former is AFAICT more common,
and also much easier to do automatically.

Alternatively, we could write script for automatic indentation, and use that
instead. However, if such a script exists, it's possible to use the indented
style locally, by having the editor apply relevant conversions on load/save,
without affecting remote repository. IMO, it makes more sense to adopt
the simpler rule.

Location:
boot/arch/ia64/src
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • boot/arch/ia64/src/main.c

    r3061bc1 ra35b458  
    6767        memmap_item_t *memmap = bootinfo.memmap;
    6868        size_t items = 0;
    69        
     69
    7070        if (!bootpar) {
    7171                /* Fake-up a memory map for simulators. */
     
    8383                size_t mm_size = bootpar->efi_memmap_sz;
    8484                size_t md_size = bootpar->efi_memdesc_sz;
    85                
     85
    8686                /*
    8787                 * Walk the EFI memory map using the V1 memory descriptor
     
    109109                                continue;
    110110                        }
    111                        
     111
    112112                        memmap[items].base = md->phys_start;
    113113                        memmap[items].size = md->pages * EFI_PAGE_SIZE;
     
    115115                }
    116116        }
    117        
     117
    118118        bootinfo.memmap_items = items;
    119119}
     
    134134                efi_guid_t sal_guid = SAL_SYSTEM_TABLE_GUID;
    135135                sal_system_table_header_t *sal_st;
    136                
     136
    137137                sal_st = efi_vendor_table_find(
    138138                    (efi_system_table_t *) bootpar->efi_system_table, sal_guid);
    139139
    140140                sal_system_table_parse(sal_st);
    141                
     141
    142142                bootinfo.sys_freq = sal_base_clock_frequency();
    143143        } else {
     
    150150{
    151151        version_print();
    152        
     152
    153153        printf(" %p|%p: boot info structure\n", &bootinfo, &bootinfo);
    154154        printf(" %p|%p: kernel entry point\n",
     
    156156        printf(" %p|%p: loader entry point\n",
    157157            (void *) LOADER_ADDRESS, (void *) LOADER_ADDRESS);
    158        
     158
    159159        size_t i;
    160160        for (i = 0; i < COMPONENTS; i++)
     
    162162                    components[i].addr, components[i].name,
    163163                    components[i].inflated, components[i].size);
    164        
     164
    165165        void *dest[COMPONENTS];
    166166        size_t top = KERNEL_ADDRESS;
     
    169169        for (i = 0; i < min(COMPONENTS, TASKMAP_MAX_RECORDS); i++) {
    170170                top = ALIGN_UP(top, PAGE_SIZE);
    171                
     171
    172172                if (i > 0) {
    173173                        bootinfo.taskmap.tasks[bootinfo.taskmap.cnt].addr =
     
    175175                        bootinfo.taskmap.tasks[bootinfo.taskmap.cnt].size =
    176176                            components[i].inflated;
    177                        
     177
    178178                        str_cpy(bootinfo.taskmap.tasks[bootinfo.taskmap.cnt].name,
    179179                            BOOTINFO_TASK_NAME_BUFLEN, components[i].name);
    180                        
     180
    181181                        bootinfo.taskmap.cnt++;
    182182                }
    183                
     183
    184184                dest[i] = (void *) top;
    185185                top += components[i].inflated;
    186186                cnt++;
    187187        }
    188        
     188
    189189        printf("\nInflating components ... ");
    190        
     190
    191191        /*
    192192         * We will use the next available address for a copy of each component to
     
    197197        for (i = cnt; i > 0; i--) {
    198198                printf("%s ", components[i - 1].name);
    199                
     199
    200200                /*
    201201                 * Copy the component to a location which is guaranteed not to
     
    203203                 */
    204204                memmove((void *) top, components[i - 1].addr, components[i - 1].size);
    205                
     205
    206206                int err = inflate((void *) top, components[i - 1].size,
    207207                    dest[i - 1], components[i - 1].inflated);
    208                
     208
    209209                if (err != EOK) {
    210210                        printf("\n%s: Inflating error %d, halting.\n",
     
    213213                }
    214214        }
    215        
     215
    216216        printf(".\n");
    217217
     
    219219        read_sal_configuration();
    220220        read_pal_configuration();
    221        
     221
    222222        printf("Booting the kernel ...\n");
    223223        jump_to_kernel(&bootinfo);
  • boot/arch/ia64/src/pal.c

    r3061bc1 ra35b458  
    3535{
    3636        uint64_t proc_ratio;
    37        
     37
    3838        pal_static_call_0_1(PAL_FREQ_RATIOS, &proc_ratio);
    39        
     39
    4040        return proc_ratio;
    4141}
  • boot/arch/ia64/src/pal_asm.S

    r3061bc1 ra35b458  
    3838        srlz.i
    3939        srlz.d
    40        
     40
    4141        mov loc2 = gp
    4242        mov loc3 = rp
    43        
     43
    4444        addl loc4 = @gprel(pal_proc), gp
    4545
     
    4848        mov r30 = in2
    4949        mov r31 = in3 ;;
    50        
     50
    5151        ld8 loc4 = [loc4]
    5252        movl loc5 = 0f ;;
     
    6464        cmp.ne p8,p0 = 0, in5
    6565        cmp.ne p9,p0 = 0, in6 ;;
    66        
     66
    6767(p7)    st8 [in4] = r9
    6868(p8)    st8 [in5] = r10
    6969(p9)    st8 [in6] = r11
    70        
     70
    7171        mov gp = loc2
    7272        mov rp = loc3 ;;
    73        
     73
    7474        mov ar.pfs = loc0
    7575        br.ret.sptk.many rp
  • boot/arch/ia64/src/sal.c

    r3061bc1 ra35b458  
    7575{
    7676        uint64_t freq;
    77        
     77
    7878        sal_call_1_1(SAL_FREQ_BASE, 0, &freq);
    79        
     79
    8080        return freq;
    8181}
  • boot/arch/ia64/src/sal_asm.S

    r3061bc1 ra35b458  
    4545FUNCTION_BEGIN(sal_call)
    4646        alloc loc0 = ar.pfs, 8, 8, 8, 0
    47        
     47
    4848        adds sp = -STACK_SCRATCH_AREA, sp
    4949
    5050        mov loc1 = gp
    5151        mov loc2 = rp
    52        
     52
    5353        addl loc3 = @gprel(sal_proc), gp
    5454        addl loc4 = @gprel(sal_proc_gp), gp
    55        
     55
    5656        mov out0 = in0
    5757        mov out1 = in1
     
    6262        mov out6 = in6
    6363        mov out7 = in7 ;;
    64        
     64
    6565        ld8 loc3 = [loc3]
    6666        ld8 gp = [loc4]
     
    7373        ld8 loc6 = [r15]
    7474        ld8 loc7 = [r16]
    75        
     75
    7676        mov b6 = loc3 ;;
    7777        br.call.sptk.many rp = b6
    78        
     78
    7979        cmp.ne p7,p0 = 0, loc5
    8080        cmp.ne p8,p0 = 0, loc6
    8181        cmp.ne p9,p0 = 0, loc7 ;;
    82        
     82
    8383(p7)    st8 [loc5] = r9
    8484(p8)    st8 [loc6] = r10
    8585(p9)    st8 [loc7] = r11
    86        
     86
    8787        mov gp = loc1
    8888        mov rp = loc2
    8989
    9090        adds sp = STACK_SCRATCH_AREA, sp ;;
    91        
     91
    9292        mov ar.pfs = loc0
    9393        br.ret.sptk.many rp
  • boot/arch/ia64/src/ski.c

    r3061bc1 ra35b458  
    3737{
    3838        static bool initialized = false;
    39        
     39
    4040        if (initialized)
    4141                return;
     
    4848                : "r15", "r8"
    4949        );
    50        
     50
    5151        initialized = true;
    5252}
Note: See TracChangeset for help on using the changeset viewer.