|  |  | 
  
    |  |  | 
 
  |   |  | 
  
    |  |  | 
  
    |  |  | 
  
    |   xen-ia64-devel
RE: [Xen-devel] Does dom0 see all physical processors?	(RE:[Xen-ia64-dev 
| To: | "Magenheimer, Dan (HP Labs Fort Collins)" <dan.magenheimer@xxxxxx> |  
| Subject: | RE: [Xen-devel] Does dom0 see all physical processors?	(RE:[Xen-ia64-devel] SAL INFO virtualization) |  
| From: | "Stephen C. Tweedie" <sct@xxxxxxxxxx> |  
| Date: | Fri, 07 Apr 2006 09:55:43 -0400 |  
| Cc: | Jimi Xenidis <jimix@xxxxxxxxxxxxxx>, Ian Pratt <m+Ian.Pratt@xxxxxxxxxxxx>,	"Tian, Kevin" <kevin.tian@xxxxxxxxx>,	xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, okrieg@xxxxxxxxxx,	Tristan Gingold <Tristan.Gingold@xxxxxxxx>,	xen-ia64-devel@xxxxxxxxxxxxxxxxxxx |  
| Delivery-date: | Fri, 07 Apr 2006 06:57:01 -0700 |  
| Envelope-to: | www-data@xxxxxxxxxxxxxxxxxx |  
| In-reply-to: | <516F50407E01324991DD6D07B0531AD51BCF50@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx> |  
| List-help: | <mailto:xen-devel-request@lists.xensource.com?subject=help> |  
| List-id: | Xen developer discussion <xen-devel.lists.xensource.com> |  
| List-post: | <mailto:xen-devel@lists.xensource.com> |  
| List-subscribe: | <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>,	<mailto:xen-devel-request@lists.xensource.com?subject=subscribe> |  
| List-unsubscribe: | <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>,	<mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe> |  
| References: | <516F50407E01324991DD6D07B0531AD51BCF50@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx> |  
| Sender: | xen-devel-bounces@xxxxxxxxxxxxxxxxxxx |  
| Hi,
On Wed, 2006-04-05 at 07:07 -0700, Magenheimer, Dan (HP Labs Fort
Collins) wrote:
> I believe ppc has "paravirtualized spinlocks" in their Linux
> kernel
ppc64 does.  From include/asm-ppc64/spinlock.h:
/*
 * On a system with shared processors (that is, where a physical
 * processor is multiplexed between several virtual processors),
 * there is no point spinning on a lock if the holder of the lock
 * isn't currently scheduled on a physical processor.  Instead
 * we detect this situation and ask the hypervisor to give the
 * rest of our timeslice to the lock holder.
 *
 * So that we can tell which virtual processor is holding a lock,
 * we put 0x80000000 | smp_processor_id() in the lock when it is
 * held.  Conveniently, we have a word in the paca that holds this
 * value.
 */
A quick hack for this which simply did a yield sched_op when it detected
a collision could be done in the same way from a paravirtualised kernel
without any HV changes; but I think it would take extra scheduler help
to do a directed yield to a specific CPU.
--Stephen
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
 | 
 |  | 
  
    |  |  |