[edk2-devel] [PATCH edk2-platforms 1/2] Platform/ARM/JunoPkg: Bump the FV size to 2MB

Rebecca Cran posted 2 patches 2 years, 10 months ago
[edk2-devel] [PATCH edk2-platforms 1/2] Platform/ARM/JunoPkg: Bump the FV size to 2MB
Posted by Rebecca Cran 2 years, 10 months ago
Increase the FV size from 996KB to 2MB. This allows more features to be
accommodated in the firmware image, such as HTTPS boot. It also allows a
NOOPT build to be added, which is useful for source-level debugging.

Add a comment explaining that the size chosen doesn't reflect the actual
size of the Flash Device but is instead selected to reduce the amount of
time needed to copy the image to the target.

Update the BlockSize and NumBlocks to reflect the 256KB block size of
the main area on the Juno R2.

Signed-off-by: Rebecca Cran <rebecca@bsdio.com>
---
 Platform/ARM/JunoPkg/ArmJuno.fdf | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/Platform/ARM/JunoPkg/ArmJuno.fdf b/Platform/ARM/JunoPkg/ArmJuno.fdf
index 836d3cde8781..0c5a50e968e1 100644
--- a/Platform/ARM/JunoPkg/ArmJuno.fdf
+++ b/Platform/ARM/JunoPkg/ArmJuno.fdf
@@ -18,14 +18,21 @@
 #
 ################################################################################
 
+# The Size value is rather arbitrary, and doesn't reflect the actual size of the FLASH Device,
+# but is instead chosen to accommodate a normal build while reducing the amount of time required
+# to copy the image to the target.
+#
+# Juno R2 has a 64MB NOR flash split into 2 areas: the main area is 65280KB (0x3FC0000) with
+# a 256KB block size.
+
 [FD.BL33_AP_UEFI]
 BaseAddress   = 0xE0000000|gArmTokenSpaceGuid.PcdFdBaseAddress  # The base address of the Firmware in NOR Flash.
-Size          = 0x000F9000|gArmTokenSpaceGuid.PcdFdSize         # The size in bytes of the FLASH Device
+Size          = 0x00200000|gArmTokenSpaceGuid.PcdFdSize         # The size in bytes of the FLASH Device
 ErasePolarity = 1
 
 # This one is tricky, it must be: BlockSize * NumBlocks = Size
-BlockSize     = 0x00001000
-NumBlocks     = 0xF9
+BlockSize     = 0x00040000
+NumBlocks     = 0x0008
 
 ################################################################################
 #
@@ -43,7 +50,7 @@ [FD.BL33_AP_UEFI]
 #
 ################################################################################
 
-0x00000000|0x000F9000
+0x00000000|0x00200000
 gArmTokenSpaceGuid.PcdFvBaseAddress|gArmTokenSpaceGuid.PcdFvSize
 FV = FVMAIN_COMPACT
 
-- 
2.34.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#102833): https://edk2.groups.io/g/devel/message/102833
Mute This Topic: https://groups.io/mt/98197684/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-