[U-Boot] [PATCH 10/25] eeprom: Zap CONFIG_SYS_I2C_MULTI_EEPROMS

Marek Vasut marex at denx.de
Mon Oct 20 03:48:11 CEST 2014


This option only complicates the code unnecessarily, just use
CONFIG_SYS_DEF_EEPROM_ADDR as the default address if there are
only five arguments to eeprom {read/write} if this is defined.
If CONFIG_SYS_DEF_EEPROM_ADDR is not defined, we mandate all
six arguments.

Signed-off-by: Marek Vasut <marex at denx.de>
Cc: Simon Glass <sjg at chromium.org>
Cc: Tom Rini <trini at ti.com>
Cc: Heiko Schocher <hs at denx.de>
---
 common/cmd_eeprom.c             | 69 ++++++++++++++++++-----------------------
 include/configs/BSC9131RDB.h    |  1 -
 include/configs/BSC9132QDS.h    |  1 -
 include/configs/C29XPCIE.h      |  1 -
 include/configs/CPCI405AB.h     |  1 -
 include/configs/CPCI750.h       |  1 -
 include/configs/DB64360.h       |  1 -
 include/configs/DB64460.h       |  1 -
 include/configs/DU440.h         |  1 -
 include/configs/P1010RDB.h      |  1 -
 include/configs/PMC440.h        |  1 -
 include/configs/TQM834x.h       |  1 -
 include/configs/W7OLMC.h        |  1 -
 include/configs/W7OLMG.h        |  1 -
 include/configs/acadia.h        |  1 -
 include/configs/am335x_evm.h    |  1 -
 include/configs/am43xx_evm.h    |  1 -
 include/configs/axs101.h        |  1 -
 include/configs/bamboo.h        |  1 -
 include/configs/canyonlands.h   |  1 -
 include/configs/cpci5200.h      |  1 -
 include/configs/ebony.h         |  1 -
 include/configs/icon.h          |  1 -
 include/configs/intip.h         |  1 -
 include/configs/katmai.h        |  1 -
 include/configs/km/km-powerpc.h |  1 -
 include/configs/km/km_arm.h     |  1 -
 include/configs/korat.h         |  1 -
 include/configs/ks2_evm.h       |  1 -
 include/configs/luan.h          |  1 -
 include/configs/m28evk.h        |  1 -
 include/configs/mecp5200.h      |  1 -
 include/configs/motionpro.h     |  1 -
 include/configs/ocotea.h        |  1 -
 include/configs/p1_p2_rdb_pc.h  |  1 -
 include/configs/p1_twr.h        |  1 -
 include/configs/pcm051.h        |  1 -
 include/configs/pengwyn.h       |  1 -
 include/configs/pf5200.h        |  1 -
 include/configs/sequoia.h       |  1 -
 include/configs/t3corp.h        |  1 -
 include/configs/taishan.h       |  1 -
 include/configs/tricorder.h     |  1 -
 include/configs/walnut.h        |  1 -
 include/configs/yosemite.h      |  1 -
 45 files changed, 30 insertions(+), 83 deletions(-)

