From: Mike Frysinger Date: Tue, 5 Feb 2008 00:26:54 +0000 (-0500) Subject: make smc91111_eeprom managment simpler by depending on the board configuration file... X-Git-Tag: v1.3.2-rc1~12^2~18 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=32a9f5f2160a034ea87ea651b233ef7c635e55cf;p=u-boot make smc91111_eeprom managment simpler by depending on the board configuration file rather than a hardcoded list of boards Signed-off-by: Mike Frysinger --- diff --git a/examples/.gitignore b/examples/.gitignore index f547024784..059b09641a 100644 --- a/examples/.gitignore +++ b/examples/.gitignore @@ -1,5 +1,6 @@ /hello_world /interrupt /sched +/smc91111_eeprom *.bin *.srec diff --git a/examples/Makefile b/examples/Makefile index 71a8c7f3ab..79af4b07cd 100644 --- a/examples/Makefile +++ b/examples/Makefile @@ -91,13 +91,9 @@ BIN += sched.bin endif ifeq ($(ARCH),blackfin) -ifneq ($(BOARD),bf537-stamp) -ifneq ($(BOARD),bf537-pnav) ELF += smc91111_eeprom SREC += smc91111_eeprom.srec -BIN += smc91111_eeprom.bin -endif -endif +BIN += smc91111_eeprom.bin endif # The following example is pretty 8xx specific... diff --git a/examples/smc91111_eeprom.c b/examples/smc91111_eeprom.c index b8a3594e9e..1e1129a334 100644 --- a/examples/smc91111_eeprom.c +++ b/examples/smc91111_eeprom.c @@ -31,6 +31,8 @@ #include #include "../drivers/net/smc91111.h" +#ifdef CONFIG_DRIVER_SMC91111 + #define SMC_BASE_ADDRESS CONFIG_SMC91111_BASE #define EEPROM 0x1; #define MAC 0x2; @@ -387,3 +389,13 @@ void dump_reg (void) printf ("\n"); } } + +#else + +int smc91111_eeprom (int argc, char *argv[]) +{ + printf("Not supported for this board\n"); + return 1; +} + +#endif