Ignore:
Timestamp:
Dec 10, 2015, 1:38:43 PM (9 years ago)
Author:
alain
Message:

Remove the seg_kernel_init vseg: All the kernel code is now packed
in one single seg_kernel_code vseg. The entry point for the _kernel_init()
function (from the boot code is now at vaddr = 0x80000000.
The goal is to use only one BPP per cluster for the replicated kernel code.

Location:
soft/giet_vm/giet_kernel
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_kernel/giet.s

    r346 r742  
    11/************************************************************************************
    2 * GIET: Interruption/Exception/Trap Handler for MIPS32 processor
     2* This file contains the two entry points in the GIET_VM code:
     3* - the _init entry point (from the boot code)      is 0x80000000
     4* - the _giet entry point (from user applications)  is 0x80000180
     5* => The base address of the segment containing this code MUST be 0x80000000.
    36*
    4 * The base address of the segment containing this code MUST be 0x80000000, in
    5 * order to have the entry point at address 0x80000180!!! All messages are
    6 * printed on the TTY corresponding to the task&processor identifiers.
    7 *
    8 * It uses two arrays of functions:
     7* The _giet uses two arrays of functions:
    98* - the _cause_vector[16] array defines the 16 causes to enter the GIET
    109*   it is initialized in th exc_handler.c file
     
    1413
    1514    .section .giet, "ax", @progbits
    16     .space 0x180
     15
     16/*
     17 * INIT entry point (at address 0x80000000)
     18 */
     19
     20    .func   _init
     21    .type   _init, %function
     22
     23_init:
     24    la      $26,    _kernel_init
     25    jr      $26                        /* jump to _kernel_init */
     26
     27    .endfunc
     28    .size _init, .-_init
     29
     30    .space  0x170                      /* the _entry function occupies 16 bytes */
    1731
    1832/*
     
    2943    addu    $26,    $26,    $27             /* $26 <= &_cause_vector[XCODE] */
    3044    lw      $26,    ($26)               /* $26 <=  _cause_vector[XCODE] */
    31     jr      $26                         /* Jump indexed by XCODE */
     45    jr      $26                         /* Jump to handler indexed by XCODE */
    3246
    3347    .endfunc
     
    3549
    3650/*
    37  * *** System Call Handler ***
     51 * *** Syscall Handler ***
    3852 *
    3953 * A system call is handled as a special function call.
  • soft/giet_vm/giet_kernel/kernel.ld

    r516 r742  
    1616    {
    1717        *(.giet)
     18        *(.kinit)
    1819        *(.text)
    1920    }
     
    2425        *(.kdata)
    2526    }
    26 
    27     . = kernel_init_vbase;
    28     seg_kernel_init :
    29     {
    30         *(.kinit)
    31     }
    3227}
    3328
  • soft/giet_vm/giet_kernel/kernel_init.c

    r725 r742  
    137137
    138138////////////////////////////////////////////////////////////////////////////////
    139 // This kernel_init() function completes the kernel initialisation in 5 steps:
     139// This _kernel_init() function completes the kernel initialisation in 5 steps:
    140140// Step 0 is done by processor[0,0,0]. Steps 1 to 4 are executed in parallel
    141141// by all processors.
     
    146146// - step 4 : Each processor set sp, sr, ptpr, epc registers values.
    147147////////////////////////////////////////////////////////////////////////////////
    148 __attribute__((section (".kinit"))) void kernel_init()
     148__attribute__((section (".kinit"))) void _kernel_init()
    149149{
    150150    // gpid  : hardware processor index (fixed format: X_WIDTH|Y_WIDTH|P_WIDTH)
Note: See TracChangeset for help on using the changeset viewer.