qemu_opt_get_number(opts, "throttling.bps-write", 0); cfg.buckets[THROTTLE_OPS_TOTAL].avg = qemu_opt_get_number(opts, "throttling.iops-total", 0); cfg.buckets[THROTTLE_OPS_READ].avg = qemu_opt_get_number(opts, "throttling.iops-read", 0); ...
int fd_in = qemu_opt_get_number(opts, "fdin",-1); int fd_out = qemu_opt_get_number(opts, "fdout",-1); if (fd_in < 0 || fd_out < 0) return NULL; return qemu_chr_open_fd(fd_in, fd_out); } #endif /* CONFIG_ANDROID */ /* for STDIO, we handle the cas...
s->timeout = qemu_opt_get_number(opts, CURL_BLOCK_OPT_TIMEOUT, CURL_BLOCK_OPT_TIMEOUT_DEFAULT); if (s->timeout > CURL_TIMEOUT_MAX) { error_setg(errp, "timeout parameter is too large or negative"); goto out_noclean; }s->sslverify = qemu_opt_get_bool(opts, CURL_BLOCK_OPT_...
static QemuOptsList qemu_mem_opts = { .name = "memory", .implied_opt_name = "size", .head = QTAILQ_HEAD_INITIALIZER(qemu_mem_opts.head), .merge_lists = true, .desc = { { .name = "size", .type = QEMU_OPT_SIZE, }, { .name = "slots", .type = QEMU_OPT_NUMBER, }, { ...
if (chr && qemu_opt_get_bool(opts,"mux", 0)) { monitor_init(chr,MONITOR_USE_READLINE); } qemu_opts_del(opts); return chr; } qemu_chr_new_from_opts ==》 for(i = 0; i < ARRAY_SIZE(backend_table); i++) { if (strcmp(backend_table[i].name,qemu_opt_get(opts, "backend")...
by commas in getsubopt(3) style. Additionally it is possible to provide the -E and -U options multiple times. The following lines are equivalent: -E var1=val2 -E var2=val2 -U LD_PRELOAD -U LD_DEBUG -E var1=val2,var2=val2 -U LD_PRELOAD,LD_DEBUG QEMU_SET_ENV=var1=...
name = qemu_opt_get(opts, "name"); file = qemu_opt_get(opts, "file"); str = qemu_opt_get(opts, "string"); /* we need name and either a file or the content string */ /* 这个 if 表达的逻辑是,当 name 不为空的时候,那么此 name 必定要对应一个 file 或 string ...
by commasingetsubopt(3) style. Additionally itispossibletoprovide the -Eand-U options multiple times. The following lines are equivalent: -E var1=val2 -E var2=val2 -U LD_PRELOAD -U LD_DEBUG -E var1=val2,var2=val2 -U LD_PRELOAD,LD_DEBUG ...
machine_opts = qemu_get_machine_opts();if(qemu_opt_foreach(machine_opts, object_set_property, current_machine,1) <0) { object_unref(OBJECT(current_machine));exit(1); } 初始化虚拟化加速器configure_accelerator。这里的作用其实就是配置一些qemu与hypervisor层的交互接口。qemu通过一些句柄以ioctl的方...
by commasingetsubopt(3)style.Additionally it is possible to provide the-Eand-Uoptions multiple times.The following lines are equivalent:-Evar1=val2-Evar2=val2-ULD_PRELOAD-ULD_DEBUG-Evar1=val2,var2=val2-ULD_PRELOAD,LD_DEBUGQEMU_SET_ENV=var1=val2,var2=val2QEMU_UNSET_ENV=LD_PRELOAD,...