From: Jean-Christophe PLAGNIOL-VILLARD Date: Tue, 1 Apr 2008 05:30:51 +0000 (+0200) Subject: dataflash: Move CONFIG_HAS_DATAFLASH to Makefile X-Git-Tag: v1.3.3-rc1~111^2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=b5873f1732b92a25690e1513b90dfb0d644f6697;p=u-boot dataflash: Move CONFIG_HAS_DATAFLASH to Makefile Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD --- diff --git a/drivers/mtd/Makefile b/drivers/mtd/Makefile index 952e919843..ff932a1b6b 100644 --- a/drivers/mtd/Makefile +++ b/drivers/mtd/Makefile @@ -23,17 +23,17 @@ include $(TOPDIR)/config.mk -LIB := $(obj)libmtd.a +LIB := $(obj)libmtd.a COBJS-y += at45.o COBJS-y += cfi_flash.o -COBJS-y += dataflash.o +COBJS-$(CONFIG_HAS_DATAFLASH) += dataflash.o COBJS-y += mw_eeprom.o COBJS-$(CONFIG_FLASH_CFI_LEGACY) += jedec_flash.o COBJS := $(COBJS-y) -SRCS := $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(COBJS)) +SRCS := $(COBJS:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS)) all: $(LIB) diff --git a/drivers/mtd/dataflash.c b/drivers/mtd/dataflash.c index 85cbc5f783..d8f78f20a8 100644 --- a/drivers/mtd/dataflash.c +++ b/drivers/mtd/dataflash.c @@ -19,7 +19,6 @@ */ #include #include -#ifdef CONFIG_HAS_DATAFLASH #include #include @@ -475,5 +474,3 @@ void dataflash_perror (int err) break; } } - -#endif