DxeCore will install FV protocol for PI format FV FFS image. Variable storage is not FFS format. It has no FV protocol. EDKII variable driver directly access FVB protocol to read/write variable storage. But now, EDKII variable assumes variable storage is memory map range. So, it directly reads variable storage based on PcdFlashNvStorageVariableBase instead of FVB protocol Read service.
Thanks Liming From: Narinder Dhillon [mailto:[email protected]] Sent: Wednesday, October 29, 2014 4:51 AM To: [email protected] Subject: Re: [edk2] Firmware Volume Block Protocol Hi Andrew, I have initialized the flash device with a FV header at the begining, struct below. How do I determine that FV protocol was detected on the emmc device ? Is there some handle that I should see when I use 'dh' shell command ? Thanx. typedef struct { EFI_FIRMWARE_VOLUME_HEADER FvHdr; EFI_FV_BLOCK_MAP_ENTRY EndBlockMap; VARIABLE_STORE_HEADER VarHdr; } EFI_FVB_MEDIA_HDR; On Mon, Oct 27, 2014 at 12:54 PM, Andrew Fish <[email protected]<mailto:[email protected]>> wrote: On Oct 27, 2014, at 12:11 PM, Narinder Dhillon <[email protected]<mailto:[email protected]>> wrote: Hi Liming, Yes, the patch helped and now the initialization is not stuck in a loop. When UEFI runs for the first time, eMMC flash device is blank and there will not be any information or FVB header. Would UEFI create one ? Or do I have to create a volume first before UEFI will start using it ? The assumption is it is formatted, the DXE does not attempt to format the volume. Thanks, Andrew Fish Thanx. On Mon, Oct 27, 2014 at 3:24 AM, Gao, Liming <[email protected]<mailto:[email protected]>> wrote: Hi, DxeCore has FVB notify function to call FVB protocol to check whether a FV image is there. DxeCore will read FV header, then base on header length to read the whole FV header, last check FV header. If your FV is not PI FFS format, its FV header length field is invalid that causes DxeCore wrongly read data. To avoid it, DxeCore could be enhanced to check FV header first, then read full header. Could you apply the attached patch to DxeCore module and check again? Thanks Liming From: Narinder Dhillon [mailto:[email protected]<mailto:[email protected]>] Sent: Monday, October 27, 2014 8:44 AM To: [email protected]<mailto:[email protected]> Subject: [edk2] Firmware Volume Block Protocol Hi All, I am trying to implement a non-volatile variable storage on a small part of eMMC device. I have implemented the FVB protocol and the 'Read' function is being called with increasing 'Lba' during UEFI boot. Where is the 'Read' function is being called from ? (some sort of initialization code) Why will it not stop ? The 'Read' function is being called with increasing Lba till my board hangs. FvbRead Lba:2 Offset:0, Numbytes:512 0x200 FvbRead Lba:3 Offset:0, Numbytes:512 0x200 FvbRead Lba:4 Offset:0, Numbytes:512 0x200 Thanx. ------------------------------------------------------------------------------ _______________________________________________ edk2-devel mailing list [email protected]<mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/edk2-devel ------------------------------------------------------------------------------ _______________________________________________ edk2-devel mailing list [email protected]<mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/edk2-devel ------------------------------------------------------------------------------ _______________________________________________ edk2-devel mailing list [email protected]<mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/edk2-devel
------------------------------------------------------------------------------
_______________________________________________ edk2-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/edk2-devel
