]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS/Source/portable/GCC/MicroBlazeV9/port.c
Add GCC ARM Cortex-M4F MPU port.
[freertos] / FreeRTOS / Source / portable / GCC / MicroBlazeV9 / port.c
index 6c73906293e481bd0ad847809274e511dcf298b1..fbdaafe8d47e78304a517da889282565f8e83b30 100644 (file)
@@ -99,6 +99,7 @@ FSR register is saved as part of the task context.  portINITIAL_FSR is the value
 given to the FSR register when the initial context is set up for a task being\r
 created. */\r
 #define portINITIAL_FSR                                ( 0U )\r
+\r
 /*-----------------------------------------------------------*/\r
 \r
 /*\r
@@ -150,6 +151,7 @@ StackType_t *pxPortInitialiseStack( StackType_t *pxTopOfStack, TaskFunction_t px
 extern void *_SDA2_BASE_, *_SDA_BASE_;\r
 const uint32_t ulR2 = ( uint32_t ) &_SDA2_BASE_;\r
 const uint32_t ulR13 = ( uint32_t ) &_SDA_BASE_;\r
+extern void _start1( void );\r
 \r
        /* Place a few bytes of known values on the bottom of the stack.\r
        This is essential for the Microblaze port and these lines must\r
@@ -204,7 +206,7 @@ const uint32_t ulR13 = ( uint32_t ) &_SDA_BASE_;
                pxTopOfStack--;\r
                *pxTopOfStack = ( StackType_t ) 0x07;   /* R7 - other parameters and temporaries. */\r
                pxTopOfStack--;\r
-               *pxTopOfStack = ( StackType_t ) 0x08;   /* R8 - other parameters and temporaries. */\r
+               *pxTopOfStack = ( StackType_t ) NULL;   /* R8 - other parameters and temporaries. */\r
                pxTopOfStack--;\r
                *pxTopOfStack = ( StackType_t ) 0x09;   /* R9 - other parameters and temporaries. */\r
                pxTopOfStack--;\r
@@ -222,7 +224,7 @@ const uint32_t ulR13 = ( uint32_t ) &_SDA_BASE_;
        pxTopOfStack--;\r
        *pxTopOfStack = ( StackType_t ) pxCode; /* R14 - return address for interrupt. */\r
        pxTopOfStack--;\r
-       *pxTopOfStack = ( StackType_t ) NULL;   /* R15 - return address for subroutine. */\r
+       *pxTopOfStack = ( StackType_t ) _start1;        /* R15 - return address for subroutine. */\r
 \r
        #ifdef portPRE_LOAD_STACK_FOR_DEBUGGING\r
                pxTopOfStack--;\r