mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-20 10:08:33 -04:00
xTaskGetTaskHandle() changed to xTaskGetHandle().
Tidy up CEC1302 demo. Ensure bit 0 of the task address is clear when setting up stack of initial Cortex-M3/4/7 stacks (for strict compliance, although not practically necessary). vTaskGetTaskInfo() changed to vTaskGetInfo() - with a macro added for backward compatibility.
This commit is contained in:
parent
ee5386756d
commit
255145bde1
30 changed files with 179 additions and 112 deletions
|
@ -105,6 +105,10 @@ debugger. */
|
|||
#define portTASK_RETURN_ADDRESS prvTaskExitError
|
||||
#endif
|
||||
|
||||
/* For strict compliance with the Cortex-M spec the task start address should
|
||||
have bit-0 clear, as it is loaded into the PC on exit from an ISR. */
|
||||
#define portSTART_ADDRESS_MASK ( ( StackType_t ) 0xfffffffeUL )
|
||||
|
||||
/* The priority used by the kernel is assigned to a variable to make access
|
||||
from inline assembler easier. */
|
||||
const uint32_t ulKernelPriority = configKERNEL_INTERRUPT_PRIORITY;
|
||||
|
@ -154,7 +158,7 @@ StackType_t *pxPortInitialiseStack( StackType_t *pxTopOfStack, TaskFunction_t px
|
|||
|
||||
*pxTopOfStack = portINITIAL_XPSR; /* xPSR */
|
||||
pxTopOfStack--;
|
||||
*pxTopOfStack = ( StackType_t ) pxCode; /* PC */
|
||||
*pxTopOfStack = ( ( StackType_t ) pxCode ) & portSTART_ADDRESS_MASK; /* PC */
|
||||
pxTopOfStack--;
|
||||
*pxTopOfStack = ( StackType_t ) portTASK_RETURN_ADDRESS; /* LR */
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue