All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>, Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Olof Johansson <olof@lixom.net>,
	"open list:ALPHA PORT" <linux-alpha@vger.kernel.org>,
	"open list:SYNOPSYS ARC ARCHITECTURE"
	<linux-snps-arc@lists.infradead.org>,
	"moderated list:ARM PORT" <linux-arm-kernel@lists.infradead.org>,
	"open list:C6X ARCHITECTURE" <linux-c6x-dev@linux-c6x.org>,
	"moderated list:H8/300 ARCHITECTURE"
	<uclinux-h8-devel@lists.sourceforge.jp>,
	"open list:QUALCOMM HEXAGON ARCHITECTURE"
	<linux-hexagon@vger.kernel.org>,
	"open list:IA64 Itanium PLATFORM" <linux-ia64@vger.kernel.org>,
	"open list:M68" <linux-m68k@lists.linux-m68k.org>
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 19:32:54 +0000	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>, Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Olof Johansson <olof@lixom.net>,
	linux-alpha@vger.kernel.org (open list:ALPHA PORT),
	linux-snps-arc@lists.infradead.org (open list:SYNOPSYS ARC
	ARCHITECTURE),
	linux-arm-kernel@lists.infradead.org (moderated list:ARM PORT),
	linux-c6x-dev@linux-c6x.org (open list:C6X ARCHITECTURE),
	uclinux-h8-devel@lists.sourceforge.jp (moderated list:H8/300
	ARCHITECTURE),
	linux-hexagon@vger.kernel.org (open list:QUALCOMM HEXAGON
	ARCHITECTURE),
	linux-ia64@vger.kernel.org (open list:IA64 (Itanium) PLATFORM),
	linux-m68k@lists.linux-m68k.org (open list:M68
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>, Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Olof Johansson <olof@lixom.net>,
	linux-alpha@vger.kernel.org (open list:ALPHA PORT),
	linux-snps-arc@lists.infradead.org (open list:SYNOPSYS ARC
	ARCHITECTURE),
	linux-arm-kernel@lists.infradead.org (moderated list:ARM PORT),
	linux-c6x-dev@linux-c6x.org (open list:C6X ARCHITECTURE),
	uclinux-h8-devel@lists.sourceforge.jp (moderated list:H8/300
	ARCHITECTURE),
	linux-hexagon@vger.kernel.org (open list:QUALCOMM HEXAGON
	ARCHITECTURE),
	linux-ia64@vger.kernel.org (open list:IA64 (Itanium) PLATFORM),
	linux-m68k@lists.linux-m68k.org (open list:M68K ARCHITECTURE),
	linux-mips@linux-mips.org (open list:MIPS),
	nios2-dev@lists.rocketboards.org (moderated list:NIOS2
	ARCHITECTURE),
	openrisc@lists.librecores.org (open list:OPENRISC ARCHITECTURE),
	linux-parisc@vger.kernel.org (open list:PARISC ARCHITECTURE),
	linuxppc-dev@lists.ozlabs.org (open list:LINUX FOR POWERPC
	(32-BIT AND 64-BIT)),
	linux-riscv@lists.infradead.org (open list:RISC-V ARCHITECTURE),
	linux-s390@vger.kernel.org (open list:S390),
	linux-sh@vger.kernel.org (open list:SUPERH),
	sparclinux@vger.kernel.org (open list:SPARC + UltraSPARC
	(sparc/sparc64)),
	linux-um@lists.infradead.org (open list:USER-MODE LINUX (UML)),
	linux-xtensa@linux-xtensa.org (open list:TENSILICA XTENSA PORT
	(xtensa)),
	devicetree@vger.kernel.org (open list:OPEN FIRMWARE AND
	FLATTENED DEVICE TREE),
	linux-arch@vger.kernel.org (open list:GENERIC INCLUDE/ASM HEADER
	FILES)
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1


WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>, Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Olof Johansson <olof@lixom.net>,
	"open list:ALPHA PORT" <linux-alpha@vger.kernel.org>,
	"open list:SYNOPSYS ARC ARCHITECTURE"
	<linux-snps-arc@lists.infradead.org>,
	"moderated list:ARM PORT" <linux-arm-kernel@lists.infradead.org>,
	"open list:C6X ARCHITECTURE" <linux-c6x-dev@linux-c6x.org>,
	"moderated list:H8/300 ARCHITECTURE"
	<uclinux-h8-devel@lists.sourceforge.jp>,
	"open list:QUALCOMM HEXAGON ARCHITECTURE"
	<linux-hexagon@vger.kernel.org>,
	"open list:IA64 Itanium PLATFORM" <linux-ia64@vger.kernel.org>,
	"open list:M68K ARCHITECTURE" <linux-m68k@lists.linux-m68k.org>,
	"open list:MIPS" <linux-mips@linux-mips.org>,
	"moderated list:NIOS2 ARCHITECTURE"
	<nios2-dev@lists.rocketboards.org>,
	"open list:OPENRISC ARCHITECTURE" <openrisc@lists.librecores.org>,
	"open list:PARISC ARCHITECTURE" <linux-parisc@vger.kernel.org>,
	"open list:LINUX FOR POWERPC 32-BIT AND 64-BIT"
	<linuxppc-dev@lists.ozlabs.org>,
	"open list:RISC-V ARCHITECTURE" <linux-riscv@lists.infradead.org>,
	"open list:S390" <linux-s390@vger.kernel.org>,
	"open list:SUPERH" <linux-sh@vger.kernel.org>,
	"open list:SPARC + UltraSPARC sparc/sparc64"
	<sparclinux@vger.kernel.org>,
	"open list:USER-MODE LINUX UML" <linux-um@lists.infradead.org>,
	"open list:TENSILICA XTENSA PORT xtensa"
	<linux-xtensa@linux-xtensa.org>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE"
	<devicetree@vger.kernel.org>,
	"open list:GENERIC INCLUDE/ASM HEADER FILES"
	<linux-arch@vger.kernel.org>
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)
Message-ID: <20181024193254.NC5HZwptypecf7bZLUjVErU4Jek3N-_4SJpBUgnlqGg@z> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>, Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Olof Johansson <olof@lixom.net>,
	"open list:ALPHA PORT" <linux-alpha@vger.kernel.org>,
	"open list:SYNOPSYS ARC ARCHITECTURE"
	<linux-snps-arc@lists.infradead.org>,
	"moderated list:ARM PORT" <linux-arm-kernel@lists.infradead.org>,
	"open list:C6X ARCHITECTURE" <linux-c6x-dev@linux-c6x.org>,
	"moderated list:H8/300 ARCHITECTURE"
	<uclinux-h8-devel@lists.sourceforge.jp>,
	"open list:QUALCOMM HEXAGON ARCHITECTURE"
	<linux-hexagon@vger.kernel.org>,
	"open list:IA64 Itanium PLATFORM" <linux-ia64@vger.kernel.org>,
	"open list:M68" <linux-m68k@lists.linux-m68k.org>
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: f.fainelli@gmail.com (Florian Fainelli)
To: linux-riscv@lists.infradead.org
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: "open list:MIPS" <linux-mips@linux-mips.org>,
	"open list:IA64 Itanium PLATFORM" <linux-ia64@vger.kernel.org>,
	"open list:SUPERH" <linux-sh@vger.kernel.org>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE"
	<devicetree@vger.kernel.org>,
	"open list:SPARC + UltraSPARC sparc/sparc64"
	<sparclinux@vger.kernel.org>,
	"open list:RISC-V ARCHITECTURE" <linux-riscv@lists.infradead.org>,
	"open list:GENERIC INCLUDE/ASM HEADER FILES"
	<linux-arch@vger.kernel.org>,
	"open list:S390" <linux-s390@vger.kernel.org>,
	Florian Fainelli <f.fainelli@gmail.com>,
	"open list:C6X ARCHITECTURE" <linux-c6x-dev@linux-c6x.org>,
	"open list:QUALCOMM HEXAGON ARCHITECTURE"
	<linux-hexagon@vger.kernel.org>,
	"open list:SYNOPSYS ARC ARCHITECTURE"
	<linux-snps-arc@lists.infradead.org>,
	"moderated list:H8/300 ARCHITECTURE"
	<uclinux-h8-devel@lists.sourceforge.jp>,
	"open list:TENSILICA XTENSA PORT xtensa"
	<linux-xtensa@linux-xtensa.org>, Arnd Bergmann <arnd@arndb.de>,
	Marc Zyngier <marc.zyngier@arm.com>,
	"open list:USER-MODE LINUX UML" <linux-um@lists.infradead.org>,
	"open list:M68K ARCHITECTURE" <linux-m68k@lists.linux-m68k.org>,
	"open list:OPENRISC ARCHITECTURE" <openrisc@lists.librecores.org>,
	"moderated list:ARM PORT" <linux-arm-kernel@lists.infradead.org>,
	"open list:PARISC ARCHITECTURE" <linux-parisc@vger.kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"open list:ALPHA PORT" <linux-alpha@vger.kernel.org>,
	Olof Johansson <olof@lixom.net>,
	"moderated list:NIOS2 ARCHITECTURE"
	<nios2-dev@lists.rocketboards.org>,
	"open list:LINUX FOR POWERPC 32-BIT AND 64-BIT"
	<linuxppc-dev@lists.ozlabs.org>
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)
Message-ID: <20181024193254.ALx2B2mnRUj-IXo7qGs1lIf4nOuNgCjB4Bpyvhd5xXY@z> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1


