Lines Matching full:eeprom
7 * eeprom. It has been adapted from an earlier version of the
18 #include "eeprom.h"
28 * static eeprom: EEPROM layout for NXID formats
32 static struct __attribute__ ((__packed__)) eeprom { struct
33 u8 id[4]; /* 0x00 - 0x03 EEPROM Tag 'NXID' */
49 /* Set to 1 if we've read EEPROM into memory */
52 /* Is this a valid NXID EEPROM? */
56 /** Fixed ID field in EEPROM */
64 * This must be called before any eeprom access. argument
74 * show_eeprom - display the contents of the EEPROM
81 /* EEPROM tag ID, either CCID or NXID */ in show_eeprom()
119 printf("EEPROM dump: (0x%x bytes)\n", sizeof(e)); in show_eeprom()
131 * read_eeprom - read the EEPROM into memory
139 printf("EEPROM not configured\n"); in read_eeprom()
170 * This function should be called after each update to the EEPROM structure,
175 u32 crc, crc_offset = offsetof(struct eeprom, crc); in update_crc()
182 * prog_eeprom - write the EEPROM from memory
192 printf("EEPROM not configured\n"); in prog_eeprom()
218 /* Verify the write by reading back the EEPROM and comparing */ in prog_eeprom()
219 struct eeprom e2; in prog_eeprom()
260 * set_date - stores the build date into the EEPROM
264 * and stores it in the build date field of the EEPROM local copy.
282 * set_mac_address - stores a MAC address into the EEPROM
286 * stores it in one of the MAC address fields of the EEPROM local copy.
331 printf("Please read the EEPROM ('r') and/or set the ID ('i') first.\n"); in do_mac()
422 * mac_read_from_eeprom - read the MAC addresses from EEPROM
424 * This function reads the MAC addresses from EEPROM and sets the
433 * format. In a v0 EEPROM, there are only eight MAC addresses and the CRC is
439 u32 crc, crc_offset = offsetof(struct eeprom, crc); in mac_read_from_eeprom_common()
440 u32 *crcp; /* Pointer to the CRC in the data read from the EEPROM */ in mac_read_from_eeprom_common()
442 puts("EEPROM: "); in mac_read_from_eeprom_common()