mirror of
https://github.com/apache/nuttx.git
synced 2026-05-31 14:27:37 +08:00
Comment out reassessment of timer in the middle of context switches. Need to revisit
This commit is contained in:
@@ -267,6 +267,7 @@ int sam_oneshot_start(struct sam_oneshot_s *oneshot, oneshot_handler_t handler,
|
|||||||
{
|
{
|
||||||
/* Yes.. then cancel it */
|
/* Yes.. then cancel it */
|
||||||
|
|
||||||
|
tcvdbg("Already running... cancelling\n");
|
||||||
(void)sam_oneshot_cancel(oneshot, NULL);
|
(void)sam_oneshot_cancel(oneshot, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -855,8 +855,8 @@ static int sam_tc_freqdiv_lookup(uint32_t ftcin, int ndx)
|
|||||||
* Name: sam_tc_divfreq_lookup
|
* Name: sam_tc_divfreq_lookup
|
||||||
*
|
*
|
||||||
* Description:
|
* Description:
|
||||||
* Given the TC input frequency (Ftcin) and a divider index, return the value of
|
* Given the TC input frequency (Ftcin) and a divider index, return the
|
||||||
* the divided frequency
|
* value of the divided frequency
|
||||||
*
|
*
|
||||||
* Input Parameters:
|
* Input Parameters:
|
||||||
* ftcin - TC input frequency
|
* ftcin - TC input frequency
|
||||||
|
|||||||
@@ -137,11 +137,13 @@ bool sched_addreadytorun(FAR struct tcb_s *btcb)
|
|||||||
btcb->flink->task_state = TSTATE_TASK_READYTORUN;
|
btcb->flink->task_state = TSTATE_TASK_READYTORUN;
|
||||||
|
|
||||||
#if CONFIG_RR_INTERVAL > 0
|
#if CONFIG_RR_INTERVAL > 0
|
||||||
/* Whenever the task at the head of the ready-to-run chances, we
|
#if 0 /* REVISIT: This can cause crashes in certain cases */
|
||||||
|
/* Whenever the task at the head of the ready-to-run changes, we
|
||||||
* must reassess the interval time that controls time-slicing.
|
* must reassess the interval time that controls time-slicing.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
sched_timer_reassess();
|
sched_timer_reassess();
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
ret = true;
|
ret = true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,6 +109,16 @@ bool sched_removereadytorun(FAR struct tcb_s *rtcb)
|
|||||||
sched_note_switch(rtcb, rtcb->flink);
|
sched_note_switch(rtcb, rtcb->flink);
|
||||||
|
|
||||||
rtcb->flink->task_state = TSTATE_TASK_RUNNING;
|
rtcb->flink->task_state = TSTATE_TASK_RUNNING;
|
||||||
|
|
||||||
|
#if CONFIG_RR_INTERVAL > 0
|
||||||
|
#if 0 /* REVISIT: This can cause crashes in certain cases */
|
||||||
|
/* Whenever the task at the head of the ready-to-run changes, we
|
||||||
|
* must reassess the interval time that controls time-slicing.
|
||||||
|
*/
|
||||||
|
|
||||||
|
sched_timer_reassess();
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
ret = true;
|
ret = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user