_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: "open list:MIPS" <linux-mips@linux-mips.org>,
	"open list:IA64 Itanium PLATFORM" <linux-ia64@vger.kernel.org>,
	"open list:SUPERH" <linux-sh@vger.kernel.org>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE"
	<devicetree@vger.kernel.org>,
	"open list:SPARC + UltraSPARC sparc/sparc64"
	<sparclinux@vger.kernel.org>,
	"open list:RISC-V ARCHITECTURE" <linux-riscv@lists.infradead.org>,
	"open list:GENERIC INCLUDE/ASM HEADER FILES"
	<linux-arch@vger.kernel.org>,
	"open list:S390" <linux-s390@vger.kernel.org>,
	Florian Fainelli <f.fainelli@gmail.com>,
	"open list:C6X ARCHITECTURE" <linux-c6x-dev@linux-c6x.org>,
	"open list:QUALCOMM HEXAGON ARCHITECTURE"
	<linux-hexagon@vger.kernel.org>,
	"open list:SYNOPSYS ARC ARCHITECTURE"
	<linux-snps-arc@lists.infradead.org>,
	"moderated list:H8/300 ARCHITECTURE"
	<uclinux-h8-devel@lists.sourceforge.jp>,
	"open list:TENSILICA XTENSA PORT xtensa"
	<linux-xtensa@linux-xtensa.org>, Arnd Bergmann <arnd@arndb.de>,
	Marc Zyngier <marc.zyngier@arm.com>,
	"open list:USER-MODE LINUX UML" <linux-um@lists.infradead.org>,
	"open list:M68K ARCHITECTURE" <linux-m68k@lists.linux-m68k.org>,
	"open list:OPENRISC ARCHITECTURE" <openrisc@lists.librecores.org>,
	"moderated list:ARM PORT" <linux-arm-kernel@lists.infradead.org>,
	"open list:PARISC ARCHITECTURE" <linux-parisc@vger.kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"open list:ALPHA PORT" <linux-alpha@vger.kernel.org>,
	Olof Johansson <olof@lixom.net>,
	"moderated list:NIOS2 ARCHITECTURE"
	<nios2-dev@lists.rocketboards.org>,
	"open list:LINUX FOR POWERPC 32-BIT AND 64-BIT"
	<linuxppc-dev@lists.ozlabs.org>
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1


