#include "qemu/osdep.h"
#include "block/throttle-groups.h"
+#include "qemu/module.h"
#include "qemu/option.h"
#include "qemu/throttle-options.h"
#include "qapi/error.h"
ThrottleGroupMember *tgm = bs->opaque;
throttle_group_co_io_limits_intercept(tgm, bytes, true);
- return bdrv_co_pdiscard(bs->file->bs, offset, bytes);
+ return bdrv_co_pdiscard(bs->file, offset, bytes);
}
static int throttle_co_flush(BlockDriverState *bs)
atomic_dec(&tgm->io_limits_disabled);
}
+static const char *const throttle_strong_runtime_opts[] = {
+ QEMU_OPT_THROTTLE_GROUP_NAME,
+
+ NULL
+};
+
static BlockDriver bdrv_throttle = {
.format_name = "throttle",
.instance_size = sizeof(ThrottleGroupMember),
.bdrv_co_drain_end = throttle_co_drain_end,
.is_filter = true,
+ .strong_runtime_opts = throttle_strong_runtime_opts,
};
static void bdrv_throttle_init(void)