]> rtime.felk.cvut.cz Git - lisovros/qemu_apohw.git/commit
qemu-char: ignore flow control if a PTY's slave is not connected
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 24 Jul 2014 14:08:04 +0000 (16:08 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 25 Jul 2014 12:36:07 +0000 (14:36 +0200)
commit62c339c5272ce8fbe8ca52695cee8ff40da7872e
tree9dfd84d9511a075a65e2969e286d0bfd7b9e70e4
parentf368c33d5ab09dd5656924185cd975b11838cd25
qemu-char: ignore flow control if a PTY's slave is not connected

After commit f702e62 (serial: change retry logic to avoid concurrency,
2014-07-11), guest boot hangs if the backend is an unconnected PTY.

The reason is that PTYs do not support G_IO_HUP, and serial_xmit is
never called.  To fix this, simply invoke serial_xmit immediately
(via g_idle_source_new) when this happens.

Tested-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
qemu-char.c