|   | 
      | 
  
  
      | 
      | 
  
 
     | 
    | 
  
  
     | 
    | 
  
  
    |   | 
      | 
  
  
    | 
         
xen-devel
Re: [Xen-devel] domain_pause and vcpu_pause on currently executing	domai
 
On 18 Jul 2005, at 21:33, George Washington Dunlap III wrote:
 I just discovered the domain_pause() and vcpu_pause() functionality, 
and i was wondering why the functions call BUG if the target 
domain/vcpu is currently executing.  It seems like being able to say, 
"Pause the currently running domain as soon as this hypervisor event 
is done" would be a useful one; all that would be required is having 
domain_sleep_sync() raise the schedule softirq if it's the currently 
executing one.
 Was there a particular reason this was implemented this way?  Or was 
the use I described not envisioned?
 
 We do have something a bit like that, for debuggers 
(domain_pause_for_debugger). Apart from that, I'm not sure what it 
would be useful for. Well, actually it would be useful if you could 
pause the current domain to get it off the scheduler runqueues but 
still carry on your current thread of execution within Xen. But Xen 
context switching (on x86 at least) doesn't really allow that. And if 
you can't do that, hacks to make domain_pause() at least appear to work 
for the currently-executing domain probably aren;t very useful and 
would quite likely lead to confused people writing subtly broken code. 
:-)
 Those interfaces are still open for comments though, and can change if 
there is a strong argument to do so.
 -- Keir
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
 
 |   
 
 | 
    | 
  
  
    |   | 
    |