diff options
Diffstat (limited to 'bsps/microblaze/microblaze_fpga/start/crtinit.S')
-rw-r--r-- | bsps/microblaze/microblaze_fpga/start/crtinit.S | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/bsps/microblaze/microblaze_fpga/start/crtinit.S b/bsps/microblaze/microblaze_fpga/start/crtinit.S index a9779404b2..6c7fc3af23 100644 --- a/bsps/microblaze/microblaze_fpga/start/crtinit.S +++ b/bsps/microblaze/microblaze_fpga/start/crtinit.S @@ -30,6 +30,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include <bspopts.h> + .globl _crtinit .align 2 .ent _crtinit @@ -75,12 +77,17 @@ _crtinit: brlid r15, __init /* Invoke language initialization functions */ nop #endif /* __rtems__ */ - +#ifdef BSP_START_COPY_FDT_FROM_U_BOOT /* Boot loaders may pass the device tree in r5 */ + brlid r15, bsp_fdt_copy /* Do not touch r5 until bsp_fdt_copy() is called */ +#endif /* BSP_START_COPY_FDT_FROM_U_BOOT */ addi r6, r0, 0 /* Initialize argc = 1 and argv = NULL and envp = NULL */ addi r7, r0, 0 #ifndef __rtems__ brlid r15, main /* Execute the program */ #else + mfs r3, rmsr + ori r3, r3, 0x100 /* Set Exception Enable MSR flag */ + mts rmsr, r3 brlid r15, boot_card #endif /* __rtems__ */ addi r5, r0, 0 |