This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

about MMU init


hi,

There is a quesstion when i debug the eCos's kernel using VisionClick of EST on Powerpc823 platform. As far as i know ,there is no memory protect mode in eCos,however,I find that there are some places eCos set the IR and DR bit of MSR(machine state register of MPC823 )and Initialize MMU,I don't know why and what it used for?
The codes are as follow:

   /arch/v1_3_1/srcHal_misc.c

hal_MMU_init (void)
{
    int id = 0;
    int i  = 0;

    cyg_hal_clear_MMU ();

    while (cyg_hal_mem_map[i].size) {
        id = cyg_hal_map_memory (id, 
                                 cyg_hal_mem_map[i].virtual_addr,
                                 cyg_hal_mem_map[i].physical_addr,
                                 cyg_hal_mem_map[i].size,
                                 cyg_hal_mem_map[i].flags);
        i++;
    }
}

Forthermore, when i debug the eCos kernel i find that it set IR and DR bit of MSR and then call the founction :
 \mpc8xx\v1_3_1\include\Var_intr.h
cyg_hal_interrupt_unmask ( cyg_uint32 vector ) 

It can not trace down and error happens,but when i clear the IR and DR of MSR then it is ok ,and i can trace down the programme,so i think it is the IR and DR cause the error.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]