mirror of
https://github.com/mii443/qemu.git
synced 2025-09-01 14:49:23 +00:00
qemu-char: add create to register_char_driver
Having creation as a member of the CharDriver struct removes the need to export functions for qemu-char.c's usage. After the conversion, chardev backends implemented outside qemu-char.c will not need a stub creation function anymore. Ultimately all drivers will be converted. For now, support the case where cd->create == NULL. Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
@ -125,7 +125,8 @@ CharDriverState *chr_testdev_init(void)
|
||||
|
||||
static void register_types(void)
|
||||
{
|
||||
register_char_driver("testdev", CHARDEV_BACKEND_KIND_TESTDEV, NULL);
|
||||
register_char_driver("testdev", CHARDEV_BACKEND_KIND_TESTDEV, NULL,
|
||||
NULL);
|
||||
}
|
||||
|
||||
type_init(register_types);
|
||||
|
Reference in New Issue
Block a user