summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSean Rhodes <sean@starlabs.systems>2023-01-14 21:09:46 +0000
committerFelix Held <felix-coreboot@felixheld.de>2023-01-27 17:51:16 +0000
commit6e8c509d7d37d1115fbacccffa3ee7fe2b26e1b6 (patch)
tree1f13c67366197250db1c35a6995a9757b6ab1314 /src
parentb45502cd64ee0829ed6062711737ed72df1a9bd7 (diff)
mb/starlabs/starbook/adl: Fix the disable wireless CMOS option
The current CMOS option causes Linux to not boot, as the GRUB EFI loader will report an incorrect parameter. Update the CMOS option so that the corresponding UPD is changed when the wireless is set to disable, so that the root port for the wireless is also disabled. Signed-off-by: Sean Rhodes <sean@starlabs.systems> Change-Id: I607d700319d6a58618ec95b3440e695c82dff196 Reviewed-on: https://review.coreboot.org/c/coreboot/+/71896 Reviewed-by: Matt DeVillier <matt.devillier@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src')
-rw-r--r--src/mainboard/starlabs/starbook/variants/adl/devtree.c6
-rw-r--r--src/mainboard/starlabs/starbook/variants/adl/romstage.c4
2 files changed, 6 insertions, 4 deletions
diff --git a/src/mainboard/starlabs/starbook/variants/adl/devtree.c b/src/mainboard/starlabs/starbook/variants/adl/devtree.c
index 773c9036d0..0b764fdda8 100644
--- a/src/mainboard/starlabs/starbook/variants/adl/devtree.c
+++ b/src/mainboard/starlabs/starbook/variants/adl/devtree.c
@@ -21,8 +21,6 @@ void devtree_update(void)
struct soc_power_limits_config *soc_conf_12core =
&cfg->power_limits_config[ADL_P_682_28W_CORE];
- struct device *nic_dev = pcidev_on_root(0x1c, 4);
-
/* Update PL1 & PL2 based on CMOS settings */
switch (get_power_profile(PP_POWER_SAVER)) {
case PP_POWER_SAVER:
@@ -49,9 +47,9 @@ void devtree_update(void)
break;
}
- /* Enable/Disable Wireless based on CMOS settings */
+ /* Enable/Disable Bluetooth based on CMOS settings */
if (get_uint_option("wireless", 1) == 0)
- nic_dev->enabled = 0;
+ cfg->usb2_ports[9].enable = 0;
/* Enable/Disable Webcam based on CMOS settings */
if (get_uint_option("webcam", 1) == 0)
diff --git a/src/mainboard/starlabs/starbook/variants/adl/romstage.c b/src/mainboard/starlabs/starbook/variants/adl/romstage.c
index b9820035b8..29beea39d1 100644
--- a/src/mainboard/starlabs/starbook/variants/adl/romstage.c
+++ b/src/mainboard/starlabs/starbook/variants/adl/romstage.c
@@ -29,4 +29,8 @@ void mainboard_memory_init_params(FSPM_UPD *mupd)
const uint8_t vtd = get_uint_option("vtd", 1);
mupd->FspmConfig.VtdDisable = !vtd;
+
+ /* Enable/Disable Wireless (RP05) based on CMOS settings */
+ if (get_uint_option("wireless", 1) == 0)
+ mupd->FspmConfig.PcieRpEnableMask &= ~(1 << 4);
};