Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/sparc64/src/sun4v/start.S

    rc92af69b r4872160  
    9393 *
    9494 * The registers are expected to be in this state:
    95  *  - %o0 starting address of physical memory
     95 *  - %o0 bootinfo structure address (BSP only)
     96 *  - %o1 starting address of physical memory
    9697 *        + bootstrap processor flag
    9798 *          bits 63...1: physical memory starting address / 2
    9899 *          bit 0:       non-zero on BSP processor, zero on AP processors
    99  *  - %o1 bootinfo structure address (BSP only)
    100  *
    101100 *
    102101 * Moreover, we depend on boot having established the following environment:
     
    108107kernel_image_start:
    109108        mov BSP_FLAG, %l0
    110         and %o0, %l0, %l7                       ! l7 <= bootstrap processor?
    111         andn %o0, %l0, %l6                      ! l6 <= start of physical memory
    112         or %o1, %g0, %l1
     109        and %o1, %l0, %l7                       ! l7 <= bootstrap processor?
     110        andn %o1, %l0, %l6                      ! l6 <= start of physical memory
     111        or %o0, %g0, %l0
    113112
    114113        ! Get bits (PHYSMEM_ADDR_SIZE - 1):13 of physmem_base.
     
    155154        mov 0, %o5
    156155        ta 0xff
     156        nop
    157157
    158158        /*
     
    218218        ! on APs skip executing the following code
    219219        cmp %l7, 0
    220         be %xcc, 1f
     220        be 1f
    221221        nop
    222222
     
    246246        sub %sp, STACK_BIAS, %sp
    247247
    248         /*
    249          * Call arch_pre_main(bootinfo)
    250          */
     248        or %l0, %g0, %o0
    251249        call arch_pre_main
    252         or %l1, %g0, %o0
     250        nop
    253251       
    254         /*
    255          * Create the first stack frame.
    256          */
    257         save %sp, -(STACK_WINDOW_SAVE_AREA_SIZE + STACK_ARG_SAVE_AREA_SIZE), %sp
    258         flushw
    259         add %g0, -STACK_BIAS, %fp
    260 
    261252        call main_bsp
    262253        nop
     
    265256
    2662570:
    267         ba,a %xcc, 0b
     258        ba 0b
     259        nop
    268260
    2692611:
     
    277269         */
    278270
    279         mov 1, %o0              ! MMU enable flag
    280         set mmu_enabled, %o1
    281         mov MMU_ENABLE, %o5     ! MMU enable HV call
    282         ta 0x80                 ! call HV
     271        mov     1, %o0                  ! MMU enable flag
     272        set     mmu_enabled, %o1
     273        mov     MMU_ENABLE, %o5 ! MMU enable HV call
     274        ta      0x80            ! call HV
    283275
    284276        mmu_enabled:
     
    293285        ldx [%g1], %o6
    294286
    295         /*
    296          * Create the first stack frame.
    297          */
    298         save %sp, -(STACK_WINDWO_SAVE_AREA_SIZE + STACK_ARG_SAVE_AREA_SIZE), %sp
    299         flushw
    300         add %g0, -STACK_BIAS, %fp
    301 
    302287        call main_ap
    303288        nop
     
    306291        /* Not reached. */
    3072920:
    308         ba,a %xcc, 0b
     293        ba 0b
     294        nop
    309295
    310296.align 8
     
    324310before_ap_boots:
    325311        setx 0x80400000, %g0, %o0
    326         ba,a %xcc, kernel_image_start
     312        ba kernel_image_start
     313        nop
    327314
    328315.section K_DATA_START, "aw", @progbits
Note: See TracChangeset for help on using the changeset viewer.