Ensure the definition of prvTaskExitError()does not result in a compiler warning in ports where its use can be overridden (GCC Cortex-M ports).

Remove duplicate save/restore of r14 in Cortex-M4F ports.
pull/4/head
Richard Barry 11 years ago
parent 20eb03ed7d
commit b181a3af99

@ -209,6 +209,12 @@ portBASE_TYPE xPortStartScheduler( void )
/* Start the first task. */
vPortStartFirstTask();
/* Should never get here as the tasks will now be executing! Call the task
exit error function to prevent compiler warnings about a static function
not being called in the case that the application writer overrides this
functionality by defining configTASK_RETURN_ADDRESS. */
prvTaskExitError();
/* Should not get here! */
return 0;
}

@ -329,6 +329,12 @@ portBASE_TYPE xPortStartScheduler( void )
/* Start the first task. */
prvPortStartFirstTask();
/* Should never get here as the tasks will now be executing! Call the task
exit error function to prevent compiler warnings about a static function
not being called in the case that the application writer overrides this
functionality by defining configTASK_RETURN_ADDRESS. */
prvTaskExitError();
/* Should not get here! */
return 0;
}

@ -353,6 +353,12 @@ portBASE_TYPE xPortStartScheduler( void )
/* Start the first task. */
prvPortStartFirstTask();
/* Should never get here as the tasks will now be executing! Call the task
exit error function to prevent compiler warnings about a static function
not being called in the case that the application writer overrides this
functionality by defining configTASK_RETURN_ADDRESS. */
prvTaskExitError();
/* Should not get here! */
return 0;
}
@ -446,13 +452,13 @@ void xPortPendSVHandler( void )
" \n"
" str r0, [r2] \n" /* Save the new top of stack into the first member of the TCB. */
" \n"
" stmdb sp!, {r3, r14} \n"
" stmdb sp!, {r3} \n"
" mov r0, %0 \n"
" msr basepri, r0 \n"
" bl vTaskSwitchContext \n"
" mov r0, #0 \n"
" msr basepri, r0 \n"
" ldmia sp!, {r3, r14} \n"
" ldmia sp!, {r3} \n"
" \n"
" ldr r1, [r3] \n" /* The first item in pxCurrentTCB is the task top of stack. */
" ldr r0, [r1] \n"

@ -99,13 +99,13 @@ xPortPendSVHandler:
/* Save the new top of stack into the first member of the TCB. */
str r0, [r2]
stmdb sp!, {r3, r14}
stmdb sp!, {r3}
mov r0, #configMAX_SYSCALL_INTERRUPT_PRIORITY
msr basepri, r0
bl vTaskSwitchContext
mov r0, #0
msr basepri, r0
ldmia sp!, {r3, r14}
ldmia sp!, {r3}
/* The first item in pxCurrentTCB is the task top of stack. */
ldr r1, [r3]

@ -443,13 +443,13 @@ __asm void xPortPendSVHandler( void )
/* Save the new top of stack into the first member of the TCB. */
str r0, [r2]
stmdb sp!, {r3, r14}
stmdb sp!, {r3}
mov r0, #configMAX_SYSCALL_INTERRUPT_PRIORITY
msr basepri, r0
bl vTaskSwitchContext
mov r0, #0
msr basepri, r0
ldmia sp!, {r3, r14}
ldmia sp!, {r3}
/* The first item in pxCurrentTCB is the task top of stack. */
ldr r1, [r3]

@ -89,13 +89,13 @@ _vector_14: .type func
;Save the new top of stack into the first member of the TCB.
str r0, [r2]
stmdb sp!, {r3, r14}
stmdb sp!, {r3}
ldr.w r0, =ulMaxSyscallInterruptPriorityConst
msr basepri, r0
bl vTaskSwitchContext
mov r0, #0
msr basepri, r0
ldmia sp!, {r3, r14}
ldmia sp!, {r3}
;The first item in pxCurrentTCB is the task top of stack.
ldr r1, [r3]
@ -141,13 +141,13 @@ _lc_ref__vector_pp_14: .type func
;Save the new top of stack into the first member of the TCB.
str r0, [r2]
stmdb sp!, {r3, r14}
stmdb sp!, {r3}
ldr.w r0, =ulMaxSyscallInterruptPriorityConst
msr basepri, r0
bl vTaskSwitchContext
mov r0, #0
msr basepri, r0
ldmia sp!, {r3, r14}
ldmia sp!, {r3}
;The first item in pxCurrentTCB is the task top of stack.
ldr r1, [r3]

Loading…
Cancel
Save