]> git.proxmox.com Git - mirror_qemu.git/commit - chardev/char.c
chardev: add Chardev.gcontext field
authorPeter Xu <peterx@redhat.com>
Thu, 21 Sep 2017 06:35:52 +0000 (14:35 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 22 Sep 2017 19:07:27 +0000 (21:07 +0200)
commit95eeeba669dca94492d708b2893f296839652c84
tree0ec11df27cba0c98c5d3a37172e1f069b2bae12f
parent07241c205c2c0b3e5e17e883c8ae523e90d172c2
chardev: add Chardev.gcontext field

It caches the gcontext that is used to poll the chardev IO.  Before this
patch, we only passed it in via chr_update_read_handlers().  However
that may not be enough if the char backend is disconnected and
reconnected afterward.  There are chardev codes that still assumed the
context be NULL (which is the main context).  Will fix that up in
following up patches.

Signed-off-by: Peter Xu <peterx@redhat.com>
Message-Id: <1505975754-21555-3-git-send-email-peterx@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
chardev/char.c
include/chardev/char.h