diff options
Diffstat (limited to 'block.c')
-rw-r--r-- | block.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -470,6 +470,15 @@ BlockDriverState *bdrv_find(const char *name) return NULL; } +void bdrv_iterate(void (*it)(void *opaque, const char *name), void *opaque) +{ + BlockDriverState *bs; + + for (bs = bdrv_first; bs != NULL; bs = bs->next) { + it(opaque, bs->device_name); + } +} + void bdrv_info(void) { BlockDriverState *bs; |