Add logic to reset the replenish the sporadic scheduler when a task is resumed

This commit is contained in:
Gregory Nutt
2015-07-24 09:54:28 -06:00
parent 39192c3537
commit 9d98177daa
14 changed files with 43 additions and 109 deletions
+3 -7
View File
@@ -1,7 +1,7 @@
/****************************************************************************
* arch/x86/src/common/up_unblocktask.c
*
* Copyright (C) 2011, 2013-2014 Gregory Nutt. All rights reserved.
* Copyright (C) 2011, 2013-2015 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
@@ -92,13 +92,9 @@ void up_unblock_task(struct tcb_s *tcb)
sched_removeblocked(tcb);
/* Reset its timeslice. This is only meaningful for round
* robin tasks but it doesn't here to do it for everything
*/
/* Reset scheduler parameters */
#if CONFIG_RR_INTERVAL > 0
tcb->timeslice = MSEC2TICK(CONFIG_RR_INTERVAL);
#endif
sched_resume_scheduler(tcb);
/* Add the task in the correct location in the prioritized
* g_readytorun task list