Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/73092 )
Change subject: mb/starlabs/starbook/adl: Add an option to enable Hot Plug ......................................................................
mb/starlabs/starbook/adl: Add an option to enable Hot Plug
Some third-party SSDs, from Samsung and WD, such as the 990 Pro and WD Black 850X aren't initialised by coreboot, seemingly as coreboot is too quick; debug builds work, and enabling hotplug does.
Add a cmos option `pci_hot_plug`, defaulting to enabled to allow these SSDs to work.
Signed-off-by: Sean Rhodes sean@starlabs.systems Change-Id: I680211bc87153a5e6005d58040a94725c0973451 Reviewed-on: https://review.coreboot.org/c/coreboot/+/73092 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Angel Pons th3fanbus@gmail.com --- M src/mainboard/starlabs/starbook/cmos.default M src/mainboard/starlabs/starbook/cmos.layout M src/mainboard/starlabs/starbook/variants/adl/Makefile.inc A src/mainboard/starlabs/starbook/variants/adl/ramstage.c 4 files changed, 38 insertions(+), 0 deletions(-)
Approvals: build bot (Jenkins): Verified Angel Pons: Looks good to me, approved
diff --git a/src/mainboard/starlabs/starbook/cmos.default b/src/mainboard/starlabs/starbook/cmos.default index f1276cc..151686c 100644 --- a/src/mainboard/starlabs/starbook/cmos.default +++ b/src/mainboard/starlabs/starbook/cmos.default @@ -12,6 +12,7 @@ webcam=Enable microphone=Enable legacy_8254_timer=Disable +pci_hot_plug=Disable # EC kbl_timeout=30 seconds fn_ctrl_swap=Disable diff --git a/src/mainboard/starlabs/starbook/cmos.layout b/src/mainboard/starlabs/starbook/cmos.layout index 887c0b2..9fc0b7d 100644 --- a/src/mainboard/starlabs/starbook/cmos.layout +++ b/src/mainboard/starlabs/starbook/cmos.layout @@ -28,6 +28,7 @@ 512 1 e 1 webcam 520 1 e 1 microphone 528 1 e 1 legacy_8254_timer +536 1 e 1 pci_hot_plug
# coreboot config options: EC 600 3 e 4 kbl_timeout diff --git a/src/mainboard/starlabs/starbook/variants/adl/Makefile.inc b/src/mainboard/starlabs/starbook/variants/adl/Makefile.inc index 2a505c3..9abc069 100644 --- a/src/mainboard/starlabs/starbook/variants/adl/Makefile.inc +++ b/src/mainboard/starlabs/starbook/variants/adl/Makefile.inc @@ -7,3 +7,4 @@ ramstage-y += devtree.c ramstage-y += gpio.c ramstage-y += hda_verb.c +ramstage-y += ramstage.c diff --git a/src/mainboard/starlabs/starbook/variants/adl/ramstage.c b/src/mainboard/starlabs/starbook/variants/adl/ramstage.c new file mode 100644 index 0000000..7accb1d --- /dev/null +++ b/src/mainboard/starlabs/starbook/variants/adl/ramstage.c @@ -0,0 +1,15 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ + +#include <option.h> +#include <soc/ramstage.h> + + +void mainboard_silicon_init_params(FSP_S_CONFIG *supd) +{ + /* + * Enable Hot Plug on RP5 to slow down coreboot so that + * third-party drives are detected. + */ + if (get_uint_option("pci_hot_plug", 0) == 1) + supd->PcieRpHotPlug[4] = 1; +}