On 9/13/23 18:28, Andrew Jones wrote:
> On Wed, Sep 13, 2023 at 12:55:49PM +0200, Laszlo Ersek wrote:
>> Riscv64 KVM services SBI calls internally, so OpenSBI is not used in such
>> setups. Restrict the "-bios" flag accordingly. Thanks: Andrei, Drew.
>>
>> Cc: Andrei Warkentin <andrei.warken...@intel.com>
>> Cc: Andrew Jones <ajo...@ventanamicro.com>
>> Cc: Ard Biesheuvel <ardb+tianoc...@kernel.org>
>> Cc: Gerd Hoffmann <kra...@redhat.com>
>> Cc: Jiewen Yao <jiewen....@intel.com>
>> Cc: Jordan Justen <jordan.l.jus...@intel.com>
>> Cc: Sunil V L <suni...@ventanamicro.com>
>> Signed-off-by: Laszlo Ersek <ler...@redhat.com>
>> ---
>>  OvmfPkg/RiscVVirt/README.md | 5 +++++
>>  1 file changed, 5 insertions(+)
>>
>> diff --git a/OvmfPkg/RiscVVirt/README.md b/OvmfPkg/RiscVVirt/README.md
>> index dbb40bbe89b0..193e4afe8dee 100644
>> --- a/OvmfPkg/RiscVVirt/README.md
>> +++ b/OvmfPkg/RiscVVirt/README.md
>> @@ -86,3 +86,8 @@ then specify that binary for QEMU, with the following 
>> additional command line
>>  option:
>>  
>>      -bios $OPENSBI_DIR/build/platform/generic/firmware/fw_dynamic.bin
>> +
>> +Note that the above only makes a difference with software emulation (which 
>> you
>> +can force with `-M accel=tcg`). With hardware virtualization (`-M 
>> accel=kvm`),
>> +KVM services the SBI (Supervisor Binary Interface) calls internally, 
>> therefore
>> +any externally loaded OpenSBI binary is ignored.
>>
> 
> With the 'virt' machine model -bios is actually forbidden with accel=kvm,
> not just ignored.

Thanks, I think I should then say:

  therefore any OpenSBI binary specified with `-bios` is rejected

(I think I can still technically merge this series myself on github,
once it's been reviewed, so I could fix this up, to keep the churn low
for the maintainers.)

Unfortunately, I can't test KVM here; got no riscv64 hardware. (And I'm
not really considering nesting KVM under TCG! :) Even if TCG emulated
the virtualization extensions (?), the speed would probably be unbearable.)

> 
> Otherwise,
> 
> Reviewed-by: Andrew Jones <ajo...@ventanamicro.com>
> 
> Thanks,
> drew
> 

Thanks!
Laszlo



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#108641): https://edk2.groups.io/g/devel/message/108641
Mute This Topic: https://groups.io/mt/101334264/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: 
https://edk2.groups.io/g/devel/leave/9847357/21656/1706620634/xyzzy 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to