Re: [PATCH v3 10/15] MIPS: generic: Increase NR_IRQS to 256

From: Thomas Bogendoerfer
Date: Mon Sep 07 2020 - 16:04:15 EST


On Sun, Sep 06, 2020 at 09:29:30PM +0200, Paul Cercueil wrote:
> 128 IRQs is not enough to support Ingenic SoCs.
>
> Signed-off-by: Paul Cercueil <paul@xxxxxxxxxxxxxxx>
> ---
>
> Notes:
> v2-v3: No change
>
> arch/mips/include/asm/mach-generic/irq.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/mips/include/asm/mach-generic/irq.h b/arch/mips/include/asm/mach-generic/irq.h
> index 72ac2c202c55..079889ced4f3 100644
> --- a/arch/mips/include/asm/mach-generic/irq.h
> +++ b/arch/mips/include/asm/mach-generic/irq.h
> @@ -9,7 +9,7 @@
> #define __ASM_MACH_GENERIC_IRQ_H
>
> #ifndef NR_IRQS
> -#define NR_IRQS 128
> +#define NR_IRQS 256
> #endif

this will increase NR_IRQS for all platforms, which don't override
NR_IRQS in their mach-XXX directory. Size of the data segment increases
by 18464 bytes for a 32bit kernel and 33792 for a 64bit kernel. I would
take this change as this allows to remove a few more mach-*/irq.h files.
And if a platform needs save every byte it finds, we can add a irq.h file
for that. An even nicer way would be to make NR_IRQS selectable via Kconfig.
Something like "select NR_IRQS 51" would be quite handy for that...

Thomas.

--
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea. [ RFC1925, 2.3 ]