projects
/
platform
/
kernel
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
spi: Remove unused mpc8xx code
[platform/kernel/u-boot.git]
/
cmd
/
eeprom.c
diff --git
a/cmd/eeprom.c
b/cmd/eeprom.c
index
e43566b
..
9136630
100644
(file)
--- a/
cmd/eeprom.c
+++ b/
cmd/eeprom.c
@@
-1,8
+1,7
@@
+// SPDX-License-Identifier: GPL-2.0+
/*
* (C) Copyright 2000, 2001
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
/*
* (C) Copyright 2000, 2001
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
/*
*/
/*
@@
-67,11
+66,6
@@
__weak int eeprom_write_enable(unsigned dev_addr, int state)
void eeprom_init(int bus)
{
void eeprom_init(int bus)
{
- /* SPI EEPROM */
-#if defined(CONFIG_SPI) && !defined(CONFIG_ENV_EEPROM_IS_ON_I2C)
- spi_init_f();
-#endif
-
/* I2C EEPROM */
#if defined(CONFIG_SYS_I2C)
if (bus >= 0)
/* I2C EEPROM */
#if defined(CONFIG_SYS_I2C)
if (bus >= 0)
@@
-130,14
+124,6
@@
static int eeprom_rw_block(unsigned offset, uchar *addr, unsigned alen,
{
int ret = 0;
{
int ret = 0;
- /* SPI */
-#if defined(CONFIG_SPI) && !defined(CONFIG_ENV_EEPROM_IS_ON_I2C)
- if (read)
- spi_read(addr, alen, buffer, len);
- else
- spi_write(addr, alen, buffer, len);
-#else /* I2C */
-
#if defined(CONFIG_SYS_I2C_EEPROM_BUS)
i2c_set_bus_num(CONFIG_SYS_I2C_EEPROM_BUS);
#endif
#if defined(CONFIG_SYS_I2C_EEPROM_BUS)
i2c_set_bus_num(CONFIG_SYS_I2C_EEPROM_BUS);
#endif
@@
-149,7
+135,7
@@
static int eeprom_rw_block(unsigned offset, uchar *addr, unsigned alen,
if (ret)
ret = 1;
if (ret)
ret = 1;
-#endif
+
return ret;
}
return ret;
}
@@
-265,10
+251,6
@@
__weak int eeprom_parse_layout_version(char *str)
static unsigned char eeprom_buf[CONFIG_SYS_EEPROM_SIZE];
static unsigned char eeprom_buf[CONFIG_SYS_EEPROM_SIZE];
-#ifndef CONFIG_EEPROM_LAYOUT_HELP_STRING
-#define CONFIG_EEPROM_LAYOUT_HELP_STRING "<not defined>"
-#endif
-
#endif
enum eeprom_action {
#endif
enum eeprom_action {