[U-Boot] [PATCH v2 07/11] sandbox: Map host memory for efi_loader

Alexander Graf agraf at suse.de
Thu Jun 14 19:15:14 UTC 2018



On 14.06.18 21:02, Simon Glass wrote:
> Hi Alex,
> 
> On 14 June 2018 at 12:22, Alexander Graf <agraf at suse.de> wrote:
>> With efi_loader we do not control payload applications, so we can not
>> teach them about the difference between virtual and physical addresses.
>>
>> Instead, let's just always map host virtual addresses in the efi memory
>> map. That way we can be sure that all memory allocation functions always
>> return consumable pointers.
>>
>> Signed-off-by: Alexander Graf <agraf at suse.de>
>>
>> ---
>>
>> v1 -> v2:
>>
>>   - only compile efi_add_known_memory if efi_loader is enabled
>> ---
>>  arch/sandbox/cpu/cpu.c | 20 ++++++++++++++++++++
>>  1 file changed, 20 insertions(+)
> 
> NAK.
> 
> You should not point sandbox pointers into the EFI tables. I know it
> looks like a clever shortcut, but it is not correct. It will mess up
> logging and debugging, since those pointers bear no easily accessible
> relationship to U-Boot address.
> 
> Please start from my v7 patch. I'm happy to help do this correctly.
> But, again, I think it should come after we have basic sandbox EFI
> support applied.

I don't want to play ping pong with you here. NAK on your approach until
I see it properly executing selftest.

So either we drive this forward or we don't. Your choice.


Alex


More information about the U-Boot mailing list