Sean Rhodes has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/59705 )
Change subject: mainboard/starlabs/labtop: Enable/disable Thunderbolt based on CMOS ......................................................................
mainboard/starlabs/labtop: Enable/disable Thunderbolt based on CMOS
Enable or disable Thunderbolt and related settings based on CMOS value of `thunderbolt`. Changes TcssD3ColdDisable, TcssXhciEn, and UsbTcPortEn.
Signed-off-by: Sean Rhodes sean@starlabs.systems Change-Id: Ibadc7464831242ae51982610b410ccf0a6811edd --- M src/mainboard/starlabs/labtop/cmos.default M src/mainboard/starlabs/labtop/cmos.layout M src/mainboard/starlabs/labtop/variants/tgl/devicetree.cb M src/mainboard/starlabs/labtop/variants/tgl/devtree.c 4 files changed, 7 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/05/59705/1
diff --git a/src/mainboard/starlabs/labtop/cmos.default b/src/mainboard/starlabs/labtop/cmos.default index b4b2d26..589189f 100644 --- a/src/mainboard/starlabs/labtop/cmos.default +++ b/src/mainboard/starlabs/labtop/cmos.default @@ -14,6 +14,7 @@ microphone=Enable legacy_8254_timer=Enable usb_always_on=Disable +thunderbolt=Disable # EC kbl_timeout=30 seconds fn_ctrl_swap=Disable diff --git a/src/mainboard/starlabs/labtop/cmos.layout b/src/mainboard/starlabs/labtop/cmos.layout index 2601e98..f9caa18 100644 --- a/src/mainboard/starlabs/labtop/cmos.layout +++ b/src/mainboard/starlabs/labtop/cmos.layout @@ -30,6 +30,7 @@ 520 1 e 1 microphone 528 1 e 1 legacy_8254_timer 536 1 e 1 usb_always_on +542 1 e 1 thunderbolt
# coreboot config options: EC 600 3 e 4 kbl_timeout diff --git a/src/mainboard/starlabs/labtop/variants/tgl/devicetree.cb b/src/mainboard/starlabs/labtop/variants/tgl/devicetree.cb index 5c55dce..40982a5 100644 --- a/src/mainboard/starlabs/labtop/variants/tgl/devicetree.cb +++ b/src/mainboard/starlabs/labtop/variants/tgl/devicetree.cb @@ -22,7 +22,6 @@ register "enable_c6dram" = "1" register "HeciEnabled" = "1" register "SaGv" = "SaGv_Enabled" - register "TcssD3ColdDisable" = "1"
# FSP Silicon # Serial I/O @@ -89,8 +88,6 @@ device pci 09.0 off end # NPK device pci 0a.0 off end # Crash-log SRAM device pci 0d.0 on # USB xHCI - register "UsbTcPortEn" = "1" - register "TcssXhciEn" = "1" register "TcssAuxOri" = "0" end device pci 0d.1 off end # USB xDCI (OTG) diff --git a/src/mainboard/starlabs/labtop/variants/tgl/devtree.c b/src/mainboard/starlabs/labtop/variants/tgl/devtree.c index 034877c..1d35189 100644 --- a/src/mainboard/starlabs/labtop/variants/tgl/devtree.c +++ b/src/mainboard/starlabs/labtop/variants/tgl/devtree.c @@ -50,4 +50,9 @@ /* Enable/Disable Webcam based on CMOS settings */ if (get_uint_option("webcam", 1) == 0) cfg->usb2_ports[3].enable = 0; + + /* Enable/Disable Thunderbolt based on CMOS settings */ + cfg->UsbTcPortEn = get_uint_option("thunderbolt", 1); + cfg->TcssXhciEn = get_uint_option("thunderbolt", 1); + cfg->TcssD3ColdDisable = get_uint_option("thunderbolt", 1); }