aboutsummaryrefslogtreecommitdiff
path: root/qemu-char.h
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2012-10-12 09:52:49 +0200
committerAurelien Jarno <aurelien@aurel32.net>2012-10-31 22:20:44 +0100
commitac4119c023c72b15f54238af43e4a178fcf41494 (patch)
tree778fcc959169ae183facf791165fe456cfc8d1ba /qemu-char.h
parent40e3acc18f1c663ee8f0c981525316f864f7b8ea (diff)
chardev: Use timer instead of bottom-half to postpone open event
As the block layer may decide to flush bottom-halfs while the machine is still initializing (e.g. to read geometry data from the disk), our postponed open event may be processed before the last frontend registered with a muxed chardev. Until the semantics of BHs have been clarified, use an expired timer to achieve the same effect (suggested by Paolo Bonzini). This requires to perform the alarm timer initialization earlier as otherwise timer subsystem can be used before being ready. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Diffstat (limited to 'qemu-char.h')
-rw-r--r--qemu-char.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/qemu-char.h b/qemu-char.h
index 486644b3bd..297dd98342 100644
--- a/qemu-char.h
+++ b/qemu-char.h
@@ -69,7 +69,7 @@ struct CharDriverState {
void (*chr_guest_open)(struct CharDriverState *chr);
void (*chr_guest_close)(struct CharDriverState *chr);
void *opaque;
- QEMUBH *bh;
+ QEMUTimer *open_timer;
char *label;
char *filename;
int opened;