Skip to content

Commit c843a27

Browse files
configs/config.protectli_vp2430_no_emmc: create config variant with eMMC removed
Adds ENABLE_EMMC option (default y) to support VP2430e — a hardware variant without eMMC. SMBIOS product name gets an "e" suffix when the option is disabled. `ScsEmmcEnabled` is set by `soc_silicon_init_params()` via `is_devfn_enabled(PCH_DEVFN_EMMC)` before `mainboard_silicon_init_params()` is called, so overriding it directly in FSP UPD at the end of `mainboard_silicon_init_params()` is sufficient. `pcidev_path_on_root(PCH_DEVFN_EMMC)->enabled` is also cleared to prevent the device from appearing in ACPI tables. Upstream-Status: Inappropriate [Dasharo downstream] Signed-off-by: Wiktor Mowinski <wiktor.mowinski@3mdeb.com>
1 parent 5e4b1fc commit c843a27

4 files changed

Lines changed: 80 additions & 1 deletion

File tree

build.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ usage() {
1515
echo -e "\tvp32xx - build Dasharo for Protectli VP32xx"
1616
echo -e "\tvp2440 - build Dasharo for Protectli VP2440"
1717
echo -e "\tvp2430 - build Dasharo for Protectli VP2430"
18+
echo -e "\tvp2430_noemmc - build Dasharo for Protectli VP2430 without eMMC (VP2430e)"
1819
echo -e "\tvp2420 - build Dasharo for Protectli VP2420"
1920
echo -e "\tvp2410 - build Dasharo for Protectli VP2410"
2021
echo -e "\tV1210 - build Dasharo for Protectli V1210"
@@ -388,6 +389,10 @@ case "$CMD" in
388389
BOARD="vp2430"
389390
build_protectli_vault
390391
;;
392+
"vp2430_noemmc" | "VP2430_noemmc" | "vp2430e" | "VP2430e")
393+
BOARD="vp2430"
394+
build_protectli_vault _no_emmc
395+
;;
391396
"vp2440" | "VP2440")
392397
BOARD="vp2440"
393398
build_protectli_vault
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
CONFIG_LOCALVERSION="v0.9.0"
2+
CONFIG_OPTION_BACKEND_NONE=y
3+
CONFIG_VENDOR_PROTECTLI=y
4+
CONFIG_VBOOT=y
5+
CONFIG_IFD_BIN_PATH="3rdparty/dasharo-blobs/$(MAINBOARDDIR)/vp2430/descriptor.bin"
6+
CONFIG_ME_BIN_PATH="3rdparty/dasharo-blobs/$(MAINBOARDDIR)/vp2430/me.bin"
7+
CONFIG_CONSOLE_CBMEM_BUFFER_SIZE=0x100000
8+
CONFIG_EDK2_BOOT_TIMEOUT=6
9+
CONFIG_HAVE_IFD_BIN=y
10+
CONFIG_TPM_MEASURED_BOOT=y
11+
CONFIG_BOARD_PROTECTLI_VP2430=y
12+
# CONFIG_ENABLE_EMMC is not set
13+
CONFIG_EDK2_BOOTSPLASH_FILE="3rdparty/dasharo-blobs/protectli/black_background.bmp"
14+
CONFIG_POWER_STATE_OFF_AFTER_FAILURE=y
15+
CONFIG_HAVE_ME_BIN=y
16+
CONFIG_INTEL_ME_DISABLED_HECI=y
17+
# CONFIG_DASHARO_FIRMWARE_UPDATE_MODE is not set
18+
CONFIG_PCIEXP_LANE_ERR_STAT_CLEAR=y
19+
CONFIG_DRIVERS_EFI_VARIABLE_STORE=y
20+
CONFIG_DRIVERS_GENERIC_CBFS_SERIAL=y
21+
CONFIG_DRIVERS_GENERIC_CBFS_UUID=y
22+
CONFIG_TPM2=y
23+
CONFIG_BOOTMEDIA_LOCK_CONTROLLER=y
24+
CONFIG_BOOTMEDIA_LOCK_WPRO_VBOOT_RO=y
25+
CONFIG_BOOTMEDIA_LOCK_IN_VERSTAGE=y
26+
CONFIG_BOOTMEDIA_SMM_BWP=y
27+
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_0=y
28+
# CONFIG_CONSOLE_USE_LOGLEVEL_PREFIX is not set
29+
# CONFIG_CONSOLE_USE_ANSI_ESCAPES is not set
30+
CONFIG_PAYLOAD_EDK2=y
31+
CONFIG_EDK2_USE_EDK2_PLATFORMS=y
32+
CONFIG_EDK2_PLATFORMS_REPOSITORY="https://github.com/Dasharo/edk2-platforms"
33+
CONFIG_EDK2_PLATFORMS_TAG_OR_REV="1002a59639f111a2f8178b77d1f5fde0ea8d976f"
34+
CONFIG_EDK2_CBMEM_LOGGING=y
35+
CONFIG_EDK2_FOLLOW_BGRT_SPEC=y
36+
# CONFIG_EDK2_PRIORITIZE_INTERNAL is not set
37+
# CONFIG_EDK2_PS2_SUPPORT is not set
38+
CONFIG_EDK2_SERIAL_SUPPORT=y
39+
CONFIG_EDK2_CUSTOM_BUILD_PARAMS="-D VARIABLE_SUPPORT=SMMSTORE --pcd gEfiMdeModulePkgTokenSpaceGuid.PcdUse1GPageTable=FALSE"
40+
CONFIG_BUILD_IPXE=y
41+
CONFIG_IPXE_NO_PROMPT=y
42+
CONFIG_IPXE_ADD_SCRIPT=y
43+
CONFIG_IPXE_SCRIPT="3rdparty/dasharo-blobs/dasharo/protectli.ipxe"
44+
CONFIG_IPXE_CUSTOM_BUILD_ID="0123456789"
45+
CONFIG_DASHARO=y
46+
CONFIG_EDK2_ENABLE_IPXE=y
47+
CONFIG_EDK2_IPXE_OPTION_NAME="Network Boot and Utilities"
48+
# CONFIG_EDK2_SECURE_BOOT_DEFAULT_ENABLE is not set
49+
CONFIG_EDK2_SETUP_PASSWORD=y
50+
CONFIG_EDK2_DASHARO_SYSTEM_FEATURES=y
51+
CONFIG_EDK2_DASHARO_SECURITY_OPTIONS=y
52+
CONFIG_EDK2_DASHARO_USB_CONFIG=y
53+
CONFIG_EDK2_DASHARO_POWER_CONFIG=y
54+
CONFIG_EDK2_CPU_THROTTLING_THRESHOLD_OPTION=y
55+
CONFIG_EDK2_DASHARO_NETWORK_BOOT_DEFAULT_ENABLE=y
56+
CONFIG_EDK2_DASHARO_SERIAL_REDIRECTION_DEFAULT_ENABLE=y
57+
CONFIG_EDK2_HAVE_2ND_UART=y
58+
CONFIG_EDK2_DASHARO_SERIAL_REDIRECTION2_DEFAULT_ENABLE=y
59+
CONFIG_EDK2_BOOT_MENU_KEY=0x0015
60+
CONFIG_EDK2_SETUP_MENU_KEY=0x0008
61+
CONFIG_EDK2_DISABLE_OPTION_ROMS=y
62+
CONFIG_EDK2_CREATE_PREINSTALLED_BOOT_OPTIONS=y

