diff options
| author | Paolo Bonzini <pbonzini@redhat.com> | 2024-05-09 19:00:37 +0200 |
|---|---|---|
| committer | Paolo Bonzini <pbonzini@redhat.com> | 2024-05-10 15:45:15 +0200 |
| commit | 0973996fe47bfca8f0bf552728e36682d642c9cc (patch) | |
| tree | 61be2ed1097e6349790d89a444936bd30d854a4a /hw/xen/xen-bus.c | |
| parent | fa5365e8b6eff888e99f31cd65afefd3643e5d0e (diff) | |
| download | focaccia-qemu-0973996fe47bfca8f0bf552728e36682d642c9cc.tar.gz focaccia-qemu-0973996fe47bfca8f0bf552728e36682d642c9cc.zip | |
xen: initialize legacy backends from xen_bus_init()
Prepare for moving the calls to xen_be_register() under the control of xen_bus_init(), using the normal xen_backend_init() method that is used by the "modern" backends. This requires the xenstore global variable to be initialized, which is done by xen_be_init(). To ensure that everything is ready at the time the xen_backend_init() functions are called, remove the xen_be_init() function from all the boards and place it directly in xen_bus_init(). Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-ID: <20240509170044.190795-7-pbonzini@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/xen/xen-bus.c')
| -rw-r--r-- | hw/xen/xen-bus.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/xen/xen-bus.c b/hw/xen/xen-bus.c index fb82cc33e4..95b207ac8b 100644 --- a/hw/xen/xen-bus.c +++ b/hw/xen/xen-bus.c @@ -13,6 +13,7 @@ #include "hw/sysbus.h" #include "hw/xen/xen.h" #include "hw/xen/xen-backend.h" +#include "hw/xen/xen-legacy-backend.h" /* xen_be_init() */ #include "hw/xen/xen-bus.h" #include "hw/xen/xen-bus-helper.h" #include "monitor/monitor.h" @@ -329,6 +330,9 @@ static void xen_bus_realize(BusState *bus, Error **errp) goto fail; } + /* Initialize legacy backend core & drivers */ + xen_be_init(); + if (xs_node_scanf(xenbus->xsh, XBT_NULL, "", /* domain root node */ "domid", NULL, "%u", &domid) == 1) { xenbus->backend_id = domid; |