[RTEMS Project] #2774: RTEMS loaded by u-boot with dcache, icache and mmu enable does not boot.
RTEMS trac
trac at rtems.org
Mon Aug 8 06:31:47 UTC 2016
#2774: RTEMS loaded by u-boot with dcache, icache and mmu enable does not boot.
--------------------+------------------
Reporter: chrisj | Owner:
Type: defect | Status: new
Priority: normal | Milestone: 4.12
Component: bsps | Version: 4.12
Severity: normal | Keywords:
--------------------+------------------
The arm/xilinx_zynq_zedboard does not boot with a recent u-boot built from
git (b2f1858455e99a91aeafe59ac73c6c047106d5e8). I have tracked the issue
down to the MMU initialization and I am wondering if there are a few
issues we need to look at closer. I think RTEMS could handle this case a
little better and this would improve the ARM support making it more
resilient to how it is run.
I have the code booting and running and these are the changes.
1. In arm_cp15_start_setup_translation_table in arm-cp15-start.h I moved
the arm_cp15_set_translation_table_base to after the table is created.
While this is not that important I did find when looking into this problem
it improved things when I had a call to
arm_cp15_data_cache_clean_all_levels() before setting the table base. I am
not sure the cache clear is needed.
2. In the zynq_setup_mmu_and_cache I detect the MMU being enabled and if
enabled I:
{{{
uint32_t ctrl = arm_cp15_get_control();
if ((ctrl & ARM_CP15_CTRL_M) != 0) {
arm_cp15_data_cache_clean_all_levels();
ctrl &= ~(ARM_CP15_CTRL_C | ARM_CP15_CTRL_I | ARM_CP15_CTRL_M);
arm_cp15_set_control(ctrl);
arm_cp15_tlb_invalidate();
}
}}}
This lets ticker run.
--
Ticket URL: <http://devel.rtems.org/ticket/2774>
RTEMS Project <http://www.rtems.org/>
RTEMS Project
More information about the bugs
mailing list