aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2014-10-06 10:59:55 +0100
committerPeter Maydell <peter.maydell@linaro.org>2014-10-06 10:59:56 +0100
commit507ef2f9fab3e67ac6fefda4e20db7fc5f2bc186 (patch)
tree71c2dc7fcfeb4f0b0dfba1287e191998b1375c79 /include
parentb00a0ddb31a393b8386d30a9bef4d9bbb249e7ec (diff)
parent767c86d3e752dfc68ff5d018c3b0b63b333371b2 (diff)
Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into staging
# gpg: Signature made Sat 04 Oct 2014 21:24:46 BST using RSA key ID 81AB73C8 # gpg: Good signature from "Stefan Hajnoczi <stefanha@redhat.com>" # gpg: aka "Stefan Hajnoczi <stefanha@gmail.com>" * remotes/stefanha/tags/block-pull-request: (23 commits) blockdev-test: Test device_del after drive_del blockdev-test: Factor out some common code into helpers blockdev-test: Simplify by using g_assert_cmpstr() blockdev-test: Clean up bogus drive_add argument blockdev-test: Use single rather than double quotes in QMP drive_del-test: Merge of qdev-monitor-test, blockdev-test iotests: qemu-img info output for corrupt image qapi: Add corrupt field to ImageInfoSpecificQCow2 iotests: Use _img_info util: Emancipate id_wellformed() from QemuOpts q35/ahci: Pick up -cdrom and -hda options qtest/bios-tables: Correct Q35 command line ide: Update ide_drive_get to be HBA agnostic pc/vl: Add units-per-default-bus property blockdev: Allow overriding if_max_dev property blockdev: Orphaned drive search qemu-iotests: Fix supported cache modes for 052 make check-block: Use default cache modes Modify qemu_opt_rename to realize renaming all items in opts vmdk: Fix integer overflow in offset calculation ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include')
-rw-r--r--include/hw/boards.h2
-rw-r--r--include/qemu-common.h3
-rw-r--r--include/qemu/option.h1
-rw-r--r--include/sysemu/blockdev.h5
4 files changed, 10 insertions, 1 deletions
diff --git a/include/hw/boards.h b/include/hw/boards.h
index dfb6718dc1..663f16acdd 100644
--- a/include/hw/boards.h
+++ b/include/hw/boards.h
@@ -28,6 +28,7 @@ struct QEMUMachine {
QEMUMachineHotAddCPUFunc *hot_add_cpu;
QEMUMachineGetKvmtypeFunc *kvm_type;
BlockInterfaceType block_default_type;
+ int units_per_default_bus;
int max_cpus;
unsigned int no_serial:1,
no_parallel:1,
@@ -86,6 +87,7 @@ struct MachineClass {
int (*kvm_type)(const char *arg);
BlockInterfaceType block_default_type;
+ int units_per_default_bus;
int max_cpus;
unsigned int no_serial:1,
no_parallel:1,
diff --git a/include/qemu-common.h b/include/qemu-common.h
index dcb57ab4b9..b87e9c2d8b 100644
--- a/include/qemu-common.h
+++ b/include/qemu-common.h
@@ -190,6 +190,9 @@ int64_t strtosz_suffix_unit(const char *nptr, char **end,
/* used to print char* safely */
#define STR_OR_NULL(str) ((str) ? (str) : "null")
+/* id.c */
+bool id_wellformed(const char *id);
+
/* path.c */
void init_paths(const char *prefix);
const char *path(const char *pathname);
diff --git a/include/qemu/option.h b/include/qemu/option.h
index 945347cc8f..59bea759a2 100644
--- a/include/qemu/option.h
+++ b/include/qemu/option.h
@@ -103,7 +103,6 @@ typedef int (*qemu_opt_loopfunc)(const char *name, const char *value, void *opaq
int qemu_opt_foreach(QemuOpts *opts, qemu_opt_loopfunc func, void *opaque,
int abort_on_failure);
-int qemu_opts_id_wellformed(const char *id);
QemuOpts *qemu_opts_find(QemuOptsList *list, const char *id);
QemuOpts *qemu_opts_create(QemuOptsList *list, const char *id,
int fail_if_exists, Error **errp);
diff --git a/include/sysemu/blockdev.h b/include/sysemu/blockdev.h
index abec381049..09716de809 100644
--- a/include/sysemu/blockdev.h
+++ b/include/sysemu/blockdev.h
@@ -38,6 +38,7 @@ struct DriveInfo {
int unit;
int auto_del; /* see blockdev_mark_auto_del() */
bool enable_auto_del; /* Only for legacy drive_new() */
+ bool is_default; /* Added by default_drive() ? */
int media_cd;
int cyls, heads, secs, trans;
QemuOpts *opts;
@@ -45,9 +46,13 @@ struct DriveInfo {
QTAILQ_ENTRY(DriveInfo) next;
};
+void override_max_devs(BlockInterfaceType type, int max_devs);
+
DriveInfo *drive_get(BlockInterfaceType type, int bus, int unit);
+bool drive_check_orphaned(void);
DriveInfo *drive_get_by_index(BlockInterfaceType type, int index);
int drive_get_max_bus(BlockInterfaceType type);
+int drive_get_max_devs(BlockInterfaceType type);
DriveInfo *drive_get_next(BlockInterfaceType type);
DriveInfo *drive_get_by_blockdev(BlockDriverState *bs);