diff --git a/common/cmd_eeprom.c b/common/cmd_eeprom.c
index 17d241d..67de730 100644
--- a/common/cmd_eeprom.c
+++ b/common/cmd_eeprom.c
@@ -337,50 +337,50 @@ static int do_eeprom(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 {
 	const char *const fmt =
 		"\nEEPROM @0x%lX %s: addr %08lx  off %04lx  count %ld ... ";
+	char * const *args = &argv[2];
+	int rcode;
+	ulong dev_addr, addr, off, cnt;
+
+	switch (argc) {
+#ifdef CONFIG_SYS_DEF_EEPROM_ADDR
+	case 5:
+		dev_addr = CONFIG_SYS_DEF_EEPROM_ADDR;
+		break;
+#endif
+	case 6:
+		dev_addr = simple_strtoul(*args++, NULL, 16);
+		break;
+	default:
+		return CMD_RET_USAGE;
+	}
 
-#if defined(CONFIG_SYS_I2C_MULTI_EEPROMS)
-	if (argc == 6) {
-		ulong dev_addr = simple_strtoul (argv[2], NULL, 16);
-		ulong addr = simple_strtoul (argv[3], NULL, 16);
-		ulong off  = simple_strtoul (argv[4], NULL, 16);
-		ulong cnt  = simple_strtoul (argv[5], NULL, 16);
-#else
-	if (argc == 5) {
-		ulong dev_addr = CONFIG_SYS_DEF_EEPROM_ADDR;
-		ulong addr = simple_strtoul (argv[2], NULL, 16);
-		ulong off  = simple_strtoul (argv[3], NULL, 16);
-		ulong cnt  = simple_strtoul (argv[4], NULL, 16);
-#endif /* CONFIG_SYS_I2C_MULTI_EEPROMS */
+	addr = simple_strtoul(*args++, NULL, 16);
+	off = simple_strtoul(*args++, NULL, 16);
+	cnt = simple_strtoul(*args++, NULL, 16);
 
 # if !defined(CONFIG_SPI) || defined(CONFIG_ENV_EEPROM_IS_ON_I2C)
-		eeprom_init ();
+	eeprom_init ();
 # endif /* !CONFIG_SPI */
 
-		if (strcmp (argv[1], "read") == 0) {
-			int rcode;
-
-			printf (fmt, dev_addr, argv[1], addr, off, cnt);
-
-			rcode = eeprom_read (dev_addr, off, (uchar *) addr, cnt);
+	if (strcmp (argv[1], "read") == 0) {
+		printf(fmt, dev_addr, argv[1], addr, off, cnt);
 
-			puts ("done\n");
-			return rcode;
-		} else if (strcmp (argv[1], "write") == 0) {
-			int rcode;
+		rcode = eeprom_read(dev_addr, off, (uchar *) addr, cnt);
 
-			printf (fmt, dev_addr, argv[1], addr, off, cnt);
+		puts ("done\n");
+		return rcode;
+	} else if (strcmp (argv[1], "write") == 0) {
+		printf(fmt, dev_addr, argv[1], addr, off, cnt);
 
-			rcode = eeprom_write (dev_addr, off, (uchar *) addr, cnt);
+		rcode = eeprom_write(dev_addr, off, (uchar *) addr, cnt);
 
-			puts ("done\n");
-			return rcode;
-		}
+		puts ("done\n");
+		return rcode;
 	}
 
 	return CMD_RET_USAGE;
 }
 
-#ifdef CONFIG_SYS_I2C_MULTI_EEPROMS
 U_BOOT_CMD(
 	eeprom,	6,	1,	do_eeprom,
 	"EEPROM sub-system",
@@ -388,12 +388,3 @@ U_BOOT_CMD(
 	"eeprom write devaddr addr off cnt\n"
 	"       - read/write `cnt' bytes from `devaddr` EEPROM at offset `off'"
 )
-#else /* One EEPROM */
-U_BOOT_CMD(
-	eeprom,	5,	1,	do_eeprom,
-	"EEPROM sub-system",
-	"read  addr off cnt\n"
-	"eeprom write addr off cnt\n"
-	"       - read/write `cnt' bytes at EEPROM offset `off'"
-)
-#endif /* CONFIG_SYS_I2C_MULTI_EEPROMS */
diff --git a/include/configs/BSC9131RDB.h b/include/configs/BSC9131RDB.h
index 56a3e94..3d488c7 100644
--- a/include/configs/BSC9131RDB.h
+++ b/include/configs/BSC9131RDB.h
@@ -265,7 +265,6 @@ extern unsigned long get_sdram_size(void);
 
 /* I2C EEPROM */
 #define CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 5
diff --git a/include/configs/BSC9132QDS.h b/include/configs/BSC9132QDS.h
index aeded6d..a75775a 100644
--- a/include/configs/BSC9132QDS.h
+++ b/include/configs/BSC9132QDS.h
@@ -464,7 +464,6 @@ combinations. this should be removed later
 
 /* enable read and write access to EEPROM */
 #define CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 5
diff --git a/include/configs/C29XPCIE.h b/include/configs/C29XPCIE.h
index 715616d..a8da16d 100644
--- a/include/configs/C29XPCIE.h
+++ b/include/configs/C29XPCIE.h
@@ -422,7 +422,6 @@
 /* I2C EEPROM */
 /* enable read and write access to EEPROM */
 #define CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 2
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 5
diff --git a/include/configs/CPCI405AB.h b/include/configs/CPCI405AB.h
index 7d58e9d..94b3efa 100644
--- a/include/configs/CPCI405AB.h
+++ b/include/configs/CPCI405AB.h
@@ -253,7 +253,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 2	/* Bytes of address		*/
 /* mask of address bits that overflow into the "EEPROM chip address"	*/
 #define CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW	0x01
-#define CONFIG_SYS_I2C_MULTI_EEPROMS   1       /* more than one eeprom used!   */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 5	/* The Catalyst CAT24WC32 has	*/
 					/* 32 byte page write mode using*/
 					/* last 5 bits of the address	*/
diff --git a/include/configs/CPCI750.h b/include/configs/CPCI750.h
index 304a12b..c57457b 100644
--- a/include/configs/CPCI750.h
+++ b/include/configs/CPCI750.h
@@ -167,7 +167,6 @@
  * Miscellaneous configurable options
  */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 2
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_SPEED	80000		/* I2C speed default */
 
 #define CONFIG_PRAM 0
diff --git a/include/configs/DB64360.h b/include/configs/DB64360.h
index b77c8b2..03f38c2 100644
--- a/include/configs/DB64360.h
+++ b/include/configs/DB64360.h
@@ -250,7 +250,6 @@ ip=${ipaddr}:${serverip}${bootargs_end}; bootm 0x400000;\0"
  * Miscellaneous configurable options
  */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_SPEED	40000		/* I2C speed default */
 
 /* #define CONFIG_SYS_GT_DUAL_CPU	 also for JTAG even with one cpu */
diff --git a/include/configs/DB64460.h b/include/configs/DB64460.h
index abc4434..96a6254 100644
--- a/include/configs/DB64460.h
+++ b/include/configs/DB64460.h
@@ -188,7 +188,6 @@ ip=${ipaddr}:${serverip}${bootargs_end}; bootm 0x400000;\0"
  * Miscellaneous configurable options
  */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_SPEED	40000		/* I2C speed default */
 
 /* #define CONFIG_SYS_GT_DUAL_CPU	 also for JTAG even with one cpu */
diff --git a/include/configs/DU440.h b/include/configs/DU440.h
index be5494b..4409553 100644
--- a/include/configs/DU440.h
+++ b/include/configs/DU440.h
@@ -170,7 +170,6 @@
 #define IIC1_USB2507_ADDR	0x2c
 #define CONFIG_SYS_I2C_NOPROBES		{ {1, IIC1_USB2507_ADDR} }
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x54
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 2
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 5
diff --git a/include/configs/P1010RDB.h b/include/configs/P1010RDB.h
index a373990..eed836b 100644
--- a/include/configs/P1010RDB.h
+++ b/include/configs/P1010RDB.h
@@ -661,7 +661,6 @@ extern unsigned long get_sdram_size(void);
 #endif
 /* enable read and write access to EEPROM */
 #define CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 5
diff --git a/include/configs/PMC440.h b/include/configs/PMC440.h
index c5e2f16..eb23839 100644
--- a/include/configs/PMC440.h
+++ b/include/configs/PMC440.h
@@ -156,7 +156,6 @@
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_1		400000
 #define CONFIG_SYS_I2C_PPC4XX_SLAVE_1		0x7F
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 
 #define CONFIG_SYS_I2C_EEPROM_ADDR		0x54
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		2
diff --git a/include/configs/TQM834x.h b/include/configs/TQM834x.h
index 6762e3a..7792ccb 100644
--- a/include/configs/TQM834x.h
+++ b/include/configs/TQM834x.h
@@ -181,7 +181,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		2	/* 16 bit */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	5	/* 32 bytes/write */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	12	/* 10ms +/- 20% */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS		/* more than one eeprom */
 
 /* I2C RTC */
 #define CONFIG_RTC_DS1337			/* use ds1337 rtc via i2c */
diff --git a/include/configs/W7OLMC.h b/include/configs/W7OLMC.h
index 895ad46..de4585d 100644
--- a/include/configs/W7OLMC.h
+++ b/include/configs/W7OLMC.h
@@ -273,7 +273,6 @@
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 4	/* The Catalyst CAT24WC08 has	*/
 					/* 16 byte page write mode using*/
 					/* last	4 bits of the address	*/
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 /*-----------------------------------------------------------------------
  * Definitions for Serial Presence Detect EEPROM address
  * (to get SDRAM settings)
diff --git a/include/configs/W7OLMG.h b/include/configs/W7OLMG.h
index 2a38116..bac5ba9 100644
--- a/include/configs/W7OLMG.h
+++ b/include/configs/W7OLMG.h
@@ -276,7 +276,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50		/* EEPROM ATMEL 24C04N		*/
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	1		/* Bytes of address		*/
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 /*-----------------------------------------------------------------------
  * Definitions for Serial Presence Detect EEPROM address
  * (to get SDRAM settings)
diff --git a/include/configs/acadia.h b/include/configs/acadia.h
index 4dd5720..2f53d73 100644
--- a/include/configs/acadia.h
+++ b/include/configs/acadia.h
@@ -120,7 +120,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
index 476430d..07cd2d8 100644
--- a/include/configs/am335x_evm.h
+++ b/include/configs/am335x_evm.h
@@ -209,7 +209,6 @@
 #define CONFIG_ENV_EEPROM_IS_ON_I2C
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50	/* Main EEPROM */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 
 /* PMIC support */
 #define CONFIG_POWER_TPS65217
diff --git a/include/configs/am43xx_evm.h b/include/configs/am43xx_evm.h
index 0707827..3f92dd2 100644
--- a/include/configs/am43xx_evm.h
+++ b/include/configs/am43xx_evm.h
@@ -30,7 +30,6 @@
 #define CONFIG_ENV_EEPROM_IS_ON_I2C
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50	/* Main EEPROM */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 
 /* Power */
 #define CONFIG_POWER
diff --git a/include/configs/axs101.h b/include/configs/axs101.h
index 1bf8390..008d394 100644
--- a/include/configs/axs101.h
+++ b/include/configs/axs101.h
@@ -98,7 +98,6 @@
 /*
  * EEPROM configuration
  */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR		(0xA8 >> 1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		1
 #define CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW	1
diff --git a/include/configs/bamboo.h b/include/configs/bamboo.h
index 6ba4aaf..5b8b22f 100644
--- a/include/configs/bamboo.h
+++ b/include/configs/bamboo.h
@@ -139,7 +139,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/canyonlands.h b/include/configs/canyonlands.h
index 8eeb15c..5349511 100644
--- a/include/configs/canyonlands.h
+++ b/include/configs/canyonlands.h
@@ -246,7 +246,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR		(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	3
diff --git a/include/configs/cpci5200.h b/include/configs/cpci5200.h
index ec926fd..92c1900 100644
--- a/include/configs/cpci5200.h
+++ b/include/configs/cpci5200.h
@@ -173,7 +173,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		2
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	5
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	20
-#define CONFIG_SYS_I2C_MULTI_EEPROMS		1
 /*
  * Flash configuration
  */
diff --git a/include/configs/ebony.h b/include/configs/ebony.h
index 3f0ad69..18012bb 100644
--- a/include/configs/ebony.h
+++ b/include/configs/ebony.h
@@ -123,7 +123,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/icon.h b/include/configs/icon.h
index bbe9b59..d9a3671 100644
--- a/include/configs/icon.h
+++ b/include/configs/icon.h
@@ -107,7 +107,6 @@
 
 #define CONFIG_SYS_SPD_BUS_NUM	0	/* The I2C bus for SPD		*/
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/intip.h b/include/configs/intip.h
index 928eb5b..1accb64 100644
--- a/include/configs/intip.h
+++ b/include/configs/intip.h
@@ -217,7 +217,6 @@
  */
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR		(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	3
diff --git a/include/configs/katmai.h b/include/configs/katmai.h
index fa72eb0..664896b 100644
--- a/include/configs/katmai.h
+++ b/include/configs/katmai.h
@@ -109,7 +109,6 @@
 #define IIC0_BOOTPROM_ADDR	0x50
 #define IIC0_ALT_BOOTPROM_ADDR	0x54
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0x50)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/km/km-powerpc.h b/include/configs/km/km-powerpc.h
index eb85a74..2b0b9dc 100644
--- a/include/configs/km/km-powerpc.h
+++ b/include/configs/km/km-powerpc.h
@@ -21,7 +21,6 @@
 #define CONFIG_KM_COMMON_ETH_INIT
 
 /* EEprom support 24C08, 24C16, 24C64 */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_ENABLE
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	3  /* 8 Byte write page */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	10
diff --git a/include/configs/km/km_arm.h b/include/configs/km/km_arm.h
index d31e674..1061d1d 100644
--- a/include/configs/km/km_arm.h
+++ b/include/configs/km/km_arm.h
@@ -218,7 +218,6 @@ int get_scl(void);
 #define	CONFIG_SYS_I2C_SOFT_SPEED	100000
 
 /* EEprom support 24C128, 24C256 valid for environment eeprom */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_ENABLE
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	6 /* 64 Byte write page */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	10
diff --git a/include/configs/korat.h b/include/configs/korat.h
index 5494a60..1085237 100644
--- a/include/configs/korat.h
+++ b/include/configs/korat.h
@@ -147,7 +147,6 @@
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 #define CONFIG_SYS_I2C_PPC4XX_SLAVE_0		0x7F
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/ks2_evm.h b/include/configs/ks2_evm.h
index 51926f7..c6cee42 100644
--- a/include/configs/ks2_evm.h
+++ b/include/configs/ks2_evm.h
@@ -120,7 +120,6 @@
 #define I2C_BUS_MAX			3
 
 /* EEPROM definitions */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		2
 #define CONFIG_SYS_I2C_EEPROM_ADDR		0x50
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	6
diff --git a/include/configs/luan.h b/include/configs/luan.h
index 15e4a7e..e22d0e8 100644
--- a/include/configs/luan.h
+++ b/include/configs/luan.h
@@ -119,7 +119,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/m28evk.h b/include/configs/m28evk.h
index efe770b..b566e54 100644
--- a/include/configs/m28evk.h
+++ b/include/configs/m28evk.h
@@ -97,7 +97,6 @@
 
 /* EEPROM */
 #ifdef CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
 #endif
 
diff --git a/include/configs/mecp5200.h b/include/configs/mecp5200.h
index b270429..aab787d 100644
--- a/include/configs/mecp5200.h
+++ b/include/configs/mecp5200.h
@@ -148,7 +148,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		2
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	5
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	20
-#define CONFIG_SYS_I2C_MULTI_EEPROMS		1
 /*
  * Flash configuration
  */
diff --git a/include/configs/motionpro.h b/include/configs/motionpro.h
index e8b0593..2d2fcd8 100644
--- a/include/configs/motionpro.h
+++ b/include/configs/motionpro.h
@@ -296,7 +296,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	1	/* 2 bytes per write cycle */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	5	/* 2ms/cycle + 3ms extra */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS		1	/* 2 EEPROMs (addr:50,52) */
 
 /*
  * RTC configuration
diff --git a/include/configs/ocotea.h b/include/configs/ocotea.h
index 4ff2f05..cd9e5ea 100644
--- a/include/configs/ocotea.h
+++ b/include/configs/ocotea.h
@@ -136,7 +136,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/p1_p2_rdb_pc.h b/include/configs/p1_p2_rdb_pc.h
index 9b58950..95250f3 100644
--- a/include/configs/p1_p2_rdb_pc.h
+++ b/include/configs/p1_p2_rdb_pc.h
@@ -665,7 +665,6 @@
 
 /* enable read and write access to EEPROM */
 #define CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 5
diff --git a/include/configs/p1_twr.h b/include/configs/p1_twr.h
index 911203d..203d041 100644
--- a/include/configs/p1_twr.h
+++ b/include/configs/p1_twr.h
@@ -261,7 +261,6 @@ extern unsigned long get_board_sys_clk(unsigned long dummy);
 
 /* enable read and write access to EEPROM */
 #define CONFIG_CMD_EEPROM
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 5
diff --git a/include/configs/pcm051.h b/include/configs/pcm051.h
index 7d102a4..e99a5c6 100644
--- a/include/configs/pcm051.h
+++ b/include/configs/pcm051.h
@@ -109,7 +109,6 @@
 #define CONFIG_ENV_EEPROM_IS_ON_I2C
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50	/* Main EEPROM */
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 
 #define CONFIG_SYS_BAUDRATE_TABLE	{ 110, 300, 600, 1200, 2400, \
 4800, 9600, 14400, 19200, 28800, 38400, 56000, 57600, 115200 }
diff --git a/include/configs/pengwyn.h b/include/configs/pengwyn.h
index 4684ad6..fdb103f 100644
--- a/include/configs/pengwyn.h
+++ b/include/configs/pengwyn.h
@@ -112,7 +112,6 @@
 #define CONFIG_ENV_EEPROM_IS_ON_I2C
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 
 /* SPL */
 #define CONFIG_SPL_POWER_SUPPORT
diff --git a/include/configs/pf5200.h b/include/configs/pf5200.h
index be76478..af334f7 100644
--- a/include/configs/pf5200.h
+++ b/include/configs/pf5200.h
@@ -165,7 +165,6 @@
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		2
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	5
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	20
-#define CONFIG_SYS_I2C_MULTI_EEPROMS		1
 /*
  * Flash configuration
  */
diff --git a/include/configs/sequoia.h b/include/configs/sequoia.h
index b6a5e6a..5af751b 100644
--- a/include/configs/sequoia.h
+++ b/include/configs/sequoia.h
@@ -160,7 +160,6 @@
  */
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/t3corp.h b/include/configs/t3corp.h
index 502e795..7942865 100644
--- a/include/configs/t3corp.h
+++ b/include/configs/t3corp.h
@@ -307,7 +307,6 @@
  */
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0			400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR		(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS	3
diff --git a/include/configs/taishan.h b/include/configs/taishan.h
index 3d5c351..64568fe 100644
--- a/include/configs/taishan.h
+++ b/include/configs/taishan.h
@@ -121,7 +121,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#undef CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	0x50
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/tricorder.h b/include/configs/tricorder.h
index 6ddf3d5..7a46e60 100644
--- a/include/configs/tricorder.h
+++ b/include/configs/tricorder.h
@@ -109,7 +109,6 @@
  
 
 /* EEPROM */
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_CMD_EEPROM
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN	2
 #define CONFIG_SYS_EEPROM_BUS_NUM	1
diff --git a/include/configs/walnut.h b/include/configs/walnut.h
index 8b803a2..dd6b519 100644
--- a/include/configs/walnut.h
+++ b/include/configs/walnut.h
@@ -80,7 +80,6 @@
  */
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
diff --git a/include/configs/yosemite.h b/include/configs/yosemite.h
index 8508a80..0cffab8 100644
--- a/include/configs/yosemite.h
+++ b/include/configs/yosemite.h
@@ -122,7 +122,6 @@
  *----------------------------------------------------------------------*/
 #define CONFIG_SYS_I2C_PPC4XX_SPEED_0		400000
 
-#define CONFIG_SYS_I2C_MULTI_EEPROMS
 #define CONFIG_SYS_I2C_EEPROM_ADDR	(0xa8>>1)
 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3
-- 
2.1.1



More information about the U-Boot mailing list