mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-09-21 14:42:18 +08:00
bsp/mpc55xx: Add MPC55XX_NULL_POINTER_PROTECTION
This commit is contained in:
@@ -79,6 +79,11 @@ RTEMS_BSPOPTS_SET([MPC55XX_EMIOS_PRESCALER],[*] ,[1])
|
||||
RTEMS_BSPOPTS_HELP([MPC55XX_EMIOS_PRESCALER],
|
||||
[Must be defined to set the EMIOS prescaler])
|
||||
|
||||
RTEMS_BSPOPTS_SET([MPC55XX_NULL_POINTER_PROTECTION],[mpc5566*],[1])
|
||||
RTEMS_BSPOPTS_SET([MPC55XX_NULL_POINTER_PROTECTION],[mpc5674f*],[1])
|
||||
RTEMS_BSPOPTS_HELP([MPC55XX_NULL_POINTER_PROTECTION],
|
||||
[enable NULL pointer protection])
|
||||
|
||||
RTEMS_BSPOPTS_SET([HAS_SMC91111],[phycore_mpc5554],[1])
|
||||
RTEMS_BSPOPTS_HELP([HAS_SMC91111],
|
||||
[If defined the board has the SMC91111 networking chip.])
|
||||
|
||||
@@ -76,6 +76,9 @@
|
||||
/* if defined, do low level initialization */
|
||||
#undef MPC55XX_NEEDS_LOW_LEVEL_INIT
|
||||
|
||||
/* enable NULL pointer protection */
|
||||
#undef MPC55XX_NULL_POINTER_PROTECTION
|
||||
|
||||
/* Must be defined to be the external reference clock (in Hz) for clock
|
||||
generation */
|
||||
#undef MPC55XX_REFERENCE_CLOCK
|
||||
|
||||
@@ -78,7 +78,7 @@ void _BSP_Fatal_error( unsigned n)
|
||||
|
||||
static void null_pointer_protection(void)
|
||||
{
|
||||
#if defined(MPC55XX_BOARD_MPC5674FEVB) || defined(MPC55XX_BOARD_MPC5566EVB)
|
||||
#ifdef MPC55XX_NULL_POINTER_PROTECTION
|
||||
struct MMU_tag mmu = { .MAS0 = { .B = { .TLBSEL = 1, .ESEL = 1 } } };
|
||||
|
||||
PPC_SET_SPECIAL_PURPOSE_REGISTER(FSL_EIS_MAS0, mmu.MAS0.R);
|
||||
|
||||
Reference in New Issue
Block a user