WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Fix bind_irq_vector() destination

To: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] Fix bind_irq_vector() destination
From: Sheng Yang <sheng@xxxxxxxxxxxxxxx>
Date: Thu, 26 Aug 2010 17:40:10 +0800
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 26 Aug 2010 02:41:03 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C89BF0E5.1F34E%keir.fraser@xxxxxxxxxxxxx>
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: Intel Opensource Technology Center
References: <C89BF0E5.1F34E%keir.fraser@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.13.2 (Linux/2.6.32-24-generic; KDE/4.4.2; x86_64; ; )
On Thursday 26 August 2010 17:22:29 Keir Fraser wrote:
> By the way, could an IRQ's 'domain' be given a better name in Xen? We
> already have a meaning for domain, and it makes the code very confusing!
> Can we call it cpu_affinity or cpu_binding, or something a bit more
> meaningful and distinguishable?

Or use cpu_mask directly? Would send an separate patch if you like, for 
whatever 
name. :)

--
regards
Yang, Sheng

> 
>  -- Keir
> 
> On 26/08/2010 10:14, "Sheng Yang" <sheng@xxxxxxxxxxxxxxx> wrote:
> > The "mask" covered all online cpus in the "domain". It should be used as
> > destination later, instead of using "domain" directly.
> > 
> > Signed-off-by: Sheng Yang <sheng@xxxxxxxxxxxxxxx>
> > 
> > --
> > diff --git a/xen/arch/x86/irq.c b/xen/arch/x86/irq.c
> > --- a/xen/arch/x86/irq.c
> > +++ b/xen/arch/x86/irq.c
> > @@ -86,14 +86,14 @@
> > 
> >      cpus_and(mask, domain, cpu_online_map);
> >      if (cpus_empty(mask))
> >      
> >          return -EINVAL;
> > 
> > -    if ((cfg->vector == vector) && cpus_equal(cfg->domain, domain))
> > +    if ((cfg->vector == vector) && cpus_equal(cfg->domain, mask))
> > 
> >          return 0;
> >      
> >      if (cfg->vector != IRQ_VECTOR_UNASSIGNED)
> >      
> >          return -EBUSY;
> >      
> >      for_each_cpu_mask(cpu, mask)
> >      
> >          per_cpu(vector_irq, cpu)[vector] = irq;
> >      
> >      cfg->vector = vector;
> > 
> > -    cfg->domain = domain;
> > +    cfg->domain = mask;
> > 
> >      irq_status[irq] = IRQ_USED;
> >      if (IO_APIC_IRQ(irq))
> >      
> >          irq_vector[irq] = vector;

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>