* [PATCH 0/3] kbuild: Clean up makefiles and then drop obj-n an obj-n
@ 2014-09-09 10:26 Masahiro Yamada
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
` (2 more replies)
0 siblings, 3 replies; 18+ messages in thread
From: Masahiro Yamada @ 2014-09-09 10:26 UTC (permalink / raw)
To: linux-kbuild
Cc: Masahiro Yamada, Mike Turquette, Linus Walleij, Takashi Yoshii,
Jean-Christophe Plagniol-Villard, Hartley Sweeten, Greg Ungerer,
Ryan Mallon, Geert Uytterhoeven, Laurent Pinchart, Wolfram Sang,
Andrew Victor, linux-samsung-soc, Kukjin Kim, Russell King,
Ben Dooks, Sam Ravnborg, Michal Marek, linux-omap, Ulrich Hecht,
linux-arm-kernel, Simon Horman, Nicolas Ferre, netdev,
linux-kernel, Tony Lindgren
Masahiro Yamada (3):
kbuild: remove unnecessary "obj- := dummy.o" trick
kbuild: remove unnecessary variable initializaions
kbuild: remove obj-n and lib-n handling
arch/arm/mach-at91/Makefile | 3 ---
arch/arm/mach-ebsa110/Makefile | 3 ---
arch/arm/mach-ep93xx/Makefile | 3 ---
arch/arm/mach-exynos/Makefile | 5 -----
arch/arm/mach-footbridge/Makefile | 3 ---
arch/arm/mach-iop13xx/Makefile | 5 -----
arch/arm/mach-iop32x/Makefile | 3 ---
arch/arm/mach-iop33x/Makefile | 3 ---
arch/arm/mach-ks8695/Makefile | 3 ---
arch/arm/mach-rpc/Makefile | 4 ----
arch/arm/mach-s3c24xx/Makefile | 5 -----
arch/arm/mach-s3c64xx/Makefile | 5 -----
arch/arm/mach-s5pv210/Makefile | 5 -----
arch/arm/mach-sa1100/Makefile | 3 ---
arch/arm/mach-u300/Makefile | 3 ---
arch/arm/plat-iop/Makefile | 6 ------
arch/arm/plat-omap/Makefile | 3 ---
arch/arm/plat-samsung/Makefile | 5 -----
drivers/clk/shmobile/Makefile | 2 --
drivers/net/wimax/Makefile | 4 ----
firmware/Makefile | 2 +-
scripts/Makefile.build | 4 ++--
scripts/Makefile.clean | 4 +---
scripts/Makefile.fwinst | 2 +-
24 files changed, 5 insertions(+), 83 deletions(-)
--
1.9.1
^ permalink raw reply [flat|nested] 18+ messages in thread
* [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick
2014-09-09 10:26 [PATCH 0/3] kbuild: Clean up makefiles and then drop obj-n an obj-n Masahiro Yamada
@ 2014-09-09 10:26 ` Masahiro Yamada
2014-09-09 16:21 ` Peter Foley
` (2 more replies)
2014-09-09 10:26 ` [PATCH 2/3] kbuild: remove unnecessary variable initializaions Masahiro Yamada
2014-09-09 10:26 ` [PATCH 3/3] kbuild: remove obj-n and lib-n handling Masahiro Yamada
2 siblings, 3 replies; 18+ messages in thread
From: Masahiro Yamada @ 2014-09-09 10:26 UTC (permalink / raw)
To: linux-kbuild
Cc: Masahiro Yamada, Ben Dooks, Kukjin Kim, Russell King,
Mike Turquette, Laurent Pinchart, Simon Horman,
Geert Uytterhoeven, Wolfram Sang, Takashi Yoshii, Ulrich Hecht,
linux-arm-kernel, linux-samsung-soc, linux-kernel, netdev
In these Makefiles, at least one of "obj-y" and "obj-" is non-empty,
hence built-in.o is always created without such a trick.
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
---
arch/arm/plat-samsung/Makefile | 1 -
drivers/clk/shmobile/Makefile | 2 --
drivers/net/wimax/Makefile | 4 ----
3 files changed, 7 deletions(-)
diff --git a/arch/arm/plat-samsung/Makefile b/arch/arm/plat-samsung/Makefile
index 5fe1750..a402262 100644
--- a/arch/arm/plat-samsung/Makefile
+++ b/arch/arm/plat-samsung/Makefile
@@ -8,7 +8,6 @@ ccflags-$(CONFIG_ARCH_MULTI_V7) += -I$(srctree)/$(src)/include
obj-y :=
obj-m :=
-obj-n := dummy.o
obj- :=
# Objects we always build independent of SoC choice
diff --git a/drivers/clk/shmobile/Makefile b/drivers/clk/shmobile/Makefile
index e002923..9aab51c8 100644
--- a/drivers/clk/shmobile/Makefile
+++ b/drivers/clk/shmobile/Makefile
@@ -6,5 +6,3 @@ obj-$(CONFIG_ARCH_R8A7790) += clk-rcar-gen2.o
obj-$(CONFIG_ARCH_R8A7791) += clk-rcar-gen2.o
obj-$(CONFIG_ARCH_SHMOBILE_MULTI) += clk-div6.o
obj-$(CONFIG_ARCH_SHMOBILE_MULTI) += clk-mstp.o
-# for emply built-in.o
-obj-n := dummy
diff --git a/drivers/net/wimax/Makefile b/drivers/net/wimax/Makefile
index 992bc02..692184d 100644
--- a/drivers/net/wimax/Makefile
+++ b/drivers/net/wimax/Makefile
@@ -1,5 +1 @@
-
obj-$(CONFIG_WIMAX_I2400M) += i2400m/
-
-# (from Sam Ravnborg) force kbuild to create built-in.o
-obj- := dummy.o
--
1.9.1
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [PATCH 2/3] kbuild: remove unnecessary variable initializaions
2014-09-09 10:26 [PATCH 0/3] kbuild: Clean up makefiles and then drop obj-n an obj-n Masahiro Yamada
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
@ 2014-09-09 10:26 ` Masahiro Yamada
2014-09-09 11:52 ` Nicolas Ferre
` (2 more replies)
2014-09-09 10:26 ` [PATCH 3/3] kbuild: remove obj-n and lib-n handling Masahiro Yamada
2 siblings, 3 replies; 18+ messages in thread
From: Masahiro Yamada @ 2014-09-09 10:26 UTC (permalink / raw)
To: linux-kbuild
Cc: Masahiro Yamada, Andrew Victor, Nicolas Ferre,
Jean-Christophe Plagniol-Villard, Russell King, Hartley Sweeten,
Ryan Mallon, Kukjin Kim, Greg Ungerer, Ben Dooks, Linus Walleij,
Tony Lindgren, linux-arm-kernel, linux-kernel, linux-samsung-soc,
linux-omap
Clearing obj-y, obj-m, obj-n, obj- in each Makefile is
a useless habit.
They are non-exported variables; therefore they are always empty
whenever descending into each subdirectory.
(Moreorver, obj-y and obj-m are also set to empty at the beginning
of scripts/Makefile.build)
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
---
arch/arm/mach-at91/Makefile | 3 ---
arch/arm/mach-ebsa110/Makefile | 3 ---
arch/arm/mach-ep93xx/Makefile | 3 ---
arch/arm/mach-exynos/Makefile | 5 -----
| 3 ---
arch/arm/mach-iop13xx/Makefile | 5 -----
arch/arm/mach-iop32x/Makefile | 3 ---
arch/arm/mach-iop33x/Makefile | 3 ---
arch/arm/mach-ks8695/Makefile | 3 ---
arch/arm/mach-rpc/Makefile | 4 ----
arch/arm/mach-s3c24xx/Makefile | 5 -----
arch/arm/mach-s3c64xx/Makefile | 5 -----
arch/arm/mach-s5pv210/Makefile | 5 -----
arch/arm/mach-sa1100/Makefile | 3 ---
arch/arm/mach-u300/Makefile | 3 ---
arch/arm/plat-iop/Makefile | 6 ------
arch/arm/plat-omap/Makefile | 3 ---
arch/arm/plat-samsung/Makefile | 4 ----
18 files changed, 69 deletions(-)
diff --git a/arch/arm/mach-at91/Makefile b/arch/arm/mach-at91/Makefile
index 78e9cec..75033839 100644
--- a/arch/arm/mach-at91/Makefile
+++ b/arch/arm/mach-at91/Makefile
@@ -3,9 +3,6 @@
#
obj-y := irq.o gpio.o setup.o sysirq_mask.o
-obj-m :=
-obj-n :=
-obj- :=
obj-$(CONFIG_OLD_CLK_AT91) += clock.o
obj-$(CONFIG_AT91_SAM9_ALT_RESET) += at91sam9_alt_reset.o
diff --git a/arch/arm/mach-ebsa110/Makefile b/arch/arm/mach-ebsa110/Makefile
index 935e4af..a7d68c1 100644
--- a/arch/arm/mach-ebsa110/Makefile
+++ b/arch/arm/mach-ebsa110/Makefile
@@ -5,6 +5,3 @@
# Object file lists.
obj-y := core.o io.o leds.o
-obj-m :=
-obj-n :=
-obj- :=
diff --git a/arch/arm/mach-ep93xx/Makefile b/arch/arm/mach-ep93xx/Makefile
index 0dc51f9..78d427b 100644
--- a/arch/arm/mach-ep93xx/Makefile
+++ b/arch/arm/mach-ep93xx/Makefile
@@ -2,9 +2,6 @@
# Makefile for the linux kernel.
#
obj-y := core.o clock.o
-obj-m :=
-obj-n :=
-obj- :=
obj-$(CONFIG_EP93XX_DMA) += dma.o
diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile
index 788f26d..27ae614 100644
--- a/arch/arm/mach-exynos/Makefile
+++ b/arch/arm/mach-exynos/Makefile
@@ -7,11 +7,6 @@
ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
-obj-y :=
-obj-m :=
-obj-n :=
-obj- :=
-
# Core
obj-$(CONFIG_ARCH_EXYNOS) += exynos.o pmu.o exynos-smc.o firmware.o
--git a/arch/arm/mach-footbridge/Makefile b/arch/arm/mach-footbridge/Makefile
index c3faa3b..e83d5c8 100644
--- a/arch/arm/mach-footbridge/Makefile
+++ b/arch/arm/mach-footbridge/Makefile
@@ -5,9 +5,6 @@
# Object file lists.
obj-y := common.o dma.o isa-irq.o
-obj-m :=
-obj-n :=
-obj- :=
pci-y += dc21285.o
pci-$(CONFIG_ARCH_CATS) += cats-pci.o
diff --git a/arch/arm/mach-iop13xx/Makefile b/arch/arm/mach-iop13xx/Makefile
index cad015f..a3d9260 100644
--- a/arch/arm/mach-iop13xx/Makefile
+++ b/arch/arm/mach-iop13xx/Makefile
@@ -1,8 +1,3 @@
-obj-y :=
-obj-m :=
-obj-n :=
-obj- :=
-
obj-$(CONFIG_ARCH_IOP13XX) += setup.o
obj-$(CONFIG_ARCH_IOP13XX) += irq.o
obj-$(CONFIG_ARCH_IOP13XX) += pci.o
diff --git a/arch/arm/mach-iop32x/Makefile b/arch/arm/mach-iop32x/Makefile
index cfdf8a1..2d4010a 100644
--- a/arch/arm/mach-iop32x/Makefile
+++ b/arch/arm/mach-iop32x/Makefile
@@ -3,9 +3,6 @@
#
obj-y := irq.o
-obj-m :=
-obj-n :=
-obj- :=
obj-$(CONFIG_MACH_GLANTANK) += glantank.o
obj-$(CONFIG_ARCH_IQ80321) += iq80321.o
diff --git a/arch/arm/mach-iop33x/Makefile b/arch/arm/mach-iop33x/Makefile
index 90081d8..e95db30 100644
--- a/arch/arm/mach-iop33x/Makefile
+++ b/arch/arm/mach-iop33x/Makefile
@@ -3,9 +3,6 @@
#
obj-y := irq.o uart.o
-obj-m :=
-obj-n :=
-obj- :=
obj-$(CONFIG_ARCH_IQ80331) += iq80331.o
obj-$(CONFIG_MACH_IQ80332) += iq80332.o
diff --git a/arch/arm/mach-ks8695/Makefile b/arch/arm/mach-ks8695/Makefile
index e370caf..8ecb797 100644
--- a/arch/arm/mach-ks8695/Makefile
+++ b/arch/arm/mach-ks8695/Makefile
@@ -4,9 +4,6 @@
#
obj-y := cpu.o irq.o time.o devices.o
-obj-m :=
-obj-n :=
-obj- :=
# PCI support is optional
obj-$(CONFIG_PCI) += pci.o
diff --git a/arch/arm/mach-rpc/Makefile b/arch/arm/mach-rpc/Makefile
index 992e28b..2ebc687 100644
--- a/arch/arm/mach-rpc/Makefile
+++ b/arch/arm/mach-rpc/Makefile
@@ -5,7 +5,3 @@
# Object file lists.
obj-y := dma.o ecard.o fiq.o irq.o riscpc.o time.o
-obj-m :=
-obj-n :=
-obj- :=
-
diff --git a/arch/arm/mach-s3c24xx/Makefile b/arch/arm/mach-s3c24xx/Makefile
index 2235d0d..b920716 100644
--- a/arch/arm/mach-s3c24xx/Makefile
+++ b/arch/arm/mach-s3c24xx/Makefile
@@ -7,11 +7,6 @@
#
# Licensed under GPLv2
-obj-y :=
-obj-m :=
-obj-n :=
-obj- :=
-
# core
obj-y += common.o
diff --git a/arch/arm/mach-s3c64xx/Makefile b/arch/arm/mach-s3c64xx/Makefile
index 58069a7..12f67b6 100644
--- a/arch/arm/mach-s3c64xx/Makefile
+++ b/arch/arm/mach-s3c64xx/Makefile
@@ -5,11 +5,6 @@
#
# Licensed under GPLv2
-obj-y :=
-obj-m :=
-obj-n :=
-obj- :=
-
# Core
obj-y += common.o
diff --git a/arch/arm/mach-s5pv210/Makefile b/arch/arm/mach-s5pv210/Makefile
index 7dc2d0e..72b9e96 100644
--- a/arch/arm/mach-s5pv210/Makefile
+++ b/arch/arm/mach-s5pv210/Makefile
@@ -7,11 +7,6 @@
ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
-obj-y :=
-obj-m :=
-obj-n :=
-obj- :=
-
# Core
obj-$(CONFIG_PM_SLEEP) += pm.o sleep.o
diff --git a/arch/arm/mach-sa1100/Makefile b/arch/arm/mach-sa1100/Makefile
index 2732eef..f1114d1 100644
--- a/arch/arm/mach-sa1100/Makefile
+++ b/arch/arm/mach-sa1100/Makefile
@@ -4,9 +4,6 @@
# Common support
obj-y := clock.o generic.o irq.o time.o #nmi-oopser.o
-obj-m :=
-obj-n :=
-obj- :=
# Specific board support
obj-$(CONFIG_SA1100_ASSABET) += assabet.o
diff --git a/arch/arm/mach-u300/Makefile b/arch/arm/mach-u300/Makefile
index 3ec74ac..87d37de 100644
--- a/arch/arm/mach-u300/Makefile
+++ b/arch/arm/mach-u300/Makefile
@@ -3,9 +3,6 @@
#
obj-y := core.o
-obj-m :=
-obj-n :=
-obj- :=
obj-$(CONFIG_MACH_U300_SPIDUMMY) += dummyspichip.o
obj-$(CONFIG_REGULATOR_AB3100) += regulator.o
diff --git a/arch/arm/plat-iop/Makefile b/arch/arm/plat-iop/Makefile
index 224e56c..f2af203 100644
--- a/arch/arm/plat-iop/Makefile
+++ b/arch/arm/plat-iop/Makefile
@@ -2,8 +2,6 @@
# Makefile for the linux kernel.
#
-obj-y :=
-
# IOP32X
obj-$(CONFIG_ARCH_IOP32X) += i2c.o
obj-$(CONFIG_ARCH_IOP32X) += pci.o
@@ -27,7 +25,3 @@ obj-$(CONFIG_ARCH_IOP33X) += restart.o
# IOP13XX
obj-$(CONFIG_ARCH_IOP13XX) += cp6.o
obj-$(CONFIG_ARCH_IOP13XX) += time.o
-
-obj-m :=
-obj-n :=
-obj- :=
diff --git a/arch/arm/plat-omap/Makefile b/arch/arm/plat-omap/Makefile
index 0b01b68..97a50e8 100644
--- a/arch/arm/plat-omap/Makefile
+++ b/arch/arm/plat-omap/Makefile
@@ -6,9 +6,6 @@ ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/plat-omap/include
# Common support
obj-y := sram.o dma.o counter_32k.o
-obj-m :=
-obj-n :=
-obj- :=
# omap_device support (OMAP2+ only at the moment)
diff --git a/arch/arm/plat-samsung/Makefile b/arch/arm/plat-samsung/Makefile
index a402262..f0a0084 100644
--- a/arch/arm/plat-samsung/Makefile
+++ b/arch/arm/plat-samsung/Makefile
@@ -6,10 +6,6 @@
ccflags-$(CONFIG_ARCH_MULTI_V7) += -I$(srctree)/$(src)/include
-obj-y :=
-obj-m :=
-obj- :=
-
# Objects we always build independent of SoC choice
obj-y += init.o cpu.o
--
1.9.1
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [PATCH 3/3] kbuild: remove obj-n and lib-n handling
2014-09-09 10:26 [PATCH 0/3] kbuild: Clean up makefiles and then drop obj-n an obj-n Masahiro Yamada
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
2014-09-09 10:26 ` [PATCH 2/3] kbuild: remove unnecessary variable initializaions Masahiro Yamada
@ 2014-09-09 10:26 ` Masahiro Yamada
2014-09-09 16:20 ` Peter Foley
` (2 more replies)
2 siblings, 3 replies; 18+ messages in thread
From: Masahiro Yamada @ 2014-09-09 10:26 UTC (permalink / raw)
To: linux-kbuild; +Cc: Masahiro Yamada, Michal Marek, Sam Ravnborg, linux-kernel
Kconfig never defines CONFIG_* as 'n'.
Now obj-n is only used in firmware/Makefile and it can be
replaced with obj-. No makefile uses lib-n.
Let's rip off obj-n and lib-n.
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
---
firmware/Makefile | 2 +-
scripts/Makefile.build | 4 ++--
scripts/Makefile.clean | 4 +---
scripts/Makefile.fwinst | 2 +-
4 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/firmware/Makefile b/firmware/Makefile
index 0862d34..e297e1b 100644
--- a/firmware/Makefile
+++ b/firmware/Makefile
@@ -232,6 +232,6 @@ targets := $(fw-shipped-) $(patsubst $(obj)/%,%, \
# Without this, built-in.o won't be created when it's empty, and the
# final vmlinux link will fail.
-obj-n := dummy
+obj- := dummy
hostprogs-y := ihex2fw
diff --git a/scripts/Makefile.build b/scripts/Makefile.build
index 5b09d36..649ce68 100644
--- a/scripts/Makefile.build
+++ b/scripts/Makefile.build
@@ -79,11 +79,11 @@ endif
# ===========================================================================
-ifneq ($(strip $(lib-y) $(lib-m) $(lib-n) $(lib-)),)
+ifneq ($(strip $(lib-y) $(lib-m) $(lib-)),)
lib-target := $(obj)/lib.a
endif
-ifneq ($(strip $(obj-y) $(obj-m) $(obj-n) $(obj-) $(subdir-m) $(lib-target)),)
+ifneq ($(strip $(obj-y) $(obj-m) $(obj-) $(subdir-m) $(lib-target)),)
builtin-target := $(obj)/built-in.o
endif
diff --git a/scripts/Makefile.clean b/scripts/Makefile.clean
index a651cee..c630ab5 100644
--- a/scripts/Makefile.clean
+++ b/scripts/Makefile.clean
@@ -23,15 +23,13 @@ __subdir-y := $(patsubst %/,%,$(filter %/, $(obj-y)))
subdir-y += $(__subdir-y)
__subdir-m := $(patsubst %/,%,$(filter %/, $(obj-m)))
subdir-m += $(__subdir-m)
-__subdir-n := $(patsubst %/,%,$(filter %/, $(obj-n)))
-subdir-n += $(__subdir-n)
__subdir- := $(patsubst %/,%,$(filter %/, $(obj-)))
subdir- += $(__subdir-)
# Subdirectories we need to descend into
subdir-ym := $(sort $(subdir-y) $(subdir-m))
-subdir-ymn := $(sort $(subdir-ym) $(subdir-n) $(subdir-))
+subdir-ymn := $(sort $(subdir-ym) $(subdir-))
# Add subdir path
diff --git a/scripts/Makefile.fwinst b/scripts/Makefile.fwinst
index d8e335e..5b698ad 100644
--- a/scripts/Makefile.fwinst
+++ b/scripts/Makefile.fwinst
@@ -2,7 +2,7 @@
# Installing firmware
#
# We don't include the .config, so all firmware files are in $(fw-shipped-)
-# rather than in $(fw-shipped-y) or $(fw-shipped-n).
+# rather than in $(fw-shipped-y) or $(fw-shipped-m).
# ==========================================================================
INSTALL := install
--
1.9.1
^ permalink raw reply related [flat|nested] 18+ messages in thread
* Re: [PATCH 2/3] kbuild: remove unnecessary variable initializaions
2014-09-09 10:26 ` [PATCH 2/3] kbuild: remove unnecessary variable initializaions Masahiro Yamada
@ 2014-09-09 11:52 ` Nicolas Ferre
2014-09-09 16:23 ` Peter Foley
2014-09-23 14:56 ` Linus Walleij
2 siblings, 0 replies; 18+ messages in thread
From: Nicolas Ferre @ 2014-09-09 11:52 UTC (permalink / raw)
To: Masahiro Yamada, linux-kbuild
Cc: Kukjin Kim, Russell King, Ryan Mallon, Tony Lindgren,
Linus Walleij, linux-kernel, Hartley Sweeten, linux-samsung-soc,
Ben Dooks, Greg Ungerer, linux-omap,
Jean-Christophe Plagniol-Villard, Andrew Victor,
linux-arm-kernel
On 09/09/2014 12:26, Masahiro Yamada :
> Clearing obj-y, obj-m, obj-n, obj- in each Makefile is
> a useless habit.
>
> They are non-exported variables; therefore they are always empty
> whenever descending into each subdirectory.
> (Moreorver, obj-y and obj-m are also set to empty at the beginning
> of scripts/Makefile.build)
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> ---
>
> arch/arm/mach-at91/Makefile | 3 ---
> arch/arm/mach-ebsa110/Makefile | 3 ---
> arch/arm/mach-ep93xx/Makefile | 3 ---
> arch/arm/mach-exynos/Makefile | 5 -----
> arch/arm/mach-footbridge/Makefile | 3 ---
> arch/arm/mach-iop13xx/Makefile | 5 -----
> arch/arm/mach-iop32x/Makefile | 3 ---
> arch/arm/mach-iop33x/Makefile | 3 ---
> arch/arm/mach-ks8695/Makefile | 3 ---
> arch/arm/mach-rpc/Makefile | 4 ----
> arch/arm/mach-s3c24xx/Makefile | 5 -----
> arch/arm/mach-s3c64xx/Makefile | 5 -----
> arch/arm/mach-s5pv210/Makefile | 5 -----
> arch/arm/mach-sa1100/Makefile | 3 ---
> arch/arm/mach-u300/Makefile | 3 ---
> arch/arm/plat-iop/Makefile | 6 ------
> arch/arm/plat-omap/Makefile | 3 ---
> arch/arm/plat-samsung/Makefile | 4 ----
> 18 files changed, 69 deletions(-)
>
> diff --git a/arch/arm/mach-at91/Makefile b/arch/arm/mach-at91/Makefile
> index 78e9cec..75033839 100644
> --- a/arch/arm/mach-at91/Makefile
> +++ b/arch/arm/mach-at91/Makefile
> @@ -3,9 +3,6 @@
> #
>
> obj-y := irq.o gpio.o setup.o sysirq_mask.o
> -obj-m :=
> -obj-n :=
> -obj- :=
I agree:
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
But I have patches that will mess with these changes already queued for
3.18. You may have to signal these conflicts when carrying the patch
upstream.
Thanks, best regards,
> obj-$(CONFIG_OLD_CLK_AT91) += clock.o
> obj-$(CONFIG_AT91_SAM9_ALT_RESET) += at91sam9_alt_reset.o
> diff --git a/arch/arm/mach-ebsa110/Makefile b/arch/arm/mach-ebsa110/Makefile
> index 935e4af..a7d68c1 100644
> --- a/arch/arm/mach-ebsa110/Makefile
> +++ b/arch/arm/mach-ebsa110/Makefile
> @@ -5,6 +5,3 @@
> # Object file lists.
>
> obj-y := core.o io.o leds.o
> -obj-m :=
> -obj-n :=
> -obj- :=
> diff --git a/arch/arm/mach-ep93xx/Makefile b/arch/arm/mach-ep93xx/Makefile
> index 0dc51f9..78d427b 100644
> --- a/arch/arm/mach-ep93xx/Makefile
> +++ b/arch/arm/mach-ep93xx/Makefile
> @@ -2,9 +2,6 @@
> # Makefile for the linux kernel.
> #
> obj-y := core.o clock.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> obj-$(CONFIG_EP93XX_DMA) += dma.o
>
> diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile
> index 788f26d..27ae614 100644
> --- a/arch/arm/mach-exynos/Makefile
> +++ b/arch/arm/mach-exynos/Makefile
> @@ -7,11 +7,6 @@
>
> ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
>
> -obj-y :=
> -obj-m :=
> -obj-n :=
> -obj- :=
> -
> # Core
>
> obj-$(CONFIG_ARCH_EXYNOS) += exynos.o pmu.o exynos-smc.o firmware.o
> diff --git a/arch/arm/mach-footbridge/Makefile b/arch/arm/mach-footbridge/Makefile
> index c3faa3b..e83d5c8 100644
> --- a/arch/arm/mach-footbridge/Makefile
> +++ b/arch/arm/mach-footbridge/Makefile
> @@ -5,9 +5,6 @@
> # Object file lists.
>
> obj-y := common.o dma.o isa-irq.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> pci-y += dc21285.o
> pci-$(CONFIG_ARCH_CATS) += cats-pci.o
> diff --git a/arch/arm/mach-iop13xx/Makefile b/arch/arm/mach-iop13xx/Makefile
> index cad015f..a3d9260 100644
> --- a/arch/arm/mach-iop13xx/Makefile
> +++ b/arch/arm/mach-iop13xx/Makefile
> @@ -1,8 +1,3 @@
> -obj-y :=
> -obj-m :=
> -obj-n :=
> -obj- :=
> -
> obj-$(CONFIG_ARCH_IOP13XX) += setup.o
> obj-$(CONFIG_ARCH_IOP13XX) += irq.o
> obj-$(CONFIG_ARCH_IOP13XX) += pci.o
> diff --git a/arch/arm/mach-iop32x/Makefile b/arch/arm/mach-iop32x/Makefile
> index cfdf8a1..2d4010a 100644
> --- a/arch/arm/mach-iop32x/Makefile
> +++ b/arch/arm/mach-iop32x/Makefile
> @@ -3,9 +3,6 @@
> #
>
> obj-y := irq.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> obj-$(CONFIG_MACH_GLANTANK) += glantank.o
> obj-$(CONFIG_ARCH_IQ80321) += iq80321.o
> diff --git a/arch/arm/mach-iop33x/Makefile b/arch/arm/mach-iop33x/Makefile
> index 90081d8..e95db30 100644
> --- a/arch/arm/mach-iop33x/Makefile
> +++ b/arch/arm/mach-iop33x/Makefile
> @@ -3,9 +3,6 @@
> #
>
> obj-y := irq.o uart.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> obj-$(CONFIG_ARCH_IQ80331) += iq80331.o
> obj-$(CONFIG_MACH_IQ80332) += iq80332.o
> diff --git a/arch/arm/mach-ks8695/Makefile b/arch/arm/mach-ks8695/Makefile
> index e370caf..8ecb797 100644
> --- a/arch/arm/mach-ks8695/Makefile
> +++ b/arch/arm/mach-ks8695/Makefile
> @@ -4,9 +4,6 @@
> #
>
> obj-y := cpu.o irq.o time.o devices.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> # PCI support is optional
> obj-$(CONFIG_PCI) += pci.o
> diff --git a/arch/arm/mach-rpc/Makefile b/arch/arm/mach-rpc/Makefile
> index 992e28b..2ebc687 100644
> --- a/arch/arm/mach-rpc/Makefile
> +++ b/arch/arm/mach-rpc/Makefile
> @@ -5,7 +5,3 @@
> # Object file lists.
>
> obj-y := dma.o ecard.o fiq.o irq.o riscpc.o time.o
> -obj-m :=
> -obj-n :=
> -obj- :=
> -
> diff --git a/arch/arm/mach-s3c24xx/Makefile b/arch/arm/mach-s3c24xx/Makefile
> index 2235d0d..b920716 100644
> --- a/arch/arm/mach-s3c24xx/Makefile
> +++ b/arch/arm/mach-s3c24xx/Makefile
> @@ -7,11 +7,6 @@
> #
> # Licensed under GPLv2
>
> -obj-y :=
> -obj-m :=
> -obj-n :=
> -obj- :=
> -
> # core
>
> obj-y += common.o
> diff --git a/arch/arm/mach-s3c64xx/Makefile b/arch/arm/mach-s3c64xx/Makefile
> index 58069a7..12f67b6 100644
> --- a/arch/arm/mach-s3c64xx/Makefile
> +++ b/arch/arm/mach-s3c64xx/Makefile
> @@ -5,11 +5,6 @@
> #
> # Licensed under GPLv2
>
> -obj-y :=
> -obj-m :=
> -obj-n :=
> -obj- :=
> -
> # Core
>
> obj-y += common.o
> diff --git a/arch/arm/mach-s5pv210/Makefile b/arch/arm/mach-s5pv210/Makefile
> index 7dc2d0e..72b9e96 100644
> --- a/arch/arm/mach-s5pv210/Makefile
> +++ b/arch/arm/mach-s5pv210/Makefile
> @@ -7,11 +7,6 @@
>
> ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree)/arch/arm/plat-samsung/include
>
> -obj-y :=
> -obj-m :=
> -obj-n :=
> -obj- :=
> -
> # Core
>
> obj-$(CONFIG_PM_SLEEP) += pm.o sleep.o
> diff --git a/arch/arm/mach-sa1100/Makefile b/arch/arm/mach-sa1100/Makefile
> index 2732eef..f1114d1 100644
> --- a/arch/arm/mach-sa1100/Makefile
> +++ b/arch/arm/mach-sa1100/Makefile
> @@ -4,9 +4,6 @@
>
> # Common support
> obj-y := clock.o generic.o irq.o time.o #nmi-oopser.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> # Specific board support
> obj-$(CONFIG_SA1100_ASSABET) += assabet.o
> diff --git a/arch/arm/mach-u300/Makefile b/arch/arm/mach-u300/Makefile
> index 3ec74ac..87d37de 100644
> --- a/arch/arm/mach-u300/Makefile
> +++ b/arch/arm/mach-u300/Makefile
> @@ -3,9 +3,6 @@
> #
>
> obj-y := core.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> obj-$(CONFIG_MACH_U300_SPIDUMMY) += dummyspichip.o
> obj-$(CONFIG_REGULATOR_AB3100) += regulator.o
> diff --git a/arch/arm/plat-iop/Makefile b/arch/arm/plat-iop/Makefile
> index 224e56c..f2af203 100644
> --- a/arch/arm/plat-iop/Makefile
> +++ b/arch/arm/plat-iop/Makefile
> @@ -2,8 +2,6 @@
> # Makefile for the linux kernel.
> #
>
> -obj-y :=
> -
> # IOP32X
> obj-$(CONFIG_ARCH_IOP32X) += i2c.o
> obj-$(CONFIG_ARCH_IOP32X) += pci.o
> @@ -27,7 +25,3 @@ obj-$(CONFIG_ARCH_IOP33X) += restart.o
> # IOP13XX
> obj-$(CONFIG_ARCH_IOP13XX) += cp6.o
> obj-$(CONFIG_ARCH_IOP13XX) += time.o
> -
> -obj-m :=
> -obj-n :=
> -obj- :=
> diff --git a/arch/arm/plat-omap/Makefile b/arch/arm/plat-omap/Makefile
> index 0b01b68..97a50e8 100644
> --- a/arch/arm/plat-omap/Makefile
> +++ b/arch/arm/plat-omap/Makefile
> @@ -6,9 +6,6 @@ ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/plat-omap/include
>
> # Common support
> obj-y := sram.o dma.o counter_32k.o
> -obj-m :=
> -obj-n :=
> -obj- :=
>
> # omap_device support (OMAP2+ only at the moment)
>
> diff --git a/arch/arm/plat-samsung/Makefile b/arch/arm/plat-samsung/Makefile
> index a402262..f0a0084 100644
> --- a/arch/arm/plat-samsung/Makefile
> +++ b/arch/arm/plat-samsung/Makefile
> @@ -6,10 +6,6 @@
>
> ccflags-$(CONFIG_ARCH_MULTI_V7) += -I$(srctree)/$(src)/include
>
> -obj-y :=
> -obj-m :=
> -obj- :=
> -
> # Objects we always build independent of SoC choice
>
> obj-y += init.o cpu.o
>
--
Nicolas Ferre
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 3/3] kbuild: remove obj-n and lib-n handling
2014-09-09 10:26 ` [PATCH 3/3] kbuild: remove obj-n and lib-n handling Masahiro Yamada
@ 2014-09-09 16:20 ` Peter Foley
2014-10-02 13:02 ` Michal Marek
2014-10-02 13:04 ` Michal Marek
2 siblings, 0 replies; 18+ messages in thread
From: Peter Foley @ 2014-09-09 16:20 UTC (permalink / raw)
To: Masahiro Yamada; +Cc: linux-kbuild, Michal Marek, Sam Ravnborg, LKML
On Tue, Sep 9, 2014 at 6:26 AM, Masahiro Yamada
<yamada.m@jp.panasonic.com> wrote:
> Kconfig never defines CONFIG_* as 'n'.
> Now obj-n is only used in firmware/Makefile and it can be
> replaced with obj-. No makefile uses lib-n.
>
> Let's rip off obj-n and lib-n.
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Peter Foley <pefoley2@pefoley.com>
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
@ 2014-09-09 16:21 ` Peter Foley
2014-09-09 17:43 ` Mike Turquette
2014-09-10 3:40 ` David Miller
2 siblings, 0 replies; 18+ messages in thread
From: Peter Foley @ 2014-09-09 16:21 UTC (permalink / raw)
To: Masahiro Yamada
Cc: linux-kbuild, Ben Dooks, Kukjin Kim, Russell King,
Mike Turquette, Laurent Pinchart, Simon Horman,
Geert Uytterhoeven, Wolfram Sang, Takashi Yoshii, Ulrich Hecht,
linux-arm-kernel, linux-samsung-soc, LKML, netdev
On Tue, Sep 9, 2014 at 6:26 AM, Masahiro Yamada
<yamada.m@jp.panasonic.com> wrote:
> In these Makefiles, at least one of "obj-y" and "obj-" is non-empty,
> hence built-in.o is always created without such a trick.
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Peter Foley <pefoley2@pefoley.com>
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 2/3] kbuild: remove unnecessary variable initializaions
2014-09-09 10:26 ` [PATCH 2/3] kbuild: remove unnecessary variable initializaions Masahiro Yamada
2014-09-09 11:52 ` Nicolas Ferre
@ 2014-09-09 16:23 ` Peter Foley
2014-09-23 14:56 ` Linus Walleij
2 siblings, 0 replies; 18+ messages in thread
From: Peter Foley @ 2014-09-09 16:23 UTC (permalink / raw)
To: Masahiro Yamada
Cc: linux-kbuild, Andrew Victor, Nicolas Ferre,
Jean-Christophe Plagniol-Villard, Russell King, Hartley Sweeten,
Ryan Mallon, Kukjin Kim, Greg Ungerer, Ben Dooks, Linus Walleij,
Tony Lindgren, linux-arm-kernel, LKML, linux-samsung-soc,
linux-omap
On Tue, Sep 9, 2014 at 6:26 AM, Masahiro Yamada
<yamada.m@jp.panasonic.com> wrote:
> Clearing obj-y, obj-m, obj-n, obj- in each Makefile is
> a useless habit.
>
> They are non-exported variables; therefore they are always empty
> whenever descending into each subdirectory.
> (Moreorver, obj-y and obj-m are also set to empty at the beginning
> of scripts/Makefile.build)
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Peter Foley <pefoley2@pefoley.com>
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
2014-09-09 16:21 ` Peter Foley
@ 2014-09-09 17:43 ` Mike Turquette
2014-09-09 23:45 ` Simon Horman
2014-09-10 3:40 ` David Miller
2 siblings, 1 reply; 18+ messages in thread
From: Mike Turquette @ 2014-09-09 17:43 UTC (permalink / raw)
To: Masahiro Yamada, linux-kbuild
Cc: Ben Dooks, Kukjin Kim, Russell King, Laurent Pinchart,
Simon Horman, Geert Uytterhoeven, Wolfram Sang, Takashi Yoshii,
Ulrich Hecht, linux-arm-kernel, linux-samsung-soc, linux-kernel,
netdev
Quoting Masahiro Yamada (2014-09-09 03:26:19)
> In these Makefiles, at least one of "obj-y" and "obj-" is non-empty,
> hence built-in.o is always created without such a trick.
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Mike Turquette <mturquette@linaro.org>
> ---
>
> arch/arm/plat-samsung/Makefile | 1 -
> drivers/clk/shmobile/Makefile | 2 --
> drivers/net/wimax/Makefile | 4 ----
> 3 files changed, 7 deletions(-)
>
> diff --git a/arch/arm/plat-samsung/Makefile b/arch/arm/plat-samsung/Makefile
> index 5fe1750..a402262 100644
> --- a/arch/arm/plat-samsung/Makefile
> +++ b/arch/arm/plat-samsung/Makefile
> @@ -8,7 +8,6 @@ ccflags-$(CONFIG_ARCH_MULTI_V7) += -I$(srctree)/$(src)/include
>
> obj-y :=
> obj-m :=
> -obj-n := dummy.o
> obj- :=
>
> # Objects we always build independent of SoC choice
> diff --git a/drivers/clk/shmobile/Makefile b/drivers/clk/shmobile/Makefile
> index e002923..9aab51c8 100644
> --- a/drivers/clk/shmobile/Makefile
> +++ b/drivers/clk/shmobile/Makefile
> @@ -6,5 +6,3 @@ obj-$(CONFIG_ARCH_R8A7790) += clk-rcar-gen2.o
> obj-$(CONFIG_ARCH_R8A7791) += clk-rcar-gen2.o
> obj-$(CONFIG_ARCH_SHMOBILE_MULTI) += clk-div6.o
> obj-$(CONFIG_ARCH_SHMOBILE_MULTI) += clk-mstp.o
> -# for emply built-in.o
> -obj-n := dummy
> diff --git a/drivers/net/wimax/Makefile b/drivers/net/wimax/Makefile
> index 992bc02..692184d 100644
> --- a/drivers/net/wimax/Makefile
> +++ b/drivers/net/wimax/Makefile
> @@ -1,5 +1 @@
> -
> obj-$(CONFIG_WIMAX_I2400M) += i2400m/
> -
> -# (from Sam Ravnborg) force kbuild to create built-in.o
> -obj- := dummy.o
> --
> 1.9.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/
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick
2014-09-09 17:43 ` Mike Turquette
@ 2014-09-09 23:45 ` Simon Horman
0 siblings, 0 replies; 18+ messages in thread
From: Simon Horman @ 2014-09-09 23:45 UTC (permalink / raw)
To: Mike Turquette
Cc: Masahiro Yamada, linux-kbuild, Ben Dooks, Kukjin Kim,
Russell King, Laurent Pinchart, Geert Uytterhoeven, Wolfram Sang,
Takashi Yoshii, Ulrich Hecht, linux-arm-kernel,
linux-samsung-soc, linux-kernel, netdev
On Tue, Sep 09, 2014 at 10:43:37AM -0700, Mike Turquette wrote:
> Quoting Masahiro Yamada (2014-09-09 03:26:19)
> > In these Makefiles, at least one of "obj-y" and "obj-" is non-empty,
> > hence built-in.o is always created without such a trick.
> >
> > Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
>
> Acked-by: Mike Turquette <mturquette@linaro.org>
shmobile portion:
Acked-by: Simon Horman <horms+renesas@verge.net.au>
>
> > ---
> >
> > arch/arm/plat-samsung/Makefile | 1 -
> > drivers/clk/shmobile/Makefile | 2 --
> > drivers/net/wimax/Makefile | 4 ----
> > 3 files changed, 7 deletions(-)
> >
> > diff --git a/arch/arm/plat-samsung/Makefile b/arch/arm/plat-samsung/Makefile
> > index 5fe1750..a402262 100644
> > --- a/arch/arm/plat-samsung/Makefile
> > +++ b/arch/arm/plat-samsung/Makefile
> > @@ -8,7 +8,6 @@ ccflags-$(CONFIG_ARCH_MULTI_V7) += -I$(srctree)/$(src)/include
> >
> > obj-y :=
> > obj-m :=
> > -obj-n := dummy.o
> > obj- :=
> >
> > # Objects we always build independent of SoC choice
> > diff --git a/drivers/clk/shmobile/Makefile b/drivers/clk/shmobile/Makefile
> > index e002923..9aab51c8 100644
> > --- a/drivers/clk/shmobile/Makefile
> > +++ b/drivers/clk/shmobile/Makefile
> > @@ -6,5 +6,3 @@ obj-$(CONFIG_ARCH_R8A7790) += clk-rcar-gen2.o
> > obj-$(CONFIG_ARCH_R8A7791) += clk-rcar-gen2.o
> > obj-$(CONFIG_ARCH_SHMOBILE_MULTI) += clk-div6.o
> > obj-$(CONFIG_ARCH_SHMOBILE_MULTI) += clk-mstp.o
> > -# for emply built-in.o
> > -obj-n := dummy
> > diff --git a/drivers/net/wimax/Makefile b/drivers/net/wimax/Makefile
> > index 992bc02..692184d 100644
> > --- a/drivers/net/wimax/Makefile
> > +++ b/drivers/net/wimax/Makefile
> > @@ -1,5 +1 @@
> > -
> > obj-$(CONFIG_WIMAX_I2400M) += i2400m/
> > -
> > -# (from Sam Ravnborg) force kbuild to create built-in.o
> > -obj- := dummy.o
> > --
> > 1.9.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/
>
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
2014-09-09 16:21 ` Peter Foley
2014-09-09 17:43 ` Mike Turquette
@ 2014-09-10 3:40 ` David Miller
2 siblings, 0 replies; 18+ messages in thread
From: David Miller @ 2014-09-10 3:40 UTC (permalink / raw)
To: yamada.m
Cc: linux-kbuild, ben-linux, kgene.kim, linux, mturquette,
laurent.pinchart+renesas, horms+renesas, geert, wsa, takasi-y,
ulrich.hecht, linux-arm-kernel, linux-samsung-soc, linux-kernel,
netdev
From: Masahiro Yamada <yamada.m@jp.panasonic.com>
Date: Tue, 9 Sep 2014 19:26:19 +0900
> In these Makefiles, at least one of "obj-y" and "obj-" is non-empty,
> hence built-in.o is always created without such a trick.
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
For networking:
Acked-by: David S. Miller <davem@davemloft.net>
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 2/3] kbuild: remove unnecessary variable initializaions
2014-09-09 10:26 ` [PATCH 2/3] kbuild: remove unnecessary variable initializaions Masahiro Yamada
2014-09-09 11:52 ` Nicolas Ferre
2014-09-09 16:23 ` Peter Foley
@ 2014-09-23 14:56 ` Linus Walleij
2 siblings, 0 replies; 18+ messages in thread
From: Linus Walleij @ 2014-09-23 14:56 UTC (permalink / raw)
To: Masahiro Yamada
Cc: linux-kbuild, Andrew Victor, Nicolas Ferre,
Jean-Christophe Plagniol-Villard, Russell King, Hartley Sweeten,
Ryan Mallon, Kukjin Kim, Greg Ungerer, Ben Dooks, Tony Lindgren,
linux-arm-kernel, linux-kernel, linux-samsung-soc, Linux-OMAP
On Tue, Sep 9, 2014 at 12:26 PM, Masahiro Yamada
<yamada.m@jp.panasonic.com> wrote:
> Clearing obj-y, obj-m, obj-n, obj- in each Makefile is
> a useless habit.
>
> They are non-exported variables; therefore they are always empty
> whenever descending into each subdirectory.
> (Moreorver, obj-y and obj-m are also set to empty at the beginning
> of scripts/Makefile.build)
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 3/3] kbuild: remove obj-n and lib-n handling
2014-09-09 10:26 ` [PATCH 3/3] kbuild: remove obj-n and lib-n handling Masahiro Yamada
2014-09-09 16:20 ` Peter Foley
@ 2014-10-02 13:02 ` Michal Marek
2014-10-02 13:04 ` Michal Marek
2 siblings, 0 replies; 18+ messages in thread
From: Michal Marek @ 2014-10-02 13:02 UTC (permalink / raw)
To: Masahiro Yamada; +Cc: linux-kbuild, Sam Ravnborg, linux-kernel
On 2014-09-09 12:26, Masahiro Yamada wrote:
> Kconfig never defines CONFIG_* as 'n'.
> Now obj-n is only used in firmware/Makefile and it can be
> replaced with obj-. No makefile uses lib-n.
A possible usecase would be overriding CONFIG_ options on the commandline:
make CONFIG_FOOBAR=n
but CONFIG_FOOBAR= works as well.
> Let's rip off obj-n and lib-n.
Agreed, I applied your series to kbuild.git#kbuild now.
Michal
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 3/3] kbuild: remove obj-n and lib-n handling
2014-09-09 10:26 ` [PATCH 3/3] kbuild: remove obj-n and lib-n handling Masahiro Yamada
2014-09-09 16:20 ` Peter Foley
2014-10-02 13:02 ` Michal Marek
@ 2014-10-02 13:04 ` Michal Marek
2014-10-02 13:17 ` Masahiro Yamada
2 siblings, 1 reply; 18+ messages in thread
From: Michal Marek @ 2014-10-02 13:04 UTC (permalink / raw)
To: Masahiro Yamada; +Cc: linux-kbuild, Sam Ravnborg, linux-kernel
On 2014-09-09 12:26, Masahiro Yamada wrote:
> Kconfig never defines CONFIG_* as 'n'.
> Now obj-n is only used in firmware/Makefile and it can be
> replaced with obj-. No makefile uses lib-n.
BTW, there are a few more instances of *-n, none of which seem useful:
$ git --no-pager grep -e '[a-z]-n\>' -- '*Makefile*' '*Kbuild*'
Makefile: $(init-n) $(init-) \
Makefile: $(core-n) $(core-) $(drivers-n) $(drivers-) \
Makefile: $(net-n) $(net-) $(libs-n) $(libs-))))
arch/arm/mach-ixp4xx/Makefile:obj-pci-n :=
arch/powerpc/boot/Makefile:initrd- := $(patsubst zImage%,
zImage.initrd%, $(image-n) $(image-))
Michal
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH 3/3] kbuild: remove obj-n and lib-n handling
2014-10-02 13:04 ` Michal Marek
@ 2014-10-02 13:17 ` Masahiro Yamada
2014-10-02 13:33 ` [PATCH] kbuild: Do not reference *-n variables in the Makefile Michal Marek
0 siblings, 1 reply; 18+ messages in thread
From: Masahiro Yamada @ 2014-10-02 13:17 UTC (permalink / raw)
To: Michal Marek; +Cc: linux-kbuild, Sam Ravnborg, linux-kernel
Hi Michal,
On Thu, 02 Oct 2014 15:04:44 +0200
Michal Marek <mmarek@suse.cz> wrote:
> On 2014-09-09 12:26, Masahiro Yamada wrote:
> > Kconfig never defines CONFIG_* as 'n'.
> > Now obj-n is only used in firmware/Makefile and it can be
> > replaced with obj-. No makefile uses lib-n.
>
> BTW, there are a few more instances of *-n, none of which seem useful:
>
> $ git --no-pager grep -e '[a-z]-n\>' -- '*Makefile*' '*Kbuild*'
> Makefile: $(init-n) $(init-) \
> Makefile: $(core-n) $(core-) $(drivers-n) $(drivers-) \
> Makefile: $(net-n) $(net-) $(libs-n) $(libs-))))
> arch/arm/mach-ixp4xx/Makefile:obj-pci-n :=
> arch/powerpc/boot/Makefile:initrd- := $(patsubst zImage%,
> zImage.initrd%, $(image-n) $(image-))
Uh, I missed them.
Anyway, it should be done in a separate patch
even if we fix them.
Can you fix them, please?
(I do not want to steal what you found.)
Simpler makefiles seem better.
Best Regards
Masahiro Yamada
^ permalink raw reply [flat|nested] 18+ messages in thread
* [PATCH] kbuild: Do not reference *-n variables in the Makefile
2014-10-02 13:17 ` Masahiro Yamada
@ 2014-10-02 13:33 ` Michal Marek
2014-10-02 13:35 ` Michal Marek
0 siblings, 1 reply; 18+ messages in thread
From: Michal Marek @ 2014-10-02 13:33 UTC (permalink / raw)
To: linux-kbuild; +Cc: sam, yamada.m, linux-kernel
Kconfig options are either 'y', 'm', or undefined.
Signed-off-by: Michal Marek <mmarek@suse.cz>
---
Makefile | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index efbd2cb..106f300 100644
--- a/Makefile
+++ b/Makefile
@@ -868,9 +868,7 @@ vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
$(net-y) $(net-m) $(libs-y) $(libs-m)))
vmlinux-alldirs := $(sort $(vmlinux-dirs) $(patsubst %/,%,$(filter %/, \
- $(init-n) $(init-) \
- $(core-n) $(core-) $(drivers-n) $(drivers-) \
- $(net-n) $(net-) $(libs-n) $(libs-))))
+ $(init-) $(core-) $(drivers-) $(net-) $(libs-))))
init-y := $(patsubst %/, %/built-in.o, $(init-y))
core-y := $(patsubst %/, %/built-in.o, $(core-y))
--
1.8.4.5
^ permalink raw reply related [flat|nested] 18+ messages in thread
* Re: [PATCH] kbuild: Do not reference *-n variables in the Makefile
2014-10-02 13:33 ` [PATCH] kbuild: Do not reference *-n variables in the Makefile Michal Marek
@ 2014-10-02 13:35 ` Michal Marek
2014-10-02 13:55 ` Masahiro Yamada
0 siblings, 1 reply; 18+ messages in thread
From: Michal Marek @ 2014-10-02 13:35 UTC (permalink / raw)
To: linux-kbuild; +Cc: sam, yamada.m, linux-kernel
On 2014-10-02 15:33, Michal Marek wrote:
> Kconfig options are either 'y', 'm', or undefined.
>
> Signed-off-by: Michal Marek <mmarek@suse.cz>
> ---
> Makefile | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index efbd2cb..106f300 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -868,9 +868,7 @@ vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
> $(net-y) $(net-m) $(libs-y) $(libs-m)))
>
> vmlinux-alldirs := $(sort $(vmlinux-dirs) $(patsubst %/,%,$(filter %/, \
> - $(init-n) $(init-) \
> - $(core-n) $(core-) $(drivers-n) $(drivers-) \
> - $(net-n) $(net-) $(libs-n) $(libs-))))
> + $(init-) $(core-) $(drivers-) $(net-) $(libs-))))
Actually, all the directories are hardcoded in
{init,code,drivers,net,libs}-y; there are currently no Kconfig variables
involved. But let's keep this generic and handle *-m and *- just in case.
Michal
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] kbuild: Do not reference *-n variables in the Makefile
2014-10-02 13:35 ` Michal Marek
@ 2014-10-02 13:55 ` Masahiro Yamada
0 siblings, 0 replies; 18+ messages in thread
From: Masahiro Yamada @ 2014-10-02 13:55 UTC (permalink / raw)
To: Michal Marek; +Cc: linux-kbuild, sam, linux-kernel
Hi Michal,
On Thu, 02 Oct 2014 15:35:35 +0200
Michal Marek <mmarek@suse.cz> wrote:
> On 2014-10-02 15:33, Michal Marek wrote:
> > Kconfig options are either 'y', 'm', or undefined.
> >
> > Signed-off-by: Michal Marek <mmarek@suse.cz>
> > ---
> > Makefile | 4 +---
> > 1 file changed, 1 insertion(+), 3 deletions(-)
> >
> > diff --git a/Makefile b/Makefile
> > index efbd2cb..106f300 100644
> > --- a/Makefile
> > +++ b/Makefile
> > @@ -868,9 +868,7 @@ vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
> > $(net-y) $(net-m) $(libs-y) $(libs-m)))
> >
> > vmlinux-alldirs := $(sort $(vmlinux-dirs) $(patsubst %/,%,$(filter %/, \
> > - $(init-n) $(init-) \
> > - $(core-n) $(core-) $(drivers-n) $(drivers-) \
> > - $(net-n) $(net-) $(libs-n) $(libs-))))
> > + $(init-) $(core-) $(drivers-) $(net-) $(libs-))))
>
> Actually, all the directories are hardcoded in
> {init,code,drivers,net,libs}-y; there are currently no Kconfig variables
> involved. But let's keep this generic and handle *-m and *- just in case.
>
Agreed and thank you!
Best Regards
Masahiro Yamada
^ permalink raw reply [flat|nested] 18+ messages in thread
end of thread, other threads:[~2014-10-02 13:55 UTC | newest]
Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-09 10:26 [PATCH 0/3] kbuild: Clean up makefiles and then drop obj-n an obj-n Masahiro Yamada
2014-09-09 10:26 ` [PATCH 1/3] kbuild: remove unnecessary "obj- := dummy.o" trick Masahiro Yamada
2014-09-09 16:21 ` Peter Foley
2014-09-09 17:43 ` Mike Turquette
2014-09-09 23:45 ` Simon Horman
2014-09-10 3:40 ` David Miller
2014-09-09 10:26 ` [PATCH 2/3] kbuild: remove unnecessary variable initializaions Masahiro Yamada
2014-09-09 11:52 ` Nicolas Ferre
2014-09-09 16:23 ` Peter Foley
2014-09-23 14:56 ` Linus Walleij
2014-09-09 10:26 ` [PATCH 3/3] kbuild: remove obj-n and lib-n handling Masahiro Yamada
2014-09-09 16:20 ` Peter Foley
2014-10-02 13:02 ` Michal Marek
2014-10-02 13:04 ` Michal Marek
2014-10-02 13:17 ` Masahiro Yamada
2014-10-02 13:33 ` [PATCH] kbuild: Do not reference *-n variables in the Makefile Michal Marek
2014-10-02 13:35 ` Michal Marek
2014-10-02 13:55 ` Masahiro Yamada
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).