Re: First steps towards making NO_IRQ a generic concept

Ingo Molnar
2005-11-03T15:44:21Z

* Matthew Wilcox <matthew@wil.cx> wrote:

> [PATCH] Check the irq number is within bounds in the functions which
> weren't already checking.

> + if (irq >= NR_IRQS)
> + return;

hm, why not start with the -1 value for PCI_NO_IRQ, instead of 0:

> +#define PCI_NO_IRQ 0

and be done with it.

also:

> - Move the definition of NO_IRQ from asm directories to
> <linux/hardirq.h>. Individual architectures can still override it if
> they want to, but all existing definitions were -1.

we shouldnt make it overridable just for the sake of it. If all arches
were fine with -1, it should be the generic value and there's no
override.

plus, shouldnt this go into -mm first, since it clearly affects some
drivers? Why into Linus' tree immediately?

the patch series looks good to me otherwise.

Ingo