veyron: fievel/tiger: retrieve MAC address from VPD

Reads the MAC address from the VPD ethernet_mac0 if it exists,
stores it the coreboot table for depthcharge consumption.

Signed-off-by: Vincent Palatin <vpalatin@chromium.org>

BRANCH=veyron
BUG=chrome-os-partner:53191 chrome-os-partner:53964
TEST=along with the matching depthcharge change, provision a MAC address
on a Tiger device by doing 'vpd -s ethernet_mac0=0a1f9c9bfada' and
ensure that it is properly set in the MAC hardware after reboot by
running 'ifconfig' and checking
'/proc/device-tree/ethernet\@ff290000/mac-address'.

Change-Id: I0a7bb25cd6b094261dda2be25aa89b38b4707868
Reviewed-on: https://chromium-review.googlesource.com/348831
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
This commit is contained in:
Vincent Palatin 2016-06-01 15:13:12 -07:00 committed by ChromeOS Commit Bot
commit 4b19bfbb64
2 changed files with 6 additions and 0 deletions

View file

@ -141,6 +141,9 @@ void lb_board(struct lb_header *header)
dma->size = sizeof(*dma);
dma->range_start = (uintptr_t)_dma_coherent;
dma->range_size = _dma_coherent_size;
/* Retrieve the on-board Ethernet MAC address. */
lb_table_add_macs_from_vpd(header);
}
void mainboard_power_on_backlight(void)

View file

@ -141,6 +141,9 @@ void lb_board(struct lb_header *header)
dma->size = sizeof(*dma);
dma->range_start = (uintptr_t)_dma_coherent;
dma->range_size = _dma_coherent_size;
/* Retrieve the on-board Ethernet MAC address. */
lb_table_add_macs_from_vpd(header);
}
void mainboard_power_on_backlight(void)