diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2009-05-09 17:03:42 -0500 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-05-14 16:13:41 -0500 |
commit | 5efa9d5a8b18841c9c62208a494d7f519238979a (patch) | |
tree | c3d65b0b6bd54ca614e4e7e4b8eb295117ba9d78 /block-qcow.c | |
parent | 0bfe3ca51ebddbf2cc099fa34f359bd1ac4f65e6 (diff) |
Convert block infrastructure to use new module init functionality
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'block-qcow.c')
-rw-r--r-- | block-qcow.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/block-qcow.c b/block-qcow.c index fc6b809715..1cf7c3be77 100644 --- a/block-qcow.c +++ b/block-qcow.c @@ -23,6 +23,7 @@ */ #include "qemu-common.h" #include "block_int.h" +#include "module.h" #include <zlib.h> #include "aes.h" @@ -917,7 +918,7 @@ static int qcow_get_info(BlockDriverState *bs, BlockDriverInfo *bdi) return 0; } -BlockDriver bdrv_qcow = { +static BlockDriver bdrv_qcow = { .format_name = "qcow", .instance_size = sizeof(BDRVQcowState), .bdrv_probe = qcow_probe, @@ -935,3 +936,10 @@ BlockDriver bdrv_qcow = { .bdrv_write_compressed = qcow_write_compressed, .bdrv_get_info = qcow_get_info, }; + +static void bdrv_qcow_init(void) +{ + bdrv_register(&bdrv_qcow); +} + +block_init(bdrv_qcow_init); |