WARNING: multiple messages have this Message-ID (diff)
From: f.fainelli@gmail.com (Florian Fainelli)
To: linux-snps-arc@lists.infradead.org
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: f.fainelli@gmail.com (Florian Fainelli)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1

WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: openrisc@lists.librecores.org
Subject: [OpenRISC] [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1


WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>, Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Olof Johansson <olof@lixom.net>,
	"open list:ALPHA PORT" <linux-alpha@vger.kernel.org>,
	"open list:SYNOPSYS ARC ARCHITECTURE"
	<linux-snps-arc@lists.infradead.org>,
	"moderated list:ARM PORT" <linux-arm-kernel@lists.infradead.org>,
	"open list:C6X ARCHITECTURE" <linux-c6x-dev@linux-c6x.org>,
	"moderated list:H8/300" <uclinux-h8-devel@lists.sourceforge.jp>,
	ARCHITECTURE, ,
	"open list:QUALCOMM HEXAGON ARCHITECTURE"
	<linux-hexagon@vger.kernel.org>,
	"open list:IA64 Itanium PLATFORM" <linux-ia64@vger.kernel.org>,
	"open list:M68K ARCHITECTURE" <linux-m68k@lists.linux-m68k.org>,
	"open list:MIPS" <linux-mips@linux-mips.org>,
	"moderated list:NIOS2 ARCHITECTURE"
	<nios2-dev@lists.rocketboards.org>,
	"open list:OPENRISC ARCHITECTURE" <openrisc@lists.librecores.org>,
	"open list:PARISC ARCHITECTURE" <linux-parisc@vger.kernel.org>,
	"open list:LINUX FOR POWERPC 32-BIT AND 64-BIT"
	<linuxppc-dev@lists.ozlabs.org>, ,
	"open list:RISC-V ARCHITECTURE" <linux-riscv@lists.infradead.org>,
	"open list:S390" <linux-s390@vger.kernel.org>,
	"open list:SUPERH" <linux-sh@vger.kernel.org>,
	"open list:SPARC + UltraSPARC" <sparclinux@vger.kernel.org>, ,
	"open list:USER-MODE LINUX UML" <linux-um@lists.infradead.org>,
	"open list:TENSILICA XTENSA PORT xtensa"
	<linux-xtensa@linux-xtensa.org>,
	"open list:OPEN FIRMWARE AND FLATTENED"
	<devicetree@vger.kernel.org>, DEVICE, ,
	"open list:GENERIC INCLUDE/ASM HEADER FILES"
	<linux-arch@vger.kernel.org>
Subject: [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD
Date: Wed, 24 Oct 2018 12:32:54 -0700	[thread overview]
Message-ID: <20181024193256.23734-1-f.fainelli@gmail.com> (raw)

Hi all,

While investigating why ARM64 required a ton of objects to be rebuilt
when toggling CONFIG_DEV_BLK_INITRD, it became clear that this was
because we define __early_init_dt_declare_initrd() differently and we do
that in arch/arm64/include/asm/memory.h which gets included by a fair
amount of other header files, and translation units as well.

Changing the value of CONFIG_DEV_BLK_INITRD is a common thing with build
systems that generate two kernels: one with the initramfs and one
without. buildroot is one of these build systems, OpenWrt is also
another one that does this.

This patch series proposes adding an empty initrd.h to satisfy the need
for drivers/of/fdt.c to unconditionally include that file, and moves the
custom __early_init_dt_declare_initrd() definition away from
asm/memory.h

This cuts the number of objects rebuilds from 1920 down to 26, so a
factor 73 approximately.

Apologies for the long CC list, please let me know how you would go
about merging that and if another approach would be preferable, e.g:
introducing a CONFIG_ARCH_INITRD_BELOW_START_OK Kconfig option or
something like that.

Changes in v2:

- put an /* empty */ comment in the asm-generic/initrd.h file
- trim down the CC list to maximize the chances of people receiving this

Florian Fainelli (2):
  arch: Add asm-generic/initrd.h and make use of it for most
    architectures
  arm64: Create asm/initrd.h

 arch/alpha/include/asm/Kbuild      |  1 +
 arch/arc/include/asm/Kbuild        |  1 +
 arch/arm/include/asm/Kbuild        |  1 +
 arch/arm64/include/asm/initrd.h    | 13 +++++++++++++
 arch/arm64/include/asm/memory.h    |  8 --------
 arch/c6x/include/asm/Kbuild        |  1 +
 arch/h8300/include/asm/Kbuild      |  1 +
 arch/hexagon/include/asm/Kbuild    |  1 +
 arch/ia64/include/asm/Kbuild       |  1 +
 arch/m68k/include/asm/Kbuild       |  1 +
 arch/microblaze/include/asm/Kbuild |  1 +
 arch/mips/include/asm/Kbuild       |  1 +
 arch/nds32/include/asm/Kbuild      |  1 +
 arch/nios2/include/asm/Kbuild      |  1 +
 arch/openrisc/include/asm/Kbuild   |  1 +
 arch/parisc/include/asm/Kbuild     |  1 +
 arch/powerpc/include/asm/Kbuild    |  1 +
 arch/riscv/include/asm/Kbuild      |  1 +
 arch/s390/include/asm/Kbuild       |  1 +
 arch/sh/include/asm/Kbuild         |  1 +
 arch/sparc/include/asm/Kbuild      |  1 +
 arch/um/include/asm/Kbuild         |  1 +
 arch/unicore32/include/asm/Kbuild  |  1 +
 arch/x86/include/asm/Kbuild        |  1 +
 arch/xtensa/include/asm/Kbuild     |  1 +
 drivers/of/fdt.c                   |  1 +
 include/asm-generic/initrd.h       |  1 +
 27 files changed, 38 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm64/include/asm/initrd.h
 create mode 100644 include/asm-generic/initrd.h

-- 
2.17.1



             reply	other threads:[~2018-10-24 19:32 UTC|newest]

Thread overview: 168+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-24 19:32 Florian Fainelli [this message]
2018-10-24 19:32 ` [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD Florian Fainelli
2018-10-24 19:32 ` [OpenRISC] " Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` Florian Fainelli
2018-10-24 19:32 ` [PATCH v2 1/2] arch: Add asm-generic/initrd.h and make use of it for most architectures Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` [OpenRISC] " Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32 ` [PATCH v2 2/2] arm64: Create asm/initrd.h Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` [OpenRISC] " Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:32   ` Florian Fainelli
2018-10-24 19:55 ` [PATCH v2 0/2] arm64: Cut rebuild time when changing CONFIG_BLK_DEV_INITRD Rob Herring
2018-10-24 19:55   ` [OpenRISC] " Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 19:55   ` Rob Herring
2018-10-24 20:01   ` Florian Fainelli
2018-10-24 20:01     ` [OpenRISC] " Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 20:01     ` Florian Fainelli
2018-10-24 21:25     ` Rob Herring
2018-10-24 21:25       ` [OpenRISC] " Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-24 21:25       ` Rob Herring
2018-10-25  9:38   ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` [OpenRISC] " Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:38     ` Mike Rapoport
2018-10-25  9:51     ` Russell King - ARM Linux
2018-10-25  9:51       ` [OpenRISC] " Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25  9:51       ` Russell King - ARM Linux
2018-10-25 13:15     ` Rob Herring
2018-10-25 13:15       ` [OpenRISC] " Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 13:15       ` Rob Herring
2018-10-25 17:29       ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` [OpenRISC] " Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 17:29         ` Mike Rapoport
2018-10-25 21:13         ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` [OpenRISC] " Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 21:13           ` Rob Herring
2018-10-25 23:07           ` Florian Fainelli
2018-10-25 23:07             ` [OpenRISC] " Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-25 23:07             ` Florian Fainelli
2018-10-26 11:07             ` Mike Rapoport
2018-10-26 11:07               ` [OpenRISC] " Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 11:07               ` Mike Rapoport
2018-10-26 19:05               ` Florian Fainelli
2018-10-26 19:05                 ` [OpenRISC] " Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26 19:05                 ` Florian Fainelli
2018-10-26  8:12           ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` [OpenRISC] " Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport
2018-10-26  8:12             ` Mike Rapoport

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181024193256.23734-1-f.fainelli@gmail.com \
    --to=f.fainelli@gmail.com \
    --cc=arnd@arndb.de \
    --cc=catalin.marinas@arm.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-alpha@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-c6x-dev@linux-c6x.org \
    --cc=linux-hexagon@vger.kernel.org \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-m68k@lists.linux-m68k.org \
    --cc=linux-snps-arc@lists.infradead.org \
    --cc=marc.zyngier@arm.com \
    --cc=olof@lixom.net \
    --cc=uclinux-h8-devel@lists.sourceforge.jp \
    --cc=will.deacon@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.