mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 07:13:54 -06:00
blockdev: Rename drive_init(), drive_uninit() to drive_new(), drive_del()
"Init" and "uninit" suggest the functions don't allocate / free storage. But they do. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Benoit Canet <benoit@irqsave.net> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
bcf8315857
commit
60e19e06a4
5 changed files with 13 additions and 13 deletions
4
vl.c
4
vl.c
|
@ -1074,7 +1074,7 @@ static int drive_init_func(QemuOpts *opts, void *opaque)
|
|||
{
|
||||
BlockInterfaceType *block_default_type = opaque;
|
||||
|
||||
return drive_init(opts, *block_default_type) == NULL;
|
||||
return drive_new(opts, *block_default_type) == NULL;
|
||||
}
|
||||
|
||||
static int drive_enable_snapshot(QemuOpts *opts, void *opaque)
|
||||
|
@ -1098,7 +1098,7 @@ static void default_drive(int enable, int snapshot, BlockInterfaceType type,
|
|||
if (snapshot) {
|
||||
drive_enable_snapshot(opts, NULL);
|
||||
}
|
||||
if (!drive_init(opts, type)) {
|
||||
if (!drive_new(opts, type)) {
|
||||
exit(1);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue