BDRVVmdkState *s = bs->opaque;
VmdkExtent *e;
- bdrv_graph_wrlock(NULL);
+ bdrv_graph_wrlock();
for (i = 0; i < s->num_extents; i++) {
e = &s->extents[i];
g_free(e->l1_table);
bdrv_unref_child(bs, e->file);
}
}
- bdrv_graph_wrunlock(NULL);
+ bdrv_graph_wrunlock();
g_free(s->extents);
}
0, 0, 0, 0, 0, &extent, errp);
if (ret < 0) {
bdrv_graph_rdunlock_main_loop();
- bdrv_graph_wrlock(NULL);
+ bdrv_graph_wrlock();
bdrv_unref_child(bs, extent_file);
- bdrv_graph_wrunlock(NULL);
+ bdrv_graph_wrunlock();
bdrv_graph_rdlock_main_loop();
goto out;
}
g_free(buf);
if (ret) {
bdrv_graph_rdunlock_main_loop();
- bdrv_graph_wrlock(NULL);
+ bdrv_graph_wrlock();
bdrv_unref_child(bs, extent_file);
- bdrv_graph_wrunlock(NULL);
+ bdrv_graph_wrunlock();
bdrv_graph_rdlock_main_loop();
goto out;
}
ret = vmdk_open_se_sparse(bs, extent_file, bs->open_flags, errp);
if (ret) {
bdrv_graph_rdunlock_main_loop();
- bdrv_graph_wrlock(NULL);
+ bdrv_graph_wrlock();
bdrv_unref_child(bs, extent_file);
- bdrv_graph_wrunlock(NULL);
+ bdrv_graph_wrunlock();
bdrv_graph_rdlock_main_loop();
goto out;
}
} else {
error_setg(errp, "Unsupported extent type '%s'", type);
bdrv_graph_rdunlock_main_loop();
- bdrv_graph_wrlock(NULL);
+ bdrv_graph_wrlock();
bdrv_unref_child(bs, extent_file);
- bdrv_graph_wrunlock(NULL);
+ bdrv_graph_wrunlock();
bdrv_graph_rdlock_main_loop();
ret = -ENOTSUP;
goto out;