src/mainboard/protectli/vault_adl_n/Kconfig

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,4 +92,10 @@ config BEEP_ON_BOOT
9292
May serve as a useful indicator in headless mode that platform is
9393
properly booting.
9494

95+
config ENABLE_EMMC
96+
bool "Enable eMMC support"
97+
default y
98+
help
99+
Enable the eMMC storage controller
100+
95101
endif

src/mainboard/protectli/vault_adl_n/mainboard.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
#include <device/device.h>
77
#include <pc80/i8254.h>
88
#include <smbios.h>
9+
#include <soc/pci_devs.h>
910
#include <soc/ramstage.h>
1011
#include <superio/ite/it8659e/chip.h>
1112
#include <superio/ite/it8659e/it8659e.h>
@@ -15,7 +16,7 @@
1516
const char *smbios_mainboard_product_name(void)
1617
{
1718
if (CONFIG(BOARD_PROTECTLI_VP2430))
18-
return "VP2430";
19+
return CONFIG(ENABLE_EMMC) ? "VP2430" : "VP2430e";
1920

2021
if (CONFIG(BOARD_PROTECTLI_VP2440))
2122
return "VP2440";
@@ -126,6 +127,11 @@ void mainboard_silicon_init_params(FSP_S_CONFIG *params)
126127
params->EnableTcssCovTypeA[1] = 1;
127128
params->MappingPchXhciUsbA[1] = 6;
128129
}
130+
131+
if (!CONFIG(ENABLE_EMMC)) {
132+
params->ScsEmmcEnabled = 0;
133+
pcidev_path_on_root(PCH_DEVFN_EMMC)->enabled = 0;
134+
}
129135
}
130136

131137
static void mainboard_final(void *chip_info)

0 commit comments

Comments
 (0)