summaryrefslogtreecommitdiffstats
path: root/qemu-options.hx
diff options
context:
space:
mode:
authorRichard Henderson2019-03-14 21:06:29 +0100
committerRichard Henderson2019-05-22 18:38:54 +0200
commit9c09a2518eac6277c09ee006841c94abe7305e53 (patch)
treefd63e4e66875cd1d0087b04cbfe1f8592abfcabd /qemu-options.hx
parentutil: Add qemu_guest_getrandom and associated routines (diff)
downloadqemu-9c09a2518eac6277c09ee006841c94abe7305e53.tar.gz
qemu-9c09a2518eac6277c09ee006841c94abe7305e53.tar.xz
qemu-9c09a2518eac6277c09ee006841c94abe7305e53.zip
cpus: Initialize pseudo-random seeds for all guest cpus
When the -seed option is given, call qemu_guest_random_seed_main, putting the subsystem into deterministic mode. Pass derived seeds to each cpu created; which is a no-op unless the subsystem is in deterministic mode. Reviewed-by: Laurent Vivier <lvivier@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'qemu-options.hx')
-rw-r--r--qemu-options.hx10
1 files changed, 10 insertions, 0 deletions
diff --git a/qemu-options.hx b/qemu-options.hx
index 5daa5a8fb0..7ae3373a00 100644
--- a/qemu-options.hx
+++ b/qemu-options.hx
@@ -3641,6 +3641,16 @@ the 0x200 sized block starting at 0xffffffc000080000 and another 0x1000 sized
block starting at 0xffffffc00005f000.
ETEXI
+DEF("seed", HAS_ARG, QEMU_OPTION_seed, \
+ "-seed number seed the pseudo-random number generator\n",
+ QEMU_ARCH_ALL)
+STEXI
+@item -seed @var{number}
+@findex -seed
+Force the guest to use a deterministic pseudo-random number generator, seeded
+with @var{number}. This does not affect crypto routines within the host.
+ETEXI
+
DEF("L", HAS_ARG, QEMU_OPTION_L, \
"-L path set the directory for the BIOS, VGA BIOS and keymaps\n",
QEMU_ARCH_ALL)