summaryrefslogtreecommitdiff
path: root/src/soc/intel/elkhartlake/include
diff options
context:
space:
mode:
authorMario Scheithauer <mario.scheithauer@siemens.com>2022-04-26 14:16:59 +0200
committerFelix Held <felix-coreboot@felixheld.de>2022-05-16 13:24:32 +0000
commitd691c216c2d0c8df4edabb62f966172880bfd02d (patch)
tree7e332f3baa226ec7729fd9263e48ba5194178ebf /src/soc/intel/elkhartlake/include
parentcf0236972d06ff02880619beb7a891a0d3011184 (diff)
soc/intel/elkhartlake: Provide ability to update TSN GbE MAC addresses
This patch provides the functionality to change the TSN GbE MAC addresses. Prerequisite for this is a mainboard specific function that returns a matching MAC address. A test was performed with the next patch in the series, which enables the TSN GbE driver for mc_ehl2 mainboard. Change-Id: I2303a64cfd09fa02734ca9452d26591af2a76221 Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/63863 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
Diffstat (limited to 'src/soc/intel/elkhartlake/include')
-rw-r--r--src/soc/intel/elkhartlake/include/soc/tsn_gbe.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/soc/intel/elkhartlake/include/soc/tsn_gbe.h b/src/soc/intel/elkhartlake/include/soc/tsn_gbe.h
index d006ef252b..e9f6c8d1fe 100644
--- a/src/soc/intel/elkhartlake/include/soc/tsn_gbe.h
+++ b/src/soc/intel/elkhartlake/include/soc/tsn_gbe.h
@@ -3,4 +3,13 @@
#ifndef _SOC_ELKHARTLAKE_TSN_GBE_H_
#define _SOC_ELKHARTLAKE_TSN_GBE_H_
+#define MAC_ADDR_LEN 6
+
+#define TSN_MAC_ADD0_HIGH 0x300 /* MAC Address0 High register */
+#define TSN_MAC_ADD0_LOW 0x304 /* MAC Address0 Low register */
+
+/* We need one function we can call to get a MAC address to use. */
+/* This function can be coded somewhere else but must exist. */
+enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_LEN]);
+
#endif /* _SOC_ELKHARTLAKE_TSN_GBE_H_ */