* [edk2-platform][PATCH v2 0/2] Platforms/RaspberryPi: Add RPi settings to Readme
@ 2020-06-15 21:43 Samer El-Haj-Mahmoud
2020-06-15 21:43 ` [edk2-platform][PATCH v2 1/2] Platforms/RaspberryPi: Add RPi4 " Samer El-Haj-Mahmoud
2020-06-15 21:43 ` [edk2-platform][PATCH v2 2/2] Platforms/RaspberryPi: Add RPi3 " Samer El-Haj-Mahmoud
0 siblings, 2 replies; 4+ messages in thread
From: Samer El-Haj-Mahmoud @ 2020-06-15 21:43 UTC (permalink / raw)
To: devel; +Cc: Leif Lindholm, Ard Biesheuvel, Pete Batard, Andrei Warkentin
Add a section to the the RPi3/4 Readme for 'Configuration Settings', with
instructions on scripting from the UEFI Shell.
Cc: Leif Lindholm <leif@nuviainc.com>
Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
Cc: Pete Batard <pete@akeo.ie>
Cc: Andrei Warkentin <awarkentin@vmware.com>
Signed-off-by: Samer El-Haj-Mahmoud <samer.el-haj-mahmoud@arm.com>
Samer El-Haj-Mahmoud (2):
Platforms/RaspberryPi: Add RPi4 settings to Readme
Platforms/RaspberryPi: Add RPi3 settings to Readme
Platform/RaspberryPi/RPi3/Readme.md | 61 ++++++++++++++++
Platform/RaspberryPi/RPi4/Readme.md | 74 +++++++++++++++++++-
2 files changed, 134 insertions(+), 1 deletion(-)
--
2.17.1
^ permalink raw reply [flat|nested] 4+ messages in thread
* [edk2-platform][PATCH v2 1/2] Platforms/RaspberryPi: Add RPi4 settings to Readme
2020-06-15 21:43 [edk2-platform][PATCH v2 0/2] Platforms/RaspberryPi: Add RPi settings to Readme Samer El-Haj-Mahmoud
@ 2020-06-15 21:43 ` Samer El-Haj-Mahmoud
2020-06-16 8:13 ` Pete Batard
2020-06-15 21:43 ` [edk2-platform][PATCH v2 2/2] Platforms/RaspberryPi: Add RPi3 " Samer El-Haj-Mahmoud
1 sibling, 1 reply; 4+ messages in thread
From: Samer El-Haj-Mahmoud @ 2020-06-15 21:43 UTC (permalink / raw)
To: devel; +Cc: Leif Lindholm, Ard Biesheuvel, Pete Batard, Andrei Warkentin
Add a section to the the RPi4 Readme for 'Configuration Settings', with
instructions on scripting from the UEFI Shell.
Cc: Leif Lindholm <leif@nuviainc.com>
Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
Cc: Pete Batard <pete@akeo.ie>
Cc: Andrei Warkentin <awarkentin@vmware.com>
Signed-off-by: Samer El-Haj-Mahmoud <samer.el-haj-mahmoud@arm.com>
---
Platform/RaspberryPi/RPi4/Readme.md | 74 +++++++++++++++++++-
1 file changed, 73 insertions(+), 1 deletion(-)
diff --git a/Platform/RaspberryPi/RPi4/Readme.md b/Platform/RaspberryPi/RPi4/Readme.md
index 03eb6c391aca..98388e3caba1 100644
--- a/Platform/RaspberryPi/RPi4/Readme.md
+++ b/Platform/RaspberryPi/RPi4/Readme.md
@@ -143,4 +143,76 @@ all functionality may be available.
- Network booting via onboard NIC.
- SPCR hardcodes type to PL011, and thus will not expose correct
- (miniUART) UART if DT overlays to switch UART are used on Pi 4B.
\ No newline at end of file
+ (miniUART) UART if DT overlays to switch UART are used on Pi 4B.
+
+# Configuration Settings
+The Raspberry Pi UEFI configuration settings can be viewed and changed using both the UI configuration menu (under `Device Manager` -> `Raspberry Pi Configuration`), as well as the UEFI Shell. To configure using the UEFI Shell, use `setvar` command to read/write the UEFI variables with GUID = `CD7CC258-31DB-22E6-9F22-63B0B8EED6B5`.
+
+The syntax to read a setting is:
+```
+setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
+```
+
+The syntax to write a setting is:
+```
+setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =<VALUE>
+```
+
+For string-type settings (e.g. Asset Tag), the syntax to write is:
+```
+setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =L"<VALUE>" =0x0000
+```
+
+UEFI Setting | NAME | VALUE
+-----------------------------|-----------------------|-----------------------------
+**CPU Configuration** |
+CPU Clock | `CpuClock` | Low = `0x00000000`<br> Default = `0x00000001` (default)<br> Max = `0x00000002`<br> Custom = `0x00000003`
+CPU Clock Rate (MHz) | `CustomCpuClock` | Hex numeric value, 4-bytes<br> (e.g. `0x000005DC` for 1500 MHz)
+**Display Configuration** |
+Virtual 640x480 | `DisplayEnableScaledVModes` | Checked = Bit 0 set (i.e. `<DisplayEnableScaledVModes> \| 0x01`)
+Virtual 800x600 | `DisplayEnableScaledVModes` | Checked = Bit 1 set (i.e. `<DisplayEnableScaledVModes> \| 0x02`)
+Virtual 1024x768 | `DisplayEnableScaledVModes` | Checked = Bit 2 set (i.e. `<DisplayEnableScaledVModes> \| 0x04`)
+Virtual 720p | `DisplayEnableScaledVModes` | Checked = Bit 3 set (i.e. `<DisplayEnableScaledVModes> \| 0x08`)
+Virtual 1080p | `DisplayEnableScaledVModes` | Checked = Bit 4 set (i.e. `<DisplayEnableScaledVModes> \| 0x10`)
+Native resolution | `DisplayEnableScaledVModes` | Checked = Bit 5 set (i.e. `<DisplayEnableScaledVModes> \| 0x20`) (default)
+Screenshot support | `DisplayEnableSShot` | Control-Alt-F12 = `0x00000001` (default)<br> Not Enabled = `0x00000000`
+**Advanced Configuration** |
+Limit RAM to 3 GB | `RamLimitTo3GB` | Disable = `0x00000000` <br> Enabled= `0x00000001` (default)
+System Table Selection | `SystemTableMode`| ACPI = `0x00000000` (default)<br> ACPI + Devicetree = `0x00000001` <br> Devicetree = `0x00000002`
+Asset Tag | `AssetTag` | String, 32 characters or less (e.g. `L"ABCD123"`)<br> (default `L""`)
+**SD/MMC Configuration** |
+uSD/eMMC Routing | `SdIsArasan` | Arasan SDHC = `0x00000001` (default) <br> eMMC2 SDHCI = `0x00000000`
+Multi-Block Support | `MmcDisableMulti` | Multi-block transfers = `0x00000000` (default)<br> Single block transfers = `0x00000001`
+uSD Max Bus Width | `MmcForce1Bit` | 4-bit Mode = `0x00000000` (default)<br> 1-bit Mode = `0x00000001`
+uSD Force Default Speed | `MmcForceDefaultSpeed` | Allow High Speed = `0x00000000` (default)<br> Force Default Speed = `0x00000001`
+SD Default Speed (MHz) | `MmcSdDefaultSpeedMHz` | Hex numeric value, 4-bytes (e.g. `0x00000019` for 25 MHz)<br>(default 25)
+SD High Speed (MHz) | `MmcSdHighSpeedMHz` | Hex numeric value, 4-bytes (e.g. `0x00000032` for 50 MHz)<br>(default 50)
+**Debugging Configuration** |
+JTAG Routing | `DebugEnableJTAG` | Enable JTAG via GPIO = `0x00000001`<br> Disable JTAG= `0x00000000` (default)
+
+**Examples:**
+
+- To read the 'System Table Selection' setting :
+```
+setvar SystemTableMode -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
+```
+
+- To change the 'System Table Selection' setting to 'Devicetree' :
+```
+setvar SystemTableMode -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =0x00000002
+```
+
+- To read the 'Limit RAM to 3 GB' setting:
+```
+setvar RamLimitTo3GB -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
+```
+
+- To change the 'Limit RAM to 3 GB' setting to 'Disabled':
+```
+setvar RamLimitTo3GB -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =0x00000000
+```
+
+- To change the Asset Tag to the string "ASSET-TAG-123" :
+```
+setvar AssetTag -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =L"ASSET-TAG-123" =0x0000
+```
--
2.17.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [edk2-platform][PATCH v2 1/2] Platforms/RaspberryPi: Add RPi4 settings to Readme
2020-06-15 21:43 ` [edk2-platform][PATCH v2 1/2] Platforms/RaspberryPi: Add RPi4 " Samer El-Haj-Mahmoud
@ 2020-06-16 8:13 ` Pete Batard
0 siblings, 0 replies; 4+ messages in thread
From: Pete Batard @ 2020-06-16 8:13 UTC (permalink / raw)
To: Samer El-Haj-Mahmoud, devel
Cc: Leif Lindholm, Ard Biesheuvel, Andrei Warkentin
On 2020.06.15 22:43, Samer El-Haj-Mahmoud wrote:
> Add a section to the the RPi4 Readme for 'Configuration Settings', with
> instructions on scripting from the UEFI Shell.
>
> Cc: Leif Lindholm <leif@nuviainc.com>
> Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
> Cc: Pete Batard <pete@akeo.ie>
> Cc: Andrei Warkentin <awarkentin@vmware.com>
> Signed-off-by: Samer El-Haj-Mahmoud <samer.el-haj-mahmoud@arm.com>
> ---
> Platform/RaspberryPi/RPi4/Readme.md | 74 +++++++++++++++++++-
> 1 file changed, 73 insertions(+), 1 deletion(-)
>
> diff --git a/Platform/RaspberryPi/RPi4/Readme.md b/Platform/RaspberryPi/RPi4/Readme.md
> index 03eb6c391aca..98388e3caba1 100644
> --- a/Platform/RaspberryPi/RPi4/Readme.md
> +++ b/Platform/RaspberryPi/RPi4/Readme.md
> @@ -143,4 +143,76 @@ all functionality may be available.
>
> - Network booting via onboard NIC.
> - SPCR hardcodes type to PL011, and thus will not expose correct
> - (miniUART) UART if DT overlays to switch UART are used on Pi 4B.
> \ No newline at end of file
> + (miniUART) UART if DT overlays to switch UART are used on Pi 4B.
> +
> +# Configuration Settings
> +The Raspberry Pi UEFI configuration settings can be viewed and changed using both the UI configuration menu (under `Device Manager` -> `Raspberry Pi Configuration`), as well as the UEFI Shell. To configure using the UEFI Shell, use `setvar` command to read/write the UEFI variables with GUID = `CD7CC258-31DB-22E6-9F22-63B0B8EED6B5`.
> +
> +The syntax to read a setting is:
> +```
> +setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
> +```
> +
> +The syntax to write a setting is:
> +```
> +setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =<VALUE>
> +```
> +
> +For string-type settings (e.g. Asset Tag), the syntax to write is:
> +```
> +setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =L"<VALUE>" =0x0000
> +```
> +
> +UEFI Setting | NAME | VALUE
> +-----------------------------|-----------------------|-----------------------------
> +**CPU Configuration** |
> +CPU Clock | `CpuClock` | Low = `0x00000000`<br> Default = `0x00000001` (default)<br> Max = `0x00000002`<br> Custom = `0x00000003`
> +CPU Clock Rate (MHz) | `CustomCpuClock` | Hex numeric value, 4-bytes<br> (e.g. `0x000005DC` for 1500 MHz)
> +**Display Configuration** |
> +Virtual 640x480 | `DisplayEnableScaledVModes` | Checked = Bit 0 set (i.e. `<DisplayEnableScaledVModes> \| 0x01`)
> +Virtual 800x600 | `DisplayEnableScaledVModes` | Checked = Bit 1 set (i.e. `<DisplayEnableScaledVModes> \| 0x02`)
> +Virtual 1024x768 | `DisplayEnableScaledVModes` | Checked = Bit 2 set (i.e. `<DisplayEnableScaledVModes> \| 0x04`)
> +Virtual 720p | `DisplayEnableScaledVModes` | Checked = Bit 3 set (i.e. `<DisplayEnableScaledVModes> \| 0x08`)
> +Virtual 1080p | `DisplayEnableScaledVModes` | Checked = Bit 4 set (i.e. `<DisplayEnableScaledVModes> \| 0x10`)
> +Native resolution | `DisplayEnableScaledVModes` | Checked = Bit 5 set (i.e. `<DisplayEnableScaledVModes> \| 0x20`) (default)
> +Screenshot support | `DisplayEnableSShot` | Control-Alt-F12 = `0x00000001` (default)<br> Not Enabled = `0x00000000`
> +**Advanced Configuration** |
> +Limit RAM to 3 GB | `RamLimitTo3GB` | Disable = `0x00000000` <br> Enabled= `0x00000001` (default)
> +System Table Selection | `SystemTableMode`| ACPI = `0x00000000` (default)<br> ACPI + Devicetree = `0x00000001` <br> Devicetree = `0x00000002`
> +Asset Tag | `AssetTag` | String, 32 characters or less (e.g. `L"ABCD123"`)<br> (default `L""`)
> +**SD/MMC Configuration** |
> +uSD/eMMC Routing | `SdIsArasan` | Arasan SDHC = `0x00000001` (default) <br> eMMC2 SDHCI = `0x00000000`
> +Multi-Block Support | `MmcDisableMulti` | Multi-block transfers = `0x00000000` (default)<br> Single block transfers = `0x00000001`
> +uSD Max Bus Width | `MmcForce1Bit` | 4-bit Mode = `0x00000000` (default)<br> 1-bit Mode = `0x00000001`
> +uSD Force Default Speed | `MmcForceDefaultSpeed` | Allow High Speed = `0x00000000` (default)<br> Force Default Speed = `0x00000001`
> +SD Default Speed (MHz) | `MmcSdDefaultSpeedMHz` | Hex numeric value, 4-bytes (e.g. `0x00000019` for 25 MHz)<br>(default 25)
> +SD High Speed (MHz) | `MmcSdHighSpeedMHz` | Hex numeric value, 4-bytes (e.g. `0x00000032` for 50 MHz)<br>(default 50)
> +**Debugging Configuration** |
> +JTAG Routing | `DebugEnableJTAG` | Enable JTAG via GPIO = `0x00000001`<br> Disable JTAG= `0x00000000` (default)
> +
> +**Examples:**
> +
> +- To read the 'System Table Selection' setting :
> +```
> +setvar SystemTableMode -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
> +```
> +
> +- To change the 'System Table Selection' setting to 'Devicetree' :
> +```
> +setvar SystemTableMode -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =0x00000002
> +```
> +
> +- To read the 'Limit RAM to 3 GB' setting:
> +```
> +setvar RamLimitTo3GB -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
> +```
> +
> +- To change the 'Limit RAM to 3 GB' setting to 'Disabled':
> +```
> +setvar RamLimitTo3GB -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =0x00000000
> +```
> +
> +- To change the Asset Tag to the string "ASSET-TAG-123" :
> +```
> +setvar AssetTag -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =L"ASSET-TAG-123" =0x0000
> +```
>
Reviewed-by: Pete Batard <pete@akeo.ie>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [edk2-platform][PATCH v2 2/2] Platforms/RaspberryPi: Add RPi3 settings to Readme
2020-06-15 21:43 [edk2-platform][PATCH v2 0/2] Platforms/RaspberryPi: Add RPi settings to Readme Samer El-Haj-Mahmoud
2020-06-15 21:43 ` [edk2-platform][PATCH v2 1/2] Platforms/RaspberryPi: Add RPi4 " Samer El-Haj-Mahmoud
@ 2020-06-15 21:43 ` Samer El-Haj-Mahmoud
1 sibling, 0 replies; 4+ messages in thread
From: Samer El-Haj-Mahmoud @ 2020-06-15 21:43 UTC (permalink / raw)
To: devel
Add a section to the the RPi3 readme for 'Configuration Settings', with
instructions on scripting from the UEFI Shell.
Signed-off-by: Samer El-Haj-Mahmoud <samer.el-haj-mahmoud@arm.com>
---
Platform/RaspberryPi/RPi3/Readme.md | 61 ++++++++++++++++++++
1 file changed, 61 insertions(+)
diff --git a/Platform/RaspberryPi/RPi3/Readme.md b/Platform/RaspberryPi/RPi3/Readme.md
index 075ea199a0d9..9080cff15841 100644
--- a/Platform/RaspberryPi/RPi3/Readme.md
+++ b/Platform/RaspberryPi/RPi3/Readme.md
@@ -201,3 +201,64 @@ install a kernel that relies on Device Tree rather than ACPI.
- SPCR hardcodes UART type to miniUART, and thus will not expose correct
(PL011) UART on CM3 and Pi2B or if DT overlays to switch UART are used
on Pi 3B/3B+/3A+.
+
+# Configuration Settings
+The Raspberry Pi UEFI configuration settings can be viewed and changed using both the UI configuration menu (under `Device Manager` -> `Raspberry Pi Configuration`), as well as the UEFI Shell. To configure using the UEFI Shell, use `setvar` command to read/write the UEFI variables with GUID = `CD7CC258-31DB-22E6-9F22-63B0B8EED6B5`.
+
+The syntax to read a setting is:
+```
+setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
+```
+
+The syntax to write a setting is:
+```
+setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =<VALUE>
+```
+
+For string-type settings (e.g. Asset Tag), the syntax to write is:
+```
+setvar <NAME> -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =L"<VALUE>" =0x0000
+```
+
+UEFI Setting | NAME | VALUE
+-----------------------------|-----------------------|-----------------------------
+**CPU Configuration** |
+CPU Clock | `CpuClock` | Low = `0x00000000`<br> Default = `0x00000001` (default)<br> Max = `0x00000002`<br> Custom = `0x00000003`
+CPU Clock Rate (MHz) | `CustomCpuClock` | Hex numeric value, 4-bytes<br> (e.g. `0x000005DC` for 1500 MHz)
+**Display Configuration** |
+Virtual 640x480 | `DisplayEnableScaledVModes` | Checked = Bit 0 set (i.e. `<DisplayEnableScaledVModes> \| 0x01`)
+Virtual 800x600 | `DisplayEnableScaledVModes` | Checked = Bit 1 set (i.e. `<DisplayEnableScaledVModes> \| 0x02`)
+Virtual 1024x768 | `DisplayEnableScaledVModes` | Checked = Bit 2 set (i.e. `<DisplayEnableScaledVModes> \| 0x04`)
+Virtual 720p | `DisplayEnableScaledVModes` | Checked = Bit 3 set (i.e. `<DisplayEnableScaledVModes> \| 0x08`)
+Virtual 1080p | `DisplayEnableScaledVModes` | Checked = Bit 4 set (i.e. `<DisplayEnableScaledVModes> \| 0x10`)
+Native resolution | `DisplayEnableScaledVModes` | Checked = Bit 5 set (i.e. `<DisplayEnableScaledVModes> \| 0x20`) (default)
+Screenshot support | `DisplayEnableSShot` | Control-Alt-F12 = `0x00000001` (default)<br> Not Enabled = `0x00000000`
+**Advanced Configuration** |
+System Table Selection | `SystemTableMode`| ACPI = `0x00000000` <br> ACPI + Devicetree = `0x00000001` (default)<br> Devicetree = `0x00000002`
+Asset Tag | `AssetTag` | String, 32 characters or less (e.g. `L"ABCD123"`)<br> (default `L""`)
+**SD/MMC Configuration** |
+uSD/eMMC Routing | `SdIsArasan` | Arasan SDHC = `0x00000001` <br> Broadcom SDHOST = `0x00000000` (default)
+Multi-Block Support | `MmcDisableMulti` | Multi-block transfers = `0x00000000` (default)<br> Single block transfers = `0x00000001`
+uSD Max Bus Width | `MmcForce1Bit` | 4-bit Mode = `0x00000000` (default)<br> 1-bit Mode = `0x00000001`
+uSD Force Default Speed | `MmcForceDefaultSpeed` | Allow High Speed = `0x00000000` (default)<br> Force Default Speed = `0x00000001`
+SD Default Speed (MHz) | `MmcSdDefaultSpeedMHz` | Hex numeric value, 4-bytes (e.g. `0x00000019` for 25 MHz)<br>(default 25)
+SD High Speed (MHz) | `MmcSdHighSpeedMHz` | Hex numeric value, 4-bytes (e.g. `0x00000032` for 50 MHz)<br>(default 50)
+**Debugging Configuration** |
+JTAG Routing | `DebugEnableJTAG` | Enable JTAG via GPIO = `0x00000001`<br> Disable JTAG= `0x00000000` (default)
+
+**Examples:**
+
+- To read the 'System Table Selection' setting :
+```
+setvar SystemTableMode -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5
+```
+
+- To change the 'System Table Selection' setting to 'Devicetree' :
+```
+setvar SystemTableMode -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =0x00000002
+```
+
+- To change the Asset Tag to the string "ASSET-TAG-123" :
+```
+setvar AssetTag -guid CD7CC258-31DB-22E6-9F22-63B0B8EED6B5 -bs -rt -nv =L"ASSET-TAG-123" =0x0000
+```
--
2.17.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-06-16 8:13 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-15 21:43 [edk2-platform][PATCH v2 0/2] Platforms/RaspberryPi: Add RPi settings to Readme Samer El-Haj-Mahmoud
2020-06-15 21:43 ` [edk2-platform][PATCH v2 1/2] Platforms/RaspberryPi: Add RPi4 " Samer El-Haj-Mahmoud
2020-06-16 8:13 ` Pete Batard
2020-06-15 21:43 ` [edk2-platform][PATCH v2 2/2] Platforms/RaspberryPi: Add RPi3 " Samer El-Haj-Mahmoud
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox