From: Markus Armbruster <address@hidden>
The default backend is only used within virtio_rng_device_realize().
Replace VirtIORNGConf member default_backend by a local variable.
Adjust its type to reduce conversions.
While there, pass &error_abort instead of NULL when failure would be a
programming error.
Signed-off-by: Markus Armbruster <address@hidden>
Signed-off-by: Laurent Vivier <address@hidden>
---
hw/virtio/virtio-rng.c | 20 +++++++++-----------
include/hw/virtio/virtio-rng.h | 2 --
2 files changed, 9 insertions(+), 13 deletions(-)
diff --git a/hw/virtio/virtio-rng.c b/hw/virtio/virtio-rng.c
index 30493a258622..73ffb476e030 100644
--- a/hw/virtio/virtio-rng.c
+++ b/hw/virtio/virtio-rng.c
@@ -16,6 +16,7 @@
#include "hw/virtio/virtio.h"
#include "hw/virtio/virtio-rng.h"
#include "sysemu/rng.h"
+#include "sysemu/rng-random.h"