Convert some ports to use xTaskIncrementTick() in place of vTaskIncrementTick().

Move DSB instructions to before WFI instructions in line with ARM recommendations.
This commit is contained in:
Richard Barry 2013-06-06 15:46:40 +00:00
parent 4e9374ad90
commit 686d190798
27 changed files with 128 additions and 142 deletions

View file

@ -163,7 +163,7 @@ void vPortYieldProcessor( void )
/* Increment the tick count - which may wake some tasks but as the
preemptive scheduler is not being used any woken task is not given
processor time no matter what its priority. */
vTaskIncrementTick();
xTaskIncrementTick();
/* Clear the PIT interrupt. */
ulDummy = AT91C_BASE_PITC->PITC_PIVR;
@ -183,10 +183,11 @@ void vPortYieldProcessor( void )
portSAVE_CONTEXT();
/* Increment the tick count - this may wake a task. */
vTaskIncrementTick();
/* Find the highest priority task that is ready to run. */
vTaskSwitchContext();
if( xTaskIncrementTick() != pdFALSE )
{
/* Find the highest priority task that is ready to run. */
vTaskSwitchContext();
}
/* End the interrupt in the AIC. */
AT91C_BASE_AIC->AIC_EOICR = AT91C_BASE_PITC->PITC_PIVR;;