Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mmc: Makefile: Fix EXTRA_CFLAGS assignment

The EXTRA_CFLAGS assignment in mmc/Makefile was not accomplishing
anything because this flag only has effect on sources at the same level
as the makefile (i.e., per directory). Since card/, core/, and host/
rely on MMC_DEBUG, the subdir-ccflags-y variant seems to be the
appropriate choice.

Signed-off-by: matt mooney <mfm@muteddisk.com>
Signed-off-by: Chris Ball <cjb@laptop.org>

authored by

matt mooney and committed by
Chris Ball
d3c502b8 412ab659

+1 -15
+1 -3
drivers/mmc/Makefile
··· 2 2 # Makefile for the kernel mmc device drivers. 3 3 # 4 4 5 - ifeq ($(CONFIG_MMC_DEBUG),y) 6 - EXTRA_CFLAGS += -DDEBUG 7 - endif 5 + subdir-ccflags-$(CONFIG_MMC_DEBUG) := -DDEBUG 8 6 9 7 obj-$(CONFIG_MMC) += core/ 10 8 obj-$(CONFIG_MMC) += card/
-4
drivers/mmc/card/Makefile
··· 2 2 # Makefile for MMC/SD card drivers 3 3 # 4 4 5 - ifeq ($(CONFIG_MMC_DEBUG),y) 6 - EXTRA_CFLAGS += -DDEBUG 7 - endif 8 - 9 5 obj-$(CONFIG_MMC_BLOCK) += mmc_block.o 10 6 mmc_block-objs := block.o queue.o 11 7 obj-$(CONFIG_MMC_TEST) += mmc_test.o
-4
drivers/mmc/core/Makefile
··· 2 2 # Makefile for the kernel mmc core. 3 3 # 4 4 5 - ifeq ($(CONFIG_MMC_DEBUG),y) 6 - EXTRA_CFLAGS += -DDEBUG 7 - endif 8 - 9 5 obj-$(CONFIG_MMC) += mmc_core.o 10 6 mmc_core-y := core.o bus.o host.o \ 11 7 mmc.o mmc_ops.o sd.o sd_ops.o \
-4
drivers/mmc/host/Makefile
··· 2 2 # Makefile for MMC/SD host controller drivers 3 3 # 4 4 5 - ifeq ($(CONFIG_MMC_DEBUG),y) 6 - EXTRA_CFLAGS += -DDEBUG 7 - endif 8 - 9 5 obj-$(CONFIG_MMC_ARMMMCI) += mmci.o 10 6 obj-$(CONFIG_MMC_PXA) += pxamci.o 11 7 obj-$(CONFIG_MMC_IMX) += imxmmc.o