diff options
author | Tom Rini <trini@konsulko.com> | 2020-05-19 10:51:43 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-05-19 10:51:43 -0400 |
commit | c2279d784e35fa25ee3a9fa28a74a1ba545f8c1e (patch) | |
tree | 158fd30f3d06142f6a99cbae6ed8ccb0f3be567b /examples/standalone/smc91111_eeprom.c | |
parent | ed9a3aa6452f57af65eb74f73bd2a54c3a2f4b03 (diff) | |
parent | cd93d625fd751d55c729c78b10f82109d56a5f1d (diff) |
Merge branch '2020-05-18-reduce-size-of-common.h'
Bring in the latest round of Simon's changes to reduce what's in
<common.h> overall.
Diffstat (limited to 'examples/standalone/smc91111_eeprom.c')
-rw-r--r-- | examples/standalone/smc91111_eeprom.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/examples/standalone/smc91111_eeprom.c b/examples/standalone/smc91111_eeprom.c index 5ffefc8f36b..bf7e9306430 100644 --- a/examples/standalone/smc91111_eeprom.c +++ b/examples/standalone/smc91111_eeprom.c @@ -12,6 +12,7 @@ #include <common.h> #include <exports.h> +#include <linux/delay.h> #include "../drivers/net/smc91111.h" #ifndef SMC91111_EEPROM_INIT @@ -31,7 +32,7 @@ void print_MAC (struct eth_device *dev); int read_eeprom_reg (struct eth_device *dev, int reg); void print_macaddr (struct eth_device *dev); -int smc91111_eeprom (int argc, char * const argv[]) +int smc91111_eeprom(int argc, char *const argv[]) { int c, i, j, done, line, reg, value, start, what; char input[50]; @@ -237,7 +238,7 @@ void copy_from_eeprom (struct eth_device *dev) CTL_RELOAD, CTL_REG); i = 100; while ((SMC_inw (dev, CTL_REG) & CTL_RELOAD) && --i) - udelay (100); + udelay(100); if (i == 0) { printf ("Timeout Refreshing EEPROM registers\n"); } else { @@ -318,7 +319,7 @@ int read_eeprom_reg (struct eth_device *dev, int reg) CTL_RELOAD, CTL_REG); timeout = 100; while ((SMC_inw (dev, CTL_REG) & CTL_RELOAD) && --timeout) - udelay (100); + udelay(100); if (timeout == 0) { printf ("Timeout Reading EEPROM register %02x\n", reg); return 0; @@ -341,7 +342,7 @@ int write_eeprom_reg (struct eth_device *dev, int value, int reg) CTL_STORE, CTL_REG); timeout = 100; while ((SMC_inw (dev, CTL_REG) & CTL_STORE) && --timeout) - udelay (100); + udelay(100); if (timeout == 0) { printf ("Timeout Writing EEPROM register %02x\n", reg); return 0; |