summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2008-08-30 23:54:58 +0200
committerJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2008-09-10 21:09:37 +0200
commit32628c5008105a732212003d83b75f05e5243bb2 (patch)
treeea895114f1e465e1bc26cfdca22ad833baa9dcc0
parente5648acab153f0f429bfc714902c5aaa7879f71b (diff)
downloadu-boot-32628c5008105a732212003d83b75f05e5243bb2.tar.gz
u-boot-32628c5008105a732212003d83b75f05e5243bb2.tar.xz
u-boot-32628c5008105a732212003d83b75f05e5243bb2.zip
cmd_mac: Move conditional compilation to Makefile
finish remaning CFG_ID_EEPROM in CONFIG_ID_EEPROM start in commit ad8f8687b78c3e917b173f038926695383c55555 Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
-rw-r--r--common/Makefile2
-rw-r--r--common/cmd_mac.c3
-rw-r--r--include/configs/MPC8536DS.h4
-rw-r--r--include/configs/MPC8610HPCD.h2
-rw-r--r--include/configs/MPC8641HPCN.h2
-rw-r--r--include/configs/sbc8641d.h2
-rw-r--r--lib_ppc/board.c2
-rw-r--r--lib_sparc/board.c2
8 files changed, 8 insertions, 11 deletions
diff --git a/common/Makefile b/common/Makefile
index e9f75f441d..a9a02b2e03 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -111,7 +111,7 @@ COBJS-$(CONFIG_CMD_JFFS2) += cmd_jffs2.o
COBJS-$(CONFIG_CMD_LICENSE) += cmd_license.o
COBJS-y += cmd_load.o
COBJS-$(CONFIG_LOGBUFFER) += cmd_log.o
-COBJS-y += cmd_mac.o
+COBJS-$(CONFIG_ID_EEPROM) += cmd_mac.o
COBJS-y += cmd_mem.o
COBJS-$(CONFIG_CMD_MFSL) += cmd_mfsl.o
COBJS-$(CONFIG_MII) += miiphyutil.o
diff --git a/common/cmd_mac.c b/common/cmd_mac.c
index faed8f763c..4453299fe5 100644
--- a/common/cmd_mac.c
+++ b/common/cmd_mac.c
@@ -24,8 +24,6 @@
#include <common.h>
#include <command.h>
-#ifdef CFG_ID_EEPROM
-
extern int do_mac(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
U_BOOT_CMD(
@@ -63,4 +61,3 @@ U_BOOT_CMD(
"mac 7\n"
" - program the MAC address for port 7\n"
);
-#endif /* CFG_ID_EEPROM */
diff --git a/include/configs/MPC8536DS.h b/include/configs/MPC8536DS.h
index 17cc934e44..dc304e7bca 100644
--- a/include/configs/MPC8536DS.h
+++ b/include/configs/MPC8536DS.h
@@ -301,8 +301,8 @@ extern unsigned long get_board_ddr_clk(unsigned long dummy);
/*
* I2C2 EEPROM
*/
-#define CFG_ID_EEPROM
-#ifdef CFG_ID_EEPROM
+#define CONFIG_ID_EEPROM
+#ifdef CONFIG_ID_EEPROM
#define CONFIG_ID_EEPROM
#define CFG_I2C_EEPROM_NXID
#endif
diff --git a/include/configs/MPC8610HPCD.h b/include/configs/MPC8610HPCD.h
index 0c1c4fc7c4..7c69582804 100644
--- a/include/configs/MPC8610HPCD.h
+++ b/include/configs/MPC8610HPCD.h
@@ -139,7 +139,7 @@
#define CONFIG_ID_EEPROM
#define CFG_I2C_EEPROM_NXID
-#define CFG_ID_EEPROM
+#define CONFIG_ID_EEPROM
#define CFG_I2C_EEPROM_ADDR 0x57
#define CFG_I2C_EEPROM_ADDR_LEN 1
diff --git a/include/configs/MPC8641HPCN.h b/include/configs/MPC8641HPCN.h
index 54a0461075..a57c30331b 100644
--- a/include/configs/MPC8641HPCN.h
+++ b/include/configs/MPC8641HPCN.h
@@ -151,7 +151,7 @@ extern unsigned long get_board_sys_clk(unsigned long dummy);
#define CONFIG_ID_EEPROM
#define CFG_I2C_EEPROM_NXID
-#define CFG_ID_EEPROM
+#define CONFIG_ID_EEPROM
#define CFG_I2C_EEPROM_ADDR 0x57
#define CFG_I2C_EEPROM_ADDR_LEN 1
diff --git a/include/configs/sbc8641d.h b/include/configs/sbc8641d.h
index ddca527c4e..c84240e03d 100644
--- a/include/configs/sbc8641d.h
+++ b/include/configs/sbc8641d.h
@@ -179,7 +179,7 @@
#endif
-/* #define CFG_ID_EEPROM 1
+/* #define CONFIG_ID_EEPROM 1
#define ID_EEPROM_ADDR 0x57 */
/*
diff --git a/lib_ppc/board.c b/lib_ppc/board.c
index c8f075f5a6..4d02eb2850 100644
--- a/lib_ppc/board.c
+++ b/lib_ppc/board.c
@@ -873,7 +873,7 @@ void board_init_r (gd_t *id, ulong dest_addr)
sc3_read_eeprom();
#endif
-#if defined (CFG_ID_EEPROM) || defined (CFG_I2C_MAC_OFFSET)
+#if defined (CONFIG_ID_EEPROM) || defined (CFG_I2C_MAC_OFFSET)
mac_read_from_eeprom();
#endif
diff --git a/lib_sparc/board.c b/lib_sparc/board.c
index 205a8ca532..15d69355ea 100644
--- a/lib_sparc/board.c
+++ b/lib_sparc/board.c
@@ -409,7 +409,7 @@ void board_init_f(ulong bootflag)
}
#endif
-#ifdef CFG_ID_EEPROM
+#ifdef CONFIG_ID_EEPROM
mac_read_from_eeprom();
#endif