mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-08-19 00:18:51 +09:00
![Ian Ray](/assets/img/avatar_default.png)
Define i2c mux configuration. Add new vpd_reader which is used to read vital product data. Read VPD from EEPROM and set eth0 MAC address. Signed-off-by: Ian Ray <ian.ray@ge.com> Signed-off-by: Jose Alarcon <jose.alarcon@ge.com>
26 lines
489 B
C
26 lines
489 B
C
/*
|
|
* Copyright 2016 General Electric Company
|
|
*
|
|
* SPDX-License-Identifier: GPL-2.0+
|
|
*/
|
|
|
|
#include "common.h"
|
|
|
|
/*
|
|
* Read VPD from given data, verify content, and call callback
|
|
* for each vital product data block.
|
|
*
|
|
* Returns Non-zero on error. Negative numbers encode errno.
|
|
*/
|
|
int vpd_reader(
|
|
size_t size,
|
|
uint8_t * data,
|
|
void * userdata,
|
|
int (*fn)(
|
|
void * userdata,
|
|
uint8_t id,
|
|
uint8_t version,
|
|
uint8_t type,
|
|
size_t size,
|
|
uint8_t const * data));
|