[coreboot-gerrit] Patch set updated for coreboot: 7088afd google/urara: retrieve network device information from VPD

Patrick Georgi (pgeorgi@google.com) gerrit at coreboot.org
Wed Apr 22 08:53:54 CEST 2015


Patrick Georgi (pgeorgi at google.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/9897

-gerrit

commit 7088afd2ef9e7f47915f366f8109d6f401c7b3f9
Author: Vadim Bendebury <vbendeb at chromium.org>
Date:   Sat Mar 28 22:14:53 2015 -0700

    google/urara: retrieve network device information from VPD
    
    Invoke the function which copies MAC addresses from VPD into the
    coreboot table and calibration data into CBMEM.
    
    BRANCH=none
    BUG=chrome-os-partner:36584
    TEST=with the rest of the patches applied observed that the MAC
         addresses from VPD get copied into the appropriate kernel device
         tree nodes.
    
    Change-Id: I68e2b73520853ef2d3249ca12ee87669fd01f442
    Signed-off-by: Patrick Georgi <pgeorgi at chromium.org>
    Original-Commit-Id: 12f935098c50e2df345748d3b71cee2152acd422
    Original-Change-Id: I6e1483d33480d13380ade2dddae6c92fd3f1f881
    Original-Signed-off-by: Vadim Bendebury <vbendeb at chromium.org>
    Original-Reviewed-on: https://chromium-review.googlesource.com/262844
    Original-Reviewed-by: Aaron Durbin <adurbin at chromium.org>
---
 src/mainboard/google/urara/mainboard.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/src/mainboard/google/urara/mainboard.c b/src/mainboard/google/urara/mainboard.c
index 0a0cb02..0409dab 100644
--- a/src/mainboard/google/urara/mainboard.c
+++ b/src/mainboard/google/urara/mainboard.c
@@ -24,9 +24,20 @@
 #include <device/device.h>
 #include <boot/coreboot_tables.h>
 
+#include <vendorcode/google/chromeos/chromeos.h>
+
+static void mainboard_init(device_t dev)
+{
+#if IS_ENABLED(CONFIG_CHROMEOS)
+	/* Copy WIFI calibration data into CBMEM. */
+	cbmem_add_vpd_calibration_data();
+#endif
+}
+
 static void mainboard_enable(device_t dev)
 {
 	printk(BIOS_INFO, "Enable Pistachio device...\n");
+	dev->ops->init = &mainboard_init;
 }
 
 struct chip_operations mainboard_ops = {
@@ -42,4 +53,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;
+
+#if IS_ENABLED(CONFIG_CHROMEOS)
+	/* Retrieve the switch interface MAC addressses. */
+	lb_table_add_macs_from_vpd(header);
+#endif
 }



More information about the coreboot-gerrit mailing list