From 2ed7e62034fbdf9eac2d8ab9c97ce2187df1ad51 Mon Sep 17 00:00:00 2001 From: Marcelo Tosatti Date: Tue, 11 Mar 2008 17:12:01 -0300 Subject: [PATCH] Move drives_opt for external use Device hotplug will use that structure from a separate file. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity --- sysemu.h | 9 +++++++++ vl.c | 6 +----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/sysemu.h b/sysemu.h index e845abbdf0..9a5c17a6f6 100644 --- a/sysemu.h +++ b/sysemu.h @@ -157,6 +157,15 @@ extern int drive_get_max_bus(BlockInterfaceType type); extern void drive_uninit(BlockDriverState *bdrv); extern void drive_remove(int index); +struct drive_opt { + const char *file; + char opt[1024]; + int used; +}; + +extern struct drive_opt drives_opt[MAX_DRIVES]; +extern int nb_drives_opt; + /* acpi */ void qemu_system_cpu_hot_add(int cpu, int state); void qemu_system_hot_add_init(char *cpu_model); diff --git a/vl.c b/vl.c index 637c37f6ee..f5d26a0696 100644 --- a/vl.c +++ b/vl.c @@ -251,11 +251,7 @@ unsigned int nb_prom_envs = 0; const char *prom_envs[MAX_PROM_ENVS]; #endif int nb_drives_opt; -struct drive_opt { - const char *file; - char opt[1024]; - int used; -} drives_opt[MAX_DRIVES]; +struct drive_opt drives_opt[MAX_DRIVES]; static CPUState *cur_cpu; static CPUState *next_cpu; -- 2.11.4.GIT