Changeset 624 for trunk/hal/generic


Ignore:
Timestamp:
Mar 12, 2019, 1:37:38 PM (3 years ago)
Author:
alain
Message:

Fix several bugs to use the instruction MMU in kernel mode
in replacement of the instruction address extension register,
and remove the "kentry" segment.

This version is running on the tsar_generic_iob" platform.

One interesting bug: the cp0_ebase defining the kernel entry point
(for interrupts, exceptions and syscalls) must be initialized
early in kernel_init(), because the VFS initialisation done by
kernel_ini() uses RPCs, and RPCs uses Inter-Processor-Interrup.

Location:
trunk/hal/generic
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/hal/generic/hal_gpt.h

    r623 r624  
    5656#define GPT_CACHABLE    0x0020       /*! PTE can be cached                             */
    5757#define GPT_USER        0x0040       /*! PTE is user accessible                        */
    58 #define GPT_DIRTY       0x0080       /*! PTE has been "recently" written               */
     58#define GPT_DIRTY       0x0080       /*! PTE has been written                          */
    5959#define GPT_ACCESSED    0x0100       /*! PTE has been "recently" accessed              */
    6060#define GPT_GLOBAL      0x0200       /*! PTE is kept in TLB at context switch          */
     
    142142
    143143/****************************************************************************************
    144  * This function unmaps a page table entry identified by the <vpn> argument in the
    145  * local GPT identified by the <gpt> argument.
    146  * It does NOT release the physical memory allocated for the unmapped page.
    147  ****************************************************************************************
    148  * @ gpt       : [in] pointer on the local page table
    149  * @ vpn       : [in] virtual page number
     144 * This function unmaps all pages identified by the <vpn> argument from the local GPT
     145 * identified by the <gpt> argument.
     146 * It does NOT release the physical memory allocated for the unmapped pages.
     147 ****************************************************************************************
     148 * @ gpt      : [in] pointer on the local page table
     149 * @ vpn      : [in] page index in virtual space
    150150 ***************************************************************************************/
    151151void hal_gpt_reset_pte( gpt_t * gpt,
  • trunk/hal/generic/hal_special.h

    r623 r624  
    4646
    4747/*****************************************************************************************
    48  * This function initializes - for architectures requiring it - the MMU registers
    49  * as required by the target architecture to execute the kernel threads attached
    50  * to kernel process zero. It is called by all cores in the kernel_init() function.
     48 * This function initializes - for architectures requiring it - the MMU registers of the
     49 * calling core to use the the kernel page table identified by the <gpt> argument for
     50 * all threads attached to kernel process_zero.
     51 * It is called by all cores in the kernel_init() function.
    5152 *****************************************************************************************
    5253 * @ gpt :  local pointer on the kernel page table descriptor.
Note: See TracChangeset for help on using the changeset viewer.