Convert CONFIG_SYS_MAXARGS to Kconfig
[platform/kernel/u-boot.git] / cmd / tlv_eeprom.c
index eab0531..bf8d453 100644 (file)
@@ -17,6 +17,7 @@
 #include <env.h>
 #include <init.h>
 #include <net.h>
+#include <asm/global_data.h>
 #include <linux/ctype.h>
 #include <u-boot/crc.h>
 
@@ -168,6 +169,9 @@ static void show_eeprom(u8 *eeprom)
 {
        int tlv_end;
        int curr_tlv;
+#ifdef DEBUG
+       int i;
+#endif
        struct tlvinfo_header *eeprom_hdr = to_header(eeprom);
        struct tlvinfo_tlv    *eeprom_tlv;
 
@@ -750,7 +754,7 @@ static int set_mac(char *buf, const char *string)
 
        /* Convert string to binary */
        for (i = 0, p = (char *)string; i < 6; i++) {
-               buf[i] = p ? simple_strtoul(p, &end, 16) : 0;
+               buf[i] = p ? hextoul(p, &end) : 0;
                if (p)
                        p = (*end) ? end + 1 : end;
        }