Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1244278 > unrolled thread

[PATCH 0/2] irqchip: make non-modular code explicitly non-modular

Started byPaul Gortmaker <paul.gortmaker@windriver.com>
First post2015-10-12 01:10 +0200
Last post2015-10-14 04:30 +0200
Articles 3 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 0/2] irqchip: make non-modular code explicitly non-modular Paul Gortmaker <paul.gortmaker@windriver.com> - 2015-10-12 01:10 +0200
    Re: [PATCH 0/2] irqchip: make non-modular code explicitly non-modular Geert Uytterhoeven <geert@linux-m68k.org> - 2015-10-12 09:10 +0200
      Re: [PATCH 0/2] irqchip: make non-modular code explicitly non-modular Paul Gortmaker <paul.gortmaker@windriver.com> - 2015-10-14 04:30 +0200

#1244278 — [PATCH 0/2] irqchip: make non-modular code explicitly non-modular

FromPaul Gortmaker <paul.gortmaker@windriver.com>
Date2015-10-12 01:10 +0200
Subject[PATCH 0/2] irqchip: make non-modular code explicitly non-modular
Message-ID<qixUC-61y-17@gated-at.bofh.it>
In a previous merge window, we made changes to allow better
delineation between modular and non-modular code in commit
0fd972a7d91d6e15393c449492a04d94c0b89351 ("module: relocate module_init
from init.h to module.h").  This allows us to now ensure module code
looks modular and non-modular code does not accidentally look modular
just to avoid suffering build breakage.

Here we target code that is, by nature of their Makefile and/or
Kconfig settings, only available to be built-in, but implicitly
presenting itself as being possibly modular by way of using modular
headers, macros, and functions.

The goal here is to remove that illusion of modularity from these
files, but in a way that leaves the actual runtime unchanged.
In doing so, we remove code that has never been tested and adds
no value to the tree.  And we continue the process of expecting a
level of consistency between the Kconfig/Makefile of code and the
code in use itself.

Fortuntately the irqchip subsystem has just two instances.  For
comparison there are over 300 instances tree wide, resulting in a
possible net removal of on the order of 5000 lines of unused code.

Build tested on the latest linux-next, on ARM.

Paul.
--

Cc: Jason Cooper <jason@lakedaemon.net>
Cc: Magnus Damm <damm+renesas@opensource.se>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: Thomas Gleixner <tglx@linutronix.de>

Paul Gortmaker (2):
  drivers/irqchip: make irq-renesas-intc-irqpin.c explicitly non-modular
  drivers/irqchip: make irq-renesas-irqc.c explicitly non-modular

 drivers/irqchip/irq-renesas-intc-irqpin.c | 24 +-----------------------
 drivers/irqchip/irq-renesas-irqc.c        | 30 +-----------------------------
 2 files changed, 2 insertions(+), 52 deletions(-)

-- 
2.6.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [next] | [standalone]


#1244420

FromGeert Uytterhoeven <geert@linux-m68k.org>
Date2015-10-12 09:10 +0200
Message-ID<qiFp8-8uI-3@gated-at.bofh.it>
In reply to#1244278
Hi Paul,

On Mon, Oct 12, 2015 at 1:05 AM, Paul Gortmaker
<paul.gortmaker@windriver.com> wrote:
> In a previous merge window, we made changes to allow better
> delineation between modular and non-modular code in commit
> 0fd972a7d91d6e15393c449492a04d94c0b89351 ("module: relocate module_init
> from init.h to module.h").  This allows us to now ensure module code
> looks modular and non-modular code does not accidentally look modular
> just to avoid suffering build breakage.
>
> Here we target code that is, by nature of their Makefile and/or
> Kconfig settings, only available to be built-in, but implicitly
> presenting itself as being possibly modular by way of using modular
> headers, macros, and functions.
>
> The goal here is to remove that illusion of modularity from these
> files, but in a way that leaves the actual runtime unchanged.
> In doing so, we remove code that has never been tested and adds
> no value to the tree.  And we continue the process of expecting a
> level of consistency between the Kconfig/Makefile of code and the
> code in use itself.
>
> Fortuntately the irqchip subsystem has just two instances.  For
> comparison there are over 300 instances tree wide, resulting in a
> possible net removal of on the order of 5000 lines of unused code.
>
> Build tested on the latest linux-next, on ARM.
>
> Paul.
> --
>
> Cc: Jason Cooper <jason@lakedaemon.net>
> Cc: Magnus Damm <damm+renesas@opensource.se>
> Cc: Marc Zyngier <marc.zyngier@arm.com>
> Cc: Thomas Gleixner <tglx@linutronix.de>
>
> Paul Gortmaker (2):
>   drivers/irqchip: make irq-renesas-intc-irqpin.c explicitly non-modular
>   drivers/irqchip: make irq-renesas-irqc.c explicitly non-modular
>
>  drivers/irqchip/irq-renesas-intc-irqpin.c | 24 +-----------------------
>  drivers/irqchip/irq-renesas-irqc.c        | 30 +-----------------------------
>  2 files changed, 2 insertions(+), 52 deletions(-)

Both of these are "external interrupt controllers", meaning that on some boards
they are used to handle only interrupts from external devices (e.g. Ethernet),
which is optional.

Hence IMHO the bool should be changed to tristate instead.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [prev] | [next] | [standalone]


#1246258

FromPaul Gortmaker <paul.gortmaker@windriver.com>
Date2015-10-14 04:30 +0200
Message-ID<qjjZg-1gq-13@gated-at.bofh.it>
In reply to#1244420
[Re: [PATCH 0/2] irqchip: make non-modular code explicitly non-modular] On 12/10/2015 (Mon 09:04) Geert Uytterhoeven wrote:

> Hi Paul,
> 
> On Mon, Oct 12, 2015 at 1:05 AM, Paul Gortmaker
> <paul.gortmaker@windriver.com> wrote:

[...]

> > Paul Gortmaker (2):
> >   drivers/irqchip: make irq-renesas-intc-irqpin.c explicitly non-modular
> >   drivers/irqchip: make irq-renesas-irqc.c explicitly non-modular
> >
> >  drivers/irqchip/irq-renesas-intc-irqpin.c | 24 +-----------------------
> >  drivers/irqchip/irq-renesas-irqc.c        | 30 +-----------------------------
> >  2 files changed, 2 insertions(+), 52 deletions(-)
> 
> Both of these are "external interrupt controllers", meaning that on some boards
> they are used to handle only interrupts from external devices (e.g. Ethernet),
> which is optional.
> 
> Hence IMHO the bool should be changed to tristate instead.

So, at the risk of repeating myself -- changing to tristate widens the
scope on build coverage and everything else.  When I did this for a
staging driver, I got caught in symbols that were not exported.  Not
critically complex, but it does show that allowing a new config option
can make things break.  Hence keeping the support matrix the same is
table stakes to allow me to make this tree wide update in a way that
scales.

As the changes I propose do not change the runtime, I think that the
verification of the extension of functionality lies on those who think
moving these drivers from bool to tristate is a genuine value add.

If for no other reason, it at least does keep a bisect honest in showing
where existing functionality broke vs. added functionality brought in
new breakage.

Paul.
--

> 
> Gr{oetje,eeting}s,
> 
>                         Geert
> 
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
> 
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
>                                 -- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web