Changes between Version 4 and Version 5 of boot_loader


Ignore:
Timestamp:
Nov 5, 2014, 4:59:12 PM (10 years ago)
Author:
alain
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • boot_loader

    v4 v5  
    2929
    3030=== '''boot_schedulers init()''' ===
    31 This function makes the schedulers initialisation, as specified in the mapping, with the following principles.
     31This function makes the schedulers initialisation, as specified in the mapping, respecting the following principles.
    3232 * There is one scheduler per processor.
    3333 * Any task defined in any application can be allocated to any processor.
    3434 * The allocation of task to processors is fully static (no task migration).
    3535 * One single processor cannot schedule more than 14 tasks.
    36  One scheduler occupies 8 Kbytes, and contains the contexts of all tasks allocated to the processor (256 bytes per task).
     36  * One scheduler occupies 8 Kbytes, and contains the contexts of all tasks allocated to the processor (256 bytes per task).
    3737 
    3838=== '''boot_peripherals_init()''' ===
    3939This function makes the external peripherals and coprocessors initialisation.
    4040
    41 
    4241=== '''''boot_elf_load()''' ===
    4342This function load into memory the kernel code (''kernel.elf'' file), and the user code for all applications specified in the mapping.
    44 
    4543
    4644Finally, processor(0,0,0) starts all other processors, using an inter-processor interrupt (WTI).
     
    4846to the ''kernel_init()''  function.
    4947
    50 == __Phase 2__ ==
     48== __Phase 2 : Kernel__ ==
     49
     50This phase is executed by all processors in parallel. All processors enter the same [source:soft/giet_vm/giet_kernel/kernel_init.c kernel_init() function.
     51The main steps are the following:
     52
     53 * Step 1 : each processor get its scheduler virtual address from CP0_SCHED register and contributes to _schedulers[] array initialisation
     54 * step 2 : each processor loops on all allocated tasks to build the _ptabs_vaddr[] & _ptabs_ptprs[] arrays from the tasks contexts.
     55 * step 3 : each processor computes and set the XCU masks, as specified in the HWI, PTI, and WTI interrupt vectors.
     56 * step 4 : each processor starts its TICK timer if it has at least at least one task allocated
     57 * step 5 : each processor updates the idle_task context (CTX_SP, CTX_RA, CTX_EPC).
     58 * step 6 : when all processors reach the synchronisation barrier, each processor set registers SP, SR, PTPR, EPC, with the values corresponding to the first allocated task, and jump to user code
    5159
    5260