[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080919232640.GB10245@sgi.com>
Date: Fri, 19 Sep 2008 18:26:40 -0500
From: Dean Nelson <dcn@....com>
To: Yinghai Lu <yhlu.kernel@...il.com>
Cc: Ingo Molnar <mingo@...e.hu>,
"Eric W. Biederman" <ebiederm@...ssion.com>,
"H. Peter Anvin" <hpa@...or.com>, Jack Steiner <steiner@....com>,
Alan Mayer <ajm@....com>, jeremy@...p.org,
rusty@...tcorp.com.au, suresh.b.siddha@...el.com,
torvalds@...ux-foundation.org, linux-kernel@...r.kernel.org,
Thomas Gleixner <tglx@...utronix.de>,
Yinghai Lu <Yinghai.lu@....com>
Subject: Re: [PATCH 1/3] switch vector_irq[] from irq number to irq_desc pointer v2
On Fri, Sep 19, 2008 at 01:40:23PM -0700, Yinghai Lu wrote:
> On Fri, Sep 19, 2008 at 1:04 PM, Dean Nelson <dcn@....com> wrote:
> > Change per_cpu variable vector_irq[] from holding an 'int' irq number to
> > holding a 'struct irq_desc' pointer.
>
> why?
>
> Eric wants to change int irq to some struct irq later?
Well, it was my take on what Eric was saying in the following:
On Mon, Aug 11, 2008 at 12:39:22PM -0700, Eric W. Biederman wrote:
>
> We create a common factor of assign_irq_vector that looks something like:
>
> bool __grab_irq_vector(struct irq_desc *desc, unsigned vector, cpumask_t new_domain)
> {
> /* Must be called with vector lock */
> struct irq_cfg *cfg;
> bool grabbed = false;
> unsigned int old_vector;
> cpumask_t mask;
> int cpu;
>
> cfg = get_irqp_cfg(irq);
> old_vector = cfg->vector;
> cpus_and(mask, new_domain, cpu_online_map);
>
> for_each_cpu_mask_nr(cpu, mask) {
> if (per_cpu(vector_irq, cpu)[vector])
> goto out;
> }
> /* Available reserve it */
> for_each_cpu_mask_nr(cpu, mask)
> per_cpu(vector_irq, cpu)[vector] = desc;
The previous line made me think that was what he wanted....
> if (cfg->vector) {
> cfg->move_in_progress;
> cfg->old_domain = cfg->domain;
> }
> cfg->vector = vector;
> cfg->domain = mask;
> grabbed = true;
>
> out:
> return grabbed;
> }
... Along with the following paragraph.
> I think vector_irq should return an irq_desc and have an entry for
> all of the static vectors as well (if we are going to do weird
> things with dynamic high priority vector allocation, and dynamic
> detection of which vectors assign_irq_vector may use).
If that's not what Eric meant, then I got it wrong and you can reject
the patchset.
Dean
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists