Skip to contentSkip to conversation

Fix IDLE issue with sedf scheduler on IA64

PATCH Tian, Kevin 2 participants 2 messages Jul 13, 2005

lore
Share & tools
lore
#0 lore raw
Quoted 2 lines

From: [email protected] [mailto:[email protected]] On Behalf Of

Magenheimer,

Quoted 10 lines

Dan (HP Labs Fort Collins)
Sent: Wednesday, July 13, 2005 8:25 PM
To: Tian, Kevin

Is there a better way (for ia64)? I kind of like the solution Keir and Ian imply... is it possible in context_switch to simply
"refuse" to switch to the idle domain? E.g. if the idle domain
is the target of the switch, instead switch to domain0 (and make it runnable)?

This seems not easy to be simply done in context_switch without common change. Preventing switch to IDLE is easy, and a simple check in context_switch can achieve. However the really bad thing is about housekeep info within scheduler. Eg. domain0 may have been placed on waitq, with begin of next period still far away. Stealing slice of IDLE to Dom0 without notifying scheduler, may mess the future decision since next schedule will happen on Dom0's context and base on dom0's statistic info...

Thanks,
Kevin

#1 lore raw
Quoted 8 lines · Kevin
Quoted 7 lines

Magenheimer, Dan (HP Labs Fort Collins) wrote:

Is there a better way (for ia64)? I kind of like the solution Keir and Ian imply... is it possible in context_switch to simply
"refuse" to switch to the idle domain? E.g. if the idle domain
is the target of the switch, instead switch to domain0 (and make it runnable)?

Quoted 8 lines

This seems not easy to be simply done in context_switch without common change. Preventing switch to IDLE is easy, and a simple check in context_switch can achieve. However the really bad thing is about housekeep info within scheduler. Eg. domain0 may have been placed on waitq, with begin of next period still far away. Stealing slice of IDLE to Dom0 without notifying scheduler, may mess the future decision since next schedule will happen on Dom0's context and base on dom0's statistic info...

See how x86 does this in context_switch() (arch/x86/domain.c). In particular, __context_switch is avoided for the idle domain, so the context restored is some register pops in ret_from_intr/restore_all_xen (arch/x86/x86_32/entry.S).

No scheduler changes or confusion necessary...

Signature · 2 lines
Hollis Blanchard
IBM Linux Technology Center