From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web12.10035.1589196320476796493 for ; Mon, 11 May 2020 04:25:20 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: ard.biesheuvel@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 2B6F4106F; Mon, 11 May 2020 04:25:20 -0700 (PDT) Received: from [192.168.1.81] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id C37E93F305; Mon, 11 May 2020 04:25:18 -0700 (PDT) Subject: Re: [edk2-platforms][PATCH 2/2] RPi: allow selecting DT-only mode To: Pete Batard , Andrei Warkentin , devel@edk2.groups.io Cc: leif@nuviainc.com, philmd@redhat.com References: <20200510213450.12642-1-andrey.warkentin@gmail.com> <20200510213450.12642-3-andrey.warkentin@gmail.com> <7175d5c7-fd47-245b-f593-44b091966ea7@akeo.ie> From: "Ard Biesheuvel" Message-ID: <1a076882-c950-69f9-4738-e76660af95af@arm.com> Date: Mon, 11 May 2020 13:25:16 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: <7175d5c7-fd47-245b-f593-44b091966ea7@akeo.ie> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 5/11/20 12:58 PM, Pete Batard wrote: > On 2020.05.10 22:34, Andrei Warkentin wrote: >> Today the Pies can be booted in a way where only ACPI is exposed, >> or both ACPI and DT are exposed. >> >> This adds one more mode - DT only, no ACPI. The target audience >> is developers. When both are exposed, it's up to the OS to decide >> which gets used, and that choice can differ between OSes, >> >> Note: this does _not_ change defaults. Pi 3 still defaults to >> ACPI + DT, while Pi 4 still defaults to ACPI only. >> >> We don't really want to remove DT + ACPI mode - it is the default >> on Pi 3, and removing it is bound to just annoy users - WoA and >> NetBSD (voa UEFI) on Pi 3 only work with ACPI, while everything >> else (Linux, FreeBSD) only work with DT. I'd make an analogy of >> MPS and ACPI being exposed for the longest time ever together on >> PCs. >=20 > I agree with this. >=20 > Even if other platforms may avoid this configuration, we did make DT +=20 > ACPI mode the default for the Pi 3, and folks might already be using=20 > this setup on the Pi 3 to boot Linux in DT mode and Windows in ACPI mod= e=20 > without having to change their settings. So removing that dual mode may= =20 > be seen as a regression. >=20 Fair enough. >> >> Testing: OpenBSD on Pi 4 with DT-only and ACPI-only boots. >> >> Signed-off-by: Andrei Warkentin >> --- >> =C2=A0 Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.c=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 | 11=20 >> +++++++---- >> =C2=A0 Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.inf=C2=A0=C2=A0= =C2=A0 |=C2=A0 2 +- >> =C2=A0 Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.uni |=C2=A0= 9 +++++---- >> =C2=A0 Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.vfr | 15=20 >> ++++++++------- >> =C2=A0 Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.c=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0 3 ++- >> =C2=A0 Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.inf=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0 2 +- >> =C2=A0 Platform/RaspberryPi/Include/ConfigVars.h=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 | 11=20 >> +++++------ >> =C2=A0 Platform/RaspberryPi/RPi3/RPi3.dsc=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0 |=C2=A0 8 ++++++-- >> =C2=A0 Platform/RaspberryPi/RPi4/RPi4.dsc=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0 |=C2=A0 8 ++++++-- >> =C2=A0 Platform/RaspberryPi/RaspberryPi.dec=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 |=C2=A0 2 +- >> =C2=A0 10 files changed, 42 insertions(+), 29 deletions(-) >> >> diff --git a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.c=20 >> b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.c >> index 8c9609f3..29701db2 100644 >> --- a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.c >> +++ b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.c >> @@ -155,11 +155,11 @@ SetupVariables ( >> =C2=A0=C2=A0=C2=A0 } >> =C2=A0=C2=A0=C2=A0 Size =3D sizeof (UINT32); >> -=C2=A0 Status =3D gRT->GetVariable (L"OptDeviceTree", >> +=C2=A0 Status =3D gRT->GetVariable (L"SystemTableMode", >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 &gConfigDxeFormSetGuid, >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 NULL, &Size, &Var32); >> =C2=A0=C2=A0=C2=A0 if (EFI_ERROR (Status)) { >> -=C2=A0=C2=A0=C2=A0 PcdSet32 (PcdOptDeviceTree, PcdGet32 (PcdOptDevice= Tree)); >> +=C2=A0=C2=A0=C2=A0 PcdSet32 (PcdSystemTableMode, PcdGet32 (PcdSystemT= ableMode)); >> =C2=A0=C2=A0=C2=A0 } >> =C2=A0=C2=A0=C2=A0 Size =3D sizeof (UINT32); >> @@ -488,8 +488,11 @@ ConfigInitialize ( >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 DEBUG ((DEBUG_ERROR, "Couldn't install = ConfigDxe configuration=20 >> pages: %r\n", Status)); >> =C2=A0=C2=A0=C2=A0 } >> -=C2=A0 Status =3D LocateAndInstallAcpiFromFv (&mAcpiTableFile); >> -=C2=A0 ASSERT_EFI_ERROR (Status); >> +=C2=A0 if (PcdGet32 (PcdSystemTableMode) =3D=3D SYSTEM_TABLE_MODE_ACP= I || >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 PcdGet32 (PcdSystemTableMode) =3D=3D S= YSTEM_TABLE_MODE_BOTH) { >=20 > Overall, I think code readability might have been improved by using=20 > bitmasks (e.g. bit 0 for ACPI, bit 1 for DT) rather than a triplet of=20 > values, but I'm fine with the patch as it stands. >=20 >> +=C2=A0=C2=A0=C2=A0=C2=A0 Status =3D LocateAndInstallAcpiFromFv (&mAcp= iTableFile); >> +=C2=A0=C2=A0=C2=A0=C2=A0 ASSERT_EFI_ERROR (Status); >> +=C2=A0 } >> =C2=A0=C2=A0=C2=A0 return EFI_SUCCESS; >> diff --git a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.inf=20 >> b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.inf >> index 57963baf..e47f3af6 100644 >> --- a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.inf >> +++ b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxe.inf >> @@ -77,7 +77,7 @@ >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdDebugShowUEFIExit >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdDisplayEnableScaledVM= odes >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdDisplayEnableSShot >> -=C2=A0 gRaspberryPiTokenSpaceGuid.PcdOptDeviceTree >> +=C2=A0 gRaspberryPiTokenSpaceGuid.PcdSystemTableMode >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdRamMoreThan3GB >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdRamLimitTo3GB >> diff --git a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.uni=20 >> b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.uni >> index 07660072..db36e200 100644 >> --- a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.uni >> +++ b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.uni >> @@ -41,10 +41,11 @@ >> =C2=A0 #string STR_ADVANCED_3GB_OFF=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 #language en-US "Disabled" >> =C2=A0 #string STR_ADVANCED_3GB_ON=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 #language en-US "Enabled" >> -#string STR_ADVANCED_DT_PROMPT=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 #l= anguage en-US "Device Tree" >> -#string STR_ADVANCED_DT_HELP=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0 #language en-US "Disable this=20 >> option to force OSes such as GNU/Linux to use ACPI" >> -#string STR_ADVANCED_DT_OFF=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 #language en-US "Disabled (Force=20 >> ACPI)" >> -#string STR_ADVANCED_DT_ON=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 #language en-US "Enabled" >> +#string STR_ADVANCED_SYSTAB_PROMPT=C2=A0=C2=A0 #language en-US "Syste= m Table=20 >> Selection" >> +#string STR_ADVANCED_SYSTAB_HELP=C2=A0=C2=A0=C2=A0=C2=A0 #language en= -US "ACPI/DT choice=20 >> for specific OSes" >> +#string STR_ADVANCED_SYSTAB_ACPI=C2=A0=C2=A0=C2=A0=C2=A0 #language en= -US "ACPI" >> +#string STR_ADVANCED_SYSTAB_BOTH=C2=A0=C2=A0=C2=A0=C2=A0 #language en= -US "ACPI + Devicetree" >> +#string STR_ADVANCED_SYSTAB_DT=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 #l= anguage en-US "Devicetree" >> =C2=A0 /* >> =C2=A0=C2=A0 * MMC/SD configuration. >> diff --git a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.vfr=20 >> b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.vfr >> index 576eabe9..91a0ea2d 100644 >> --- a/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.vfr >> +++ b/Platform/RaspberryPi/Drivers/ConfigDxe/ConfigDxeHii.vfr >> @@ -44,9 +44,9 @@ formset >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 name=C2=A0 =3D RamLimitTo3G= B, >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 guid=C2=A0 =3D CONFIGDXE_FO= RM_SET_GUID; >> -=C2=A0=C2=A0=C2=A0 efivarstore ADVANCED_DEVICE_TREE_VARSTORE_DATA, >> +=C2=A0=C2=A0=C2=A0 efivarstore SYSTEM_TABLE_MODE_VARSTORE_DATA, >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 attribute =3D EFI_VARIABLE_= BOOTSERVICE_ACCESS |=20 >> EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_NON_VOLATILE, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 name=C2=A0 =3D OptDeviceTree, >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 name=C2=A0 =3D SystemTableMode, >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 guid=C2=A0 =3D CONFIGDXE_FO= RM_SET_GUID; >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 efivarstore MMC_SD_VARSTORE_DATA, >> @@ -164,12 +164,13 @@ formset >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 end= oneof; >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 endif; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 oneof varid =3D OptDeviceT= ree.Enabled, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 pr= ompt=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D STRING_TOKEN(STR_ADVANCED_DT_PROMP= T), >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 he= lp=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D STRING_TOKEN(STR_ADVANCE= D_DT_HELP), >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 oneof varid =3D SystemTabl= eMode.Mode, >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 pr= ompt=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D STRING_TOKEN(STR_ADVANCED_SYSTAB_P= ROMPT), >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 he= lp=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D STRING_TOKEN(STR_ADVANCE= D_SYSTAB_HELP), >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0 flags=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D NUMERIC_SIZE_4 | INT= ERACTIVE |=20 >> RESET_REQUIRED, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 op= tion text =3D STRING_TOKEN(STR_ADVANCED_DT_OFF), value =3D=20 >> 0, flags =3D 0; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 op= tion text =3D STRING_TOKEN(STR_ADVANCED_DT_ON), value =3D=20 >> 1, flags =3D DEFAULT; >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 op= tion text =3D STRING_TOKEN(STR_ADVANCED_SYSTAB_ACPI),=20 >> value =3D SYSTEM_TABLE_MODE_ACPI, flags =3D 0; >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 op= tion text =3D STRING_TOKEN(STR_ADVANCED_SYSTAB_BOTH),=20 >> value =3D SYSTEM_TABLE_MODE_BOTH, flags =3D DEFAULT; >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 op= tion text =3D STRING_TOKEN(STR_ADVANCED_SYSTAB_DT), value=20 >> =3D SYSTEM_TABLE_MODE_DT, flags =3D DEFAULT; >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 endoneof; >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 endform; >> diff --git a/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.c=20 >> b/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.c >> index 3aaa0a7f..44c6c87c 100644 >> --- a/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.c >> +++ b/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.c >> @@ -355,7 +355,8 @@ FdtDxeInitialize ( >> =C2=A0=C2=A0=C2=A0 UINTN=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 FdtSize; >> =C2=A0=C2=A0=C2=A0 VOID=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 *FdtImage = =3D NULL; >> -=C2=A0 if (PcdGet32 (PcdOptDeviceTree) =3D=3D 0) { >> +=C2=A0 if (PcdGet32 (PcdSystemTableMode) !=3D SYSTEM_TABLE_MODE_BOTH = && >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 PcdGet32 (PcdSystemTableMode) !=3D SYS= TEM_TABLE_MODE_DT) { >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 DEBUG ((DEBUG_INFO, "Device Tree disabl= ed per user=20 >> configuration\n")); >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 return EFI_SUCCESS; >> =C2=A0=C2=A0=C2=A0 } >> diff --git a/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.inf=20 >> b/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.inf >> index 49ba5ba1..26f84e59 100644 >> --- a/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.inf >> +++ b/Platform/RaspberryPi/Drivers/FdtDxe/FdtDxe.inf >> @@ -46,4 +46,4 @@ >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdFdtBaseAddress >> =C2=A0 [Pcd] >> -=C2=A0 gRaspberryPiTokenSpaceGuid.PcdOptDeviceTree >> +=C2=A0 gRaspberryPiTokenSpaceGuid.PcdSystemTableMode >> diff --git a/Platform/RaspberryPi/Include/ConfigVars.h=20 >> b/Platform/RaspberryPi/Include/ConfigVars.h >> index a0959b4b..28837f98 100644 >> --- a/Platform/RaspberryPi/Include/ConfigVars.h >> +++ b/Platform/RaspberryPi/Include/ConfigVars.h >> @@ -76,12 +76,11 @@ typedef struct { >> =C2=A0 } ADVANCED_RAM_LIMIT_TO_3GB_VARSTORE_DATA; >> =C2=A0 typedef struct { >> -=C2=A0 /* >> -=C2=A0=C2=A0 * 0 - Do not provide a Device Tree to the OS >> -=C2=A0=C2=A0 * 1 - Provide a Device Tree to the OS >> -=C2=A0=C2=A0 */ >> -=C2=A0 UINT32 Enabled; >> -} ADVANCED_DEVICE_TREE_VARSTORE_DATA; >> +#define SYSTEM_TABLE_MODE_ACPI 0 >> +#define SYSTEM_TABLE_MODE_BOTH 1 >> +#define SYSTEM_TABLE_MODE_DT=C2=A0=C2=A0 2 >> +=C2=A0 UINT32 Mode; >> +} SYSTEM_TABLE_MODE_VARSTORE_DATA; >> =C2=A0 typedef struct { >> =C2=A0=C2=A0=C2=A0 /* >> diff --git a/Platform/RaspberryPi/RPi3/RPi3.dsc=20 >> b/Platform/RaspberryPi/RPi3/RPi3.dsc >> index 563fb891..a138c874 100644 >> --- a/Platform/RaspberryPi/RPi3/RPi3.dsc >> +++ b/Platform/RaspberryPi/RPi3/RPi3.dsc >> @@ -481,9 +481,13 @@ >> =20 >> gRaspberryPiTokenSpaceGuid.PcdRamLimitTo3GB|L"RamLimitTo3GB"|gConfigDx= eFormSetGuid|0x0|0=20 >> >> =C2=A0=C2=A0=C2=A0 # >> -=C2=A0 # Device Tree >> +=C2=A0 # Device Tree and ACPI selection. >> =C2=A0=C2=A0=C2=A0 # >> - =20 >> gRaspberryPiTokenSpaceGuid.PcdOptDeviceTree|L"OptDeviceTree"|gConfigDx= eFormSetGuid|0x0|1=20 >> >> +=C2=A0 # 0 - SYSTEM_TABLE_MODE_ACPI >> +=C2=A0 # 1 - SYSTEM_TABLE_MODE_BOTH (default) >> +=C2=A0 # 2 - SYSTEM_TABLE_MODE_DT >> +=C2=A0 # >> + =20 >> gRaspberryPiTokenSpaceGuid.PcdSystemTableMode|L"SystemTableMode"|gConf= igDxeFormSetGuid|0x0|1=20 >> >> =C2=A0=C2=A0=C2=A0 # >> =C2=A0=C2=A0=C2=A0 # Common UEFI ones. >> diff --git a/Platform/RaspberryPi/RPi4/RPi4.dsc=20 >> b/Platform/RaspberryPi/RPi4/RPi4.dsc >> index 4deccd9d..75867f03 100644 >> --- a/Platform/RaspberryPi/RPi4/RPi4.dsc >> +++ b/Platform/RaspberryPi/RPi4/RPi4.dsc >> @@ -496,9 +496,13 @@ >> =20 >> gRaspberryPiTokenSpaceGuid.PcdRamLimitTo3GB|L"RamLimitTo3GB"|gConfigDx= eFormSetGuid|0x0|1=20 >> >> =C2=A0=C2=A0=C2=A0 # >> -=C2=A0 # Device Tree >> +=C2=A0 # Device Tree and ACPI selection. >> =C2=A0=C2=A0=C2=A0 # >> - =20 >> gRaspberryPiTokenSpaceGuid.PcdOptDeviceTree|L"OptDeviceTree"|gConfigDx= eFormSetGuid|0x0|0=20 >> >> +=C2=A0 # 0 - SYSTEM_TABLE_MODE_ACPI (default) >> +=C2=A0 # 1 - SYSTEM_TABLE_MODE_BOTH >> +=C2=A0 # 2 - SYSTEM_TABLE_MODE_DT >> +=C2=A0 # >> + =20 >> gRaspberryPiTokenSpaceGuid.PcdSystemTableMode|L"SystemTableMode"|gConf= igDxeFormSetGuid|0x0|0=20 >> >> =C2=A0=C2=A0=C2=A0 # >> =C2=A0=C2=A0=C2=A0 # Common UEFI ones. >> diff --git a/Platform/RaspberryPi/RaspberryPi.dec=20 >> b/Platform/RaspberryPi/RaspberryPi.dec >> index 66ef6186..1a3c44e0 100644 >> --- a/Platform/RaspberryPi/RaspberryPi.dec >> +++ b/Platform/RaspberryPi/RaspberryPi.dec >> @@ -65,6 +65,6 @@ >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdCustomCpuClock|0|UINT= 32|0x00000016 >> =20 >> gRaspberryPiTokenSpaceGuid.PcdDisplayEnableScaledVModes|0x3F|UINT8|0x0= 0000017=20 >> >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdDisplayEnableSShot|0|= UINT32|0x00000018 >> -=C2=A0 gRaspberryPiTokenSpaceGuid.PcdOptDeviceTree|1|UINT32|0x0000001= B >> +=C2=A0 gRaspberryPiTokenSpaceGuid.PcdSystemTableMode|1|UINT32|0x00000= 01B >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdRamMoreThan3GB|0|UINT= 32|0x00000019 >> =C2=A0=C2=A0=C2=A0 gRaspberryPiTokenSpaceGuid.PcdRamLimitTo3GB|0|UINT3= 2|0x0000001A >> >=20 > Reviewed-by: Pete Batard >=20