OSDN Git Service

char: forbid direct chardevice access for hotswap devices
authorAnton Nefedov <anton.nefedov@virtuozzo.com>
Thu, 6 Jul 2017 12:08:51 +0000 (15:08 +0300)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 14 Jul 2017 09:04:33 +0000 (11:04 +0200)
commit7c44a2a9d178118193febd71cfc6943dd21bdde9
tree2206791e4494c36a2f70d3a020001910b9a79a9f
parent7bb86085e61befc95551055e26645cb23c3f0b86
char: forbid direct chardevice access for hotswap devices

qemu_chr_fe_get_driver() is unsafe, frontends with hotswap support
should not access CharDriver ptr directly as CharDriver might change.

Signed-off-by: Anton Nefedov <anton.nefedov@virtuozzo.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <1499342940-56739-5-git-send-email-anton.nefedov@virtuozzo.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
chardev/char-fe.c
include/chardev/char-fe.h