All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG
@ 2023-07-28 13:54 Heinrich Schuchardt
  2023-07-28 15:50 ` Bin Meng
  2023-07-31  6:04 ` Leo Liang
  0 siblings, 2 replies; 4+ messages in thread
From: Heinrich Schuchardt @ 2023-07-28 13:54 UTC (permalink / raw)
  To: Bin Meng; +Cc: u-boot, Heinrich Schuchardt

The EFI_RNG_PROTOCOL is needed for Linux' KASLR.

QEMU can provide a virtio-rng device to emulate a hardware random number
generator which is supported by our virtio_rng driver.

Enabling CONFIG_DM_RNG will enable CONFIG_VIRTIO_RNG and
CONFIG_EFI_RNG_PROTOCOL by default too.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
---
 board/emulation/qemu-riscv/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/board/emulation/qemu-riscv/Kconfig b/board/emulation/qemu-riscv/Kconfig
index 6114e1b812..21d6160f01 100644
--- a/board/emulation/qemu-riscv/Kconfig
+++ b/board/emulation/qemu-riscv/Kconfig
@@ -53,6 +53,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
 	imply NVME
 	imply PCI
 	imply PCIE_ECAM_GENERIC
+	imply DM_RNG
 	imply SCSI
 	imply DM_SCSI
 	imply SYS_NS16550
-- 
2.40.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG
  2023-07-28 13:54 [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG Heinrich Schuchardt
@ 2023-07-28 15:50 ` Bin Meng
  2023-07-31  6:04 ` Leo Liang
  1 sibling, 0 replies; 4+ messages in thread
From: Bin Meng @ 2023-07-28 15:50 UTC (permalink / raw)
  To: Heinrich Schuchardt; +Cc: u-boot

On Fri, Jul 28, 2023 at 9:54 PM Heinrich Schuchardt
<heinrich.schuchardt@canonical.com> wrote:
>
> The EFI_RNG_PROTOCOL is needed for Linux' KASLR.
>
> QEMU can provide a virtio-rng device to emulate a hardware random number
> generator which is supported by our virtio_rng driver.
>
> Enabling CONFIG_DM_RNG will enable CONFIG_VIRTIO_RNG and
> CONFIG_EFI_RNG_PROTOCOL by default too.
>
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
> ---
>  board/emulation/qemu-riscv/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
>

Reviewed-by: Bin Meng <bmeng.cn@gmail.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG
  2023-07-28 13:54 [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG Heinrich Schuchardt
  2023-07-28 15:50 ` Bin Meng
@ 2023-07-31  6:04 ` Leo Liang
  2023-07-31  6:37   ` Heinrich Schuchardt
  1 sibling, 1 reply; 4+ messages in thread
From: Leo Liang @ 2023-07-31  6:04 UTC (permalink / raw)
  To: Heinrich Schuchardt; +Cc: Bin Meng, u-boot

On Fri, Jul 28, 2023 at 03:54:15PM +0200, Heinrich Schuchardt wrote:
> The EFI_RNG_PROTOCOL is needed for Linux' KASLR.
> 
> QEMU can provide a virtio-rng device to emulate a hardware random number
> generator which is supported by our virtio_rng driver.
> 
> Enabling CONFIG_DM_RNG will enable CONFIG_VIRTIO_RNG and
> CONFIG_EFI_RNG_PROTOCOL by default too.
> 
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
> ---
>  board/emulation/qemu-riscv/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/board/emulation/qemu-riscv/Kconfig b/board/emulation/qemu-riscv/Kconfig
> index 6114e1b812..21d6160f01 100644
> --- a/board/emulation/qemu-riscv/Kconfig
> +++ b/board/emulation/qemu-riscv/Kconfig
> @@ -53,6 +53,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
>  	imply NVME
>  	imply PCI
>  	imply PCIE_ECAM_GENERIC
> +	imply DM_RNG
>  	imply SCSI
>  	imply DM_SCSI
>  	imply SYS_NS16550
> -- 
> 2.40.1
> 

Hi Heinrich,

This patch seems to cause CI: test/py/tests/test_efi_selftest.py to fail.
(https://source.denx.de/u-boot/custodians/u-boot-riscv/-/jobs/666642)
Could you take a look at this and check if anything else needs modification?

Best regards,
Leo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG
  2023-07-31  6:04 ` Leo Liang
@ 2023-07-31  6:37   ` Heinrich Schuchardt
  0 siblings, 0 replies; 4+ messages in thread
From: Heinrich Schuchardt @ 2023-07-31  6:37 UTC (permalink / raw)
  To: Leo Liang; +Cc: Bin Meng, u-boot



On 7/31/23 08:04, Leo Liang wrote:
> On Fri, Jul 28, 2023 at 03:54:15PM +0200, Heinrich Schuchardt wrote:
>> The EFI_RNG_PROTOCOL is needed for Linux' KASLR.
>>
>> QEMU can provide a virtio-rng device to emulate a hardware random number
>> generator which is supported by our virtio_rng driver.
>>
>> Enabling CONFIG_DM_RNG will enable CONFIG_VIRTIO_RNG and
>> CONFIG_EFI_RNG_PROTOCOL by default too.
>>
>> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
>> ---
>>   board/emulation/qemu-riscv/Kconfig | 1 +
>>   1 file changed, 1 insertion(+)
>>
>> diff --git a/board/emulation/qemu-riscv/Kconfig b/board/emulation/qemu-riscv/Kconfig
>> index 6114e1b812..21d6160f01 100644
>> --- a/board/emulation/qemu-riscv/Kconfig
>> +++ b/board/emulation/qemu-riscv/Kconfig
>> @@ -53,6 +53,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
>>   	imply NVME
>>   	imply PCI
>>   	imply PCIE_ECAM_GENERIC
>> +	imply DM_RNG
>>   	imply SCSI
>>   	imply DM_SCSI
>>   	imply SYS_NS16550
>> -- 
>> 2.40.1
>>
> 
> Hi Heinrich,
> 
> This patch seems to cause CI: test/py/tests/test_efi_selftest.py to fail.
> (https://source.denx.de/u-boot/custodians/u-boot-riscv/-/jobs/666642)
> Could you take a look at this and check if anything else needs modification?
> 
> Best regards,
> Leo

Hello Leo,

thanks for sharing the test result.

u-boot-test-hooks does not enable device virtio-rng-pci on RISC-V. I 
will adjust this.

Best regards

Heinrich

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-07-31  6:36 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-28 13:54 [PATCH 1/1] riscv: qemu: imply CONFIG_DM_RNG Heinrich Schuchardt
2023-07-28 15:50 ` Bin Meng
2023-07-31  6:04 ` Leo Liang
2023-07-31  6:37   ` Heinrich Schuchardt

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.