Oops: spice configured but not active
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
QEMU |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
with latest qemu-kvm from git i have following problem:
/usr/bin/kvm -daemonize -smp 4 -cpu host -vga qxl -enable-kvm -m 4096 -localtime -drive file=/home/
qemu-system-x86_64: Oops: spice configured but not active
Seems commit ad1be89948f88e8 9708b04ccd78245 6ccec3a6f0 from qemu needs to go in to qemu-kvm.
Could you try that and report if it fixes the issue for you?
commit ad1be89948f88e8 9708b04ccd78245 6ccec3a6f0
Author: Alon Levy <email address hidden>
Date: Wed Mar 14 20:33:37 2012 +0200
spice: fix broken initialization
Commit 1b71f7c14fab6f0 0c2680d4489fbee 7baf796e4f moved MODULE_INIT_QOM to INIT_MACHINE, thereby breaking assumptions made in
way before MODULE_
spice-core.c which registered both a type initializer and a machine
intializer.
This fix removes the type registration, and replaces it with calling
qemu_spice_init in vl.c after command line parsing (second pass) is
done, and after timers are armed, required by spice server.
Signed-off-by: Alon Levy <email address hidden>
Signed-off-by: Gerd Hoffmann <email address hidden>
diff --git a/ui/spice-core.c b/ui/spice-core.c init(void)
index 80535b6..a468524 100644
--- a/ui/spice-core.c
+++ b/ui/spice-core.c
@@ -554,7 +554,7 @@ void qemu_spice_
qemu_ thread_ get_self( &me);
- if (!opts) { get_number( opts, "port", 0); config( void) add_opts( &qemu_spice_ opts); init(spice_ register_ config) ; types(void) spice_register_ types)
+ if (!opts) {
return;
}
port = qemu_opt_
@@ -787,10 +787,3 @@ static void spice_register_
qemu_
}
machine_
-
-static void spice_register_
-{
- qemu_spice_init();
-}
-
-type_init(
diff --git a/vl.c b/vl.c
index bd95539..eeb634b 100644
--- a/vl.c
+++ b/vl.c
@@ -3369,6 +3369,11 @@ int main(int argc, char **argv, char **envp)
exit(1);
}
+#ifdef CONFIG_SPICE
fprintf( stderr, "-icount is not allowed with kvm or xen\n");
+ /* spice needs the timers to be initialized by this point */
+ qemu_spice_init();
+#endif
+
if (icount_option && (kvm_enabled() || xen_enabled())) {
exit(1);