Messages in this thread | | | Date | Sun, 14 Sep 2008 17:39:22 +0200 | From | Ingo Molnar <> | Subject | Re: [RFC 2/4] introduce dynamically allocated system vectors |
| |
* Dean Nelson <dcn@sgi.com> wrote:
> Introduce the dynamic allocation and deallocation of system vectors which > are mapped to irq numbers allowing the use of request_irq()/free_irq(). > > Signed-off-by: Dean Nelson <dcn@sgi.com> > > --- > > arch/x86/kernel/apic.c | 3 > arch/x86/kernel/io_apic.c | 264 +++++++++++++++++++++++++++++++++-----
it's not clean to put it into io_apic.c:
> -static int __assign_irq_vector(int irq, cpumask_t mask) > +bool __grab_irq_vector(struct irq_desc *desc, unsigned int vector, > + cpumask_t *new_domain_mask)
please put it into arch/x86/kernel/irq.c or so.
this bit:
> Index: linux/include/linux/irq.h > =================================================================== > --- linux.orig/include/linux/irq.h 2008-09-10 12:08:46.000000000 -0500 > +++ linux/include/linux/irq.h 2008-09-11 06:53:16.000000000 -0500 > @@ -390,11 +390,22 @@ set_irq_chained_handler(unsigned int irq > extern void set_irq_noprobe(unsigned int irq); > extern void set_irq_probe(unsigned int irq); > > -/* Handle dynamic irq creation and destruction */ > +/* Handle dynamic irq device vector allocation and deallocation */ > extern unsigned int create_irq_nr(unsigned int irq_want); > extern int create_irq(void); > extern void destroy_irq(unsigned int irq); > > +/* Handle dynamic irq system vector allocation and deallocation */ > +extern unsigned int create_irq_system_vector(cpumask_t *mask, int priority, > + char *irq_name, > + int *assigned_vector); > +#define IRQ_PRIORITY_LOW 1 > +#define IRQ_PRIORITY_HIGH 2 > + > +extern void destroy_irq_system_vector(unsigned int irq); > + > +extern int reserve_system_vectors(int number);
does not belong into the generic kernel code - it's an x86 property.
Ingo
| |