soc/intel/elkhartlake: Implement TSN GbE driver

To be able to make EHL Ethernet GbE-TSN Controller configurable, a
driver is required. Functionality comes in following patches.

Change-Id: I7522914c56b74486bb088280d2686acf7027d1d3
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/63861
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
This commit is contained in:
Mario Scheithauer 2022-04-26 13:50:52 +02:00 committed by Felix Held
parent bd192821bb
commit eda66c313b
4 changed files with 34 additions and 0 deletions

View File

@ -236,6 +236,13 @@ config PSE_CONFIG_BUFFER_SIZE_KIB
data (FSP will append PSE config data to memory region right data (FSP will append PSE config data to memory region right
after PSE FW memory region). after PSE FW memory region).
config EHL_TSN_DRIVER
bool
default n
help
Enable TSN GbE driver to provide board specific settings in the GBE MAC.
As an example of a possible change, the MAC address could be adjusted.
config SOC_INTEL_ELKHARTLAKE_DEBUG_CONSENT config SOC_INTEL_ELKHARTLAKE_DEBUG_CONSENT
int "Debug Consent for EHL" int "Debug Consent for EHL"
# USB DBC is more common for developers so make this default to 3 if # USB DBC is more common for developers so make this default to 3 if

View File

@ -36,6 +36,7 @@ ramstage-y += pmc.c
ramstage-y += reset.c ramstage-y += reset.c
ramstage-y += systemagent.c ramstage-y += systemagent.c
ramstage-y += sd.c ramstage-y += sd.c
ramstage-$(CONFIG_EHL_TSN_DRIVER) += tsn_gbe.c
ramstage-y += me.c ramstage-y += me.c
smm-y += gpio.c smm-y += gpio.c

View File

@ -0,0 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0-only */
#ifndef _SOC_ELKHARTLAKE_TSN_GBE_H_
#define _SOC_ELKHARTLAKE_TSN_GBE_H_
#endif /* _SOC_ELKHARTLAKE_TSN_GBE_H_ */

View File

@ -0,0 +1,20 @@
/* SPDX-License-Identifier: GPL-2.0-only */
#include <console/console.h>
#include <device/pci.h>
#include <device/pci_ids.h>
#include <soc/tsn_gbe.h>
static struct device_operations gbe_tsn_ops = {
.read_resources = pci_dev_read_resources,
.set_resources = pci_dev_set_resources,
.enable_resources = pci_dev_enable_resources,
};
static const unsigned short gbe_tsn_device_ids[] = { 0x4b32, 0x4ba0, 0x4bb0, 0 };
static const struct pci_driver gbe_tsn_driver __pci_driver = {
.ops = &gbe_tsn_ops,
.vendor = PCI_VID_INTEL,
.devices = gbe_tsn_device_ids,
};