aboutsummaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2016-03-24 21:42:12 +0000
committerPeter Maydell <peter.maydell@linaro.org>2016-03-24 21:42:40 +0000
commit84a5a8014801a83d1b8d15fa7f0fde03db081530 (patch)
tree9b7090464e9b910d6e083f44ed54e9afe85b7ff2 /block
parentb68a80139e37e806f004237e55311ebc42151434 (diff)
parent0f70ed4759a29ca932af1e9525729f4f455642f8 (diff)
Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging
* Log filtering from Alex and Peter * Chardev fix from Marc-André * config.status tweak from David * Header file tweaks from Markus, myself and Veronia (Outreachy candidate) * get_ticks_per_sec() removal from Rutuja (Outreachy candidate) * Coverity fix from myself * PKE implementation from myself, based on rth's XSAVE support # gpg: Signature made Thu 24 Mar 2016 20:15:11 GMT using RSA key ID 78C7AE83 # gpg: Good signature from "Paolo Bonzini <bonzini@gnu.org>" # gpg: aka "Paolo Bonzini <pbonzini@redhat.com>" * remotes/bonzini/tags/for-upstream: (28 commits) target-i386: implement PKE for TCG config.status: Pass extra parameters char: translate from QIOChannel error to errno exec: fix error handling in file_ram_alloc cputlb: modernise the debug support qemu-log: support simple pid substitution for logs target-arm: dfilter support for in_asm qemu-log: dfilter-ise exec, out_asm, op and opt_op qemu-log: new option -dfilter to limit output qemu-log: Improve the "exec" TB execution logging qemu-log: Avoid function call for disabled qemu_log_mask logging qemu-log: correct help text for -d cpu tcg: pass down TranslationBlock to tcg_code_gen util: move declarations out of qemu-common.h Replaced get_tick_per_sec() by NANOSECONDS_PER_SECOND hw: explicitly include qemu-common.h and cpu.h include/crypto: Include qapi-types.h or qemu/bswap.h instead of qemu-common.h isa: Move DMA_transfer_handler from qemu-common.h to hw/isa/isa.h Move ParallelIOArg from qemu-common.h to sysemu/char.h Move QEMU_ALIGN_*() from qemu-common.h to qemu/osdep.h ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Conflicts: scripts/clean-includes
Diffstat (limited to 'block')
-rw-r--r--block/archipelago.c2
-rw-r--r--block/backup.c2
-rw-r--r--block/blkdebug.c3
-rw-r--r--block/blkverify.c2
-rw-r--r--block/block-backend.c1
-rw-r--r--block/bochs.c1
-rw-r--r--block/cloop.c1
-rw-r--r--block/commit.c1
-rw-r--r--block/curl.c2
-rw-r--r--block/dirty-bitmap.c2
-rw-r--r--block/dmg.c1
-rw-r--r--block/gluster.c1
-rw-r--r--block/io.c2
-rw-r--r--block/mirror.c1
-rw-r--r--block/nbd.c3
-rw-r--r--block/null.c1
-rw-r--r--block/parallels.c1
-rw-r--r--block/qapi.c1
-rw-r--r--block/qcow.c1
-rw-r--r--block/qcow2-cluster.c1
-rw-r--r--block/qcow2-refcount.c1
-rw-r--r--block/qcow2-snapshot.c3
-rw-r--r--block/qcow2.c2
-rw-r--r--block/qed.c3
-rw-r--r--block/qed.h1
-rw-r--r--block/raw-aio.h2
-rw-r--r--block/raw-posix.c3
-rw-r--r--block/raw-win32.c3
-rw-r--r--block/raw_bsd.c1
-rw-r--r--block/rbd.c3
-rw-r--r--block/sheepdog.c3
-rw-r--r--block/snapshot.c1
-rw-r--r--block/ssh.c1
-rw-r--r--block/stream.c1
-rw-r--r--block/vdi.c3
-rw-r--r--block/vhdx-log.c1
-rw-r--r--block/vhdx.c1
-rw-r--r--block/vmdk.c3
-rw-r--r--block/vpc.c1
-rw-r--r--block/vvfat.c3
40 files changed, 56 insertions, 14 deletions
diff --git a/block/archipelago.c b/block/archipelago.c
index 0507589063..b9f5e69d4a 100644
--- a/block/archipelago.c
+++ b/block/archipelago.c
@@ -51,7 +51,7 @@
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qemu/cutils.h"
#include "block/block_int.h"
#include "qemu/error-report.h"
#include "qemu/thread.h"
diff --git a/block/backup.c b/block/backup.c
index ab3e345e92..9170983ba9 100644
--- a/block/backup.c
+++ b/block/backup.c
@@ -17,8 +17,10 @@
#include "block/block.h"
#include "block/block_int.h"
#include "block/blockjob.h"
+#include "qapi/error.h"
#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
+#include "qemu/cutils.h"
#include "sysemu/block-backend.h"
#include "qemu/bitmap.h"
diff --git a/block/blkdebug.c b/block/blkdebug.c
index f85c54bdc8..20d25bda67 100644
--- a/block/blkdebug.c
+++ b/block/blkdebug.c
@@ -23,7 +23,8 @@
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
+#include "qemu/cutils.h"
#include "qemu/config-file.h"
#include "block/block_int.h"
#include "qemu/module.h"
diff --git a/block/blkverify.c b/block/blkverify.c
index 2a885cc08d..9414b7a84e 100644
--- a/block/blkverify.c
+++ b/block/blkverify.c
@@ -8,10 +8,12 @@
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu/sockets.h" /* for EINPROGRESS on Windows */
#include "block/block_int.h"
#include "qapi/qmp/qdict.h"
#include "qapi/qmp/qstring.h"
+#include "qemu/cutils.h"
typedef struct {
BdrvChild *test_file;
diff --git a/block/block-backend.c b/block/block-backend.c
index dca21d1eeb..adf592e867 100644
--- a/block/block-backend.c
+++ b/block/block-backend.c
@@ -18,6 +18,7 @@
#include "sysemu/blockdev.h"
#include "sysemu/sysemu.h"
#include "qapi-event.h"
+#include "qemu/id.h"
/* Number of coroutines to reserve per attached device model */
#define COROUTINE_POOL_RESERVATION 64
diff --git a/block/bochs.c b/block/bochs.c
index 8b953bb44c..af8b7abdfd 100644
--- a/block/bochs.c
+++ b/block/bochs.c
@@ -23,6 +23,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "qemu/module.h"
diff --git a/block/cloop.c b/block/cloop.c
index 41bdee8d7f..a84f14019c 100644
--- a/block/cloop.c
+++ b/block/cloop.c
@@ -22,6 +22,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "qemu/module.h"
diff --git a/block/commit.c b/block/commit.c
index 446a3aeadd..cba0e8c1e8 100644
--- a/block/commit.c
+++ b/block/commit.c
@@ -16,6 +16,7 @@
#include "trace.h"
#include "block/block_int.h"
#include "block/blockjob.h"
+#include "qapi/error.h"
#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
#include "sysemu/block-backend.h"
diff --git a/block/curl.c b/block/curl.c
index c70bfb404d..5a8f8b6239 100644
--- a/block/curl.c
+++ b/block/curl.c
@@ -22,6 +22,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "qemu/error-report.h"
#include "block/block_int.h"
@@ -29,6 +30,7 @@
#include "qapi/qmp/qstring.h"
#include "crypto/secret.h"
#include <curl/curl.h>
+#include "qemu/cutils.h"
// #define DEBUG_CURL
// #define DEBUG_VERBOSE
diff --git a/block/dirty-bitmap.c b/block/dirty-bitmap.c
index 556e1d15c4..4902ca557f 100644
--- a/block/dirty-bitmap.c
+++ b/block/dirty-bitmap.c
@@ -22,7 +22,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
-#include "config-host.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "trace.h"
#include "block/block_int.h"
diff --git a/block/dmg.c b/block/dmg.c
index 1018fd158e..a496eb7c9b 100644
--- a/block/dmg.c
+++ b/block/dmg.c
@@ -22,6 +22,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "qemu/bswap.h"
diff --git a/block/gluster.c b/block/gluster.c
index 65077a0d0a..51e154c247 100644
--- a/block/gluster.c
+++ b/block/gluster.c
@@ -10,6 +10,7 @@
#include "qemu/osdep.h"
#include <glusterfs/api/glfs.h>
#include "block/block_int.h"
+#include "qapi/error.h"
#include "qemu/uri.h"
typedef struct GlusterAIOCB {
diff --git a/block/io.c b/block/io.c
index 41d954cad2..c2611e53c8 100644
--- a/block/io.c
+++ b/block/io.c
@@ -28,6 +28,8 @@
#include "block/blockjob.h"
#include "block/block_int.h"
#include "block/throttle-groups.h"
+#include "qemu/cutils.h"
+#include "qapi/error.h"
#include "qemu/error-report.h"
#define NOT_DONE 0x7fffffff /* used while emulated sync operation in progress */
diff --git a/block/mirror.c b/block/mirror.c
index 9635fa8e62..7bfd0d2996 100644
--- a/block/mirror.c
+++ b/block/mirror.c
@@ -16,6 +16,7 @@
#include "block/blockjob.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
+#include "qapi/error.h"
#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
#include "qemu/bitmap.h"
diff --git a/block/nbd.c b/block/nbd.c
index 836424c88c..896064a131 100644
--- a/block/nbd.c
+++ b/block/nbd.c
@@ -28,6 +28,7 @@
#include "qemu/osdep.h"
#include "block/nbd-client.h"
+#include "qapi/error.h"
#include "qemu/uri.h"
#include "block/block_int.h"
#include "qemu/module.h"
@@ -35,7 +36,7 @@
#include "qapi/qmp/qjson.h"
#include "qapi/qmp/qint.h"
#include "qapi/qmp/qstring.h"
-
+#include "qemu/cutils.h"
#define EN_OPTSTR ":exportname="
diff --git a/block/null.c b/block/null.c
index d90165dea7..00bc6e478a 100644
--- a/block/null.c
+++ b/block/null.c
@@ -11,6 +11,7 @@
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "block/block_int.h"
#define NULL_OPT_LATENCY "latency-ns"
diff --git a/block/parallels.c b/block/parallels.c
index b322d05c08..9bba8b3d06 100644
--- a/block/parallels.c
+++ b/block/parallels.c
@@ -28,6 +28,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
diff --git a/block/qapi.c b/block/qapi.c
index 6a4869a8d9..089614ee9d 100644
--- a/block/qapi.c
+++ b/block/qapi.c
@@ -32,6 +32,7 @@
#include "qapi/qmp-output-visitor.h"
#include "qapi/qmp/types.h"
#include "sysemu/block-backend.h"
+#include "qemu/cutils.h"
BlockDeviceInfo *bdrv_block_device_info(BlockDriverState *bs, Error **errp)
{
diff --git a/block/qcow.c b/block/qcow.c
index 73cf8a7081..8ea8e5ceef 100644
--- a/block/qcow.c
+++ b/block/qcow.c
@@ -22,6 +22,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c
index 3e887e9ab0..31ecc10304 100644
--- a/block/qcow2-cluster.c
+++ b/block/qcow2-cluster.c
@@ -25,6 +25,7 @@
#include "qemu/osdep.h"
#include <zlib.h>
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "block/qcow2.h"
diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c
index 52a0a9ffc3..ca6094ff5b 100644
--- a/block/qcow2-refcount.c
+++ b/block/qcow2-refcount.c
@@ -23,6 +23,7 @@
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "block/qcow2.h"
diff --git a/block/qcow2-snapshot.c b/block/qcow2-snapshot.c
index 13f88d1b8b..5f4a17e473 100644
--- a/block/qcow2-snapshot.c
+++ b/block/qcow2-snapshot.c
@@ -23,10 +23,11 @@
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
#include "block/block_int.h"
#include "block/qcow2.h"
#include "qemu/error-report.h"
+#include "qemu/cutils.h"
void qcow2_free_snapshots(BlockDriverState *bs)
{
diff --git a/block/qcow2.c b/block/qcow2.c
index cec5bd02f2..642802971c 100644
--- a/block/qcow2.c
+++ b/block/qcow2.c
@@ -22,7 +22,6 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
#include "qemu/module.h"
@@ -36,6 +35,7 @@
#include "qapi-event.h"
#include "trace.h"
#include "qemu/option_int.h"
+#include "qemu/cutils.h"
/*
Differences with QCOW:
diff --git a/block/qed.c b/block/qed.c
index 5b24a9783f..c1cc625d55 100644
--- a/block/qed.c
+++ b/block/qed.c
@@ -13,6 +13,7 @@
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu/timer.h"
#include "trace.h"
#include "qed.h"
@@ -346,7 +347,7 @@ static void qed_start_need_check_timer(BDRVQEDState *s)
* migration.
*/
timer_mod(s->need_check_timer, qemu_clock_get_ns(QEMU_CLOCK_VIRTUAL) +
- get_ticks_per_sec() * QED_NEED_CHECK_TIMEOUT);
+ NANOSECONDS_PER_SECOND * QED_NEED_CHECK_TIMEOUT);
}
/* It's okay to call this multiple times or when no timer is started */
diff --git a/block/qed.h b/block/qed.h
index 615e676fc8..22b3198751 100644
--- a/block/qed.h
+++ b/block/qed.h
@@ -16,6 +16,7 @@
#define BLOCK_QED_H
#include "block/block_int.h"
+#include "qemu/cutils.h"
/* The layout of a QED file is as follows:
*
diff --git a/block/raw-aio.h b/block/raw-aio.h
index 31d791fe67..811e375018 100644
--- a/block/raw-aio.h
+++ b/block/raw-aio.h
@@ -15,6 +15,8 @@
#ifndef QEMU_RAW_AIO_H
#define QEMU_RAW_AIO_H
+#include "qemu/iov.h"
+
/* AIO request types */
#define QEMU_AIO_READ 0x0001
#define QEMU_AIO_WRITE 0x0002
diff --git a/block/raw-posix.c b/block/raw-posix.c
index 8866121cf7..c8e2ec40fb 100644
--- a/block/raw-posix.c
+++ b/block/raw-posix.c
@@ -22,7 +22,8 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
+#include "qemu/cutils.h"
#include "qemu/error-report.h"
#include "qemu/timer.h"
#include "qemu/log.h"
diff --git a/block/raw-win32.c b/block/raw-win32.c
index 21a6cb89d7..fd23891534 100644
--- a/block/raw-win32.c
+++ b/block/raw-win32.c
@@ -22,7 +22,8 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
+#include "qemu/cutils.h"
#include "qemu/timer.h"
#include "block/block_int.h"
#include "qemu/module.h"
diff --git a/block/raw_bsd.c b/block/raw_bsd.c
index ea16a231c0..41dddf8db3 100644
--- a/block/raw_bsd.c
+++ b/block/raw_bsd.c
@@ -28,6 +28,7 @@
#include "qemu/osdep.h"
#include "block/block_int.h"
+#include "qapi/error.h"
#include "qemu/option.h"
static QemuOptsList raw_create_opts = {
diff --git a/block/rbd.c b/block/rbd.c
index abfea612ec..5bc5b32530 100644
--- a/block/rbd.c
+++ b/block/rbd.c
@@ -13,10 +13,11 @@
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
#include "qemu/error-report.h"
#include "block/block_int.h"
#include "crypto/secret.h"
+#include "qemu/cutils.h"
#include <rbd/librbd.h>
diff --git a/block/sheepdog.c b/block/sheepdog.c
index a3aeae4a67..48fc165422 100644
--- a/block/sheepdog.c
+++ b/block/sheepdog.c
@@ -13,13 +13,14 @@
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
#include "qemu/uri.h"
#include "qemu/error-report.h"
#include "qemu/sockets.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
#include "qemu/bitops.h"
+#include "qemu/cutils.h"
#define SD_PROTO_VER 0x01
diff --git a/block/snapshot.c b/block/snapshot.c
index 17a27b57ad..e9d721df68 100644
--- a/block/snapshot.c
+++ b/block/snapshot.c
@@ -25,6 +25,7 @@
#include "qemu/osdep.h"
#include "block/snapshot.h"
#include "block/block_int.h"
+#include "qapi/error.h"
#include "qapi/qmp/qerror.h"
QemuOptsList internal_snapshot_opts = {
diff --git a/block/ssh.c b/block/ssh.c
index 04deeba1ad..06928ed939 100644
--- a/block/ssh.c
+++ b/block/ssh.c
@@ -28,6 +28,7 @@
#include <libssh2_sftp.h>
#include "block/block_int.h"
+#include "qapi/error.h"
#include "qemu/error-report.h"
#include "qemu/sockets.h"
#include "qemu/uri.h"
diff --git a/block/stream.c b/block/stream.c
index cafaa07a01..9b0b0f3573 100644
--- a/block/stream.c
+++ b/block/stream.c
@@ -15,6 +15,7 @@
#include "trace.h"
#include "block/block_int.h"
#include "block/blockjob.h"
+#include "qapi/error.h"
#include "qapi/qmp/qerror.h"
#include "qemu/ratelimit.h"
#include "sysemu/block-backend.h"
diff --git a/block/vdi.c b/block/vdi.c
index df9fa47db1..71f417c461 100644
--- a/block/vdi.c
+++ b/block/vdi.c
@@ -50,12 +50,13 @@
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
#include "qemu/module.h"
#include "migration/migration.h"
#include "qemu/coroutine.h"
+#include "qemu/cutils.h"
#if defined(CONFIG_UUID)
#include <uuid/uuid.h>
diff --git a/block/vhdx-log.c b/block/vhdx-log.c
index 369076126e..7ea7187fc4 100644
--- a/block/vhdx-log.c
+++ b/block/vhdx-log.c
@@ -18,6 +18,7 @@
*
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "qemu/error-report.h"
diff --git a/block/vhdx.c b/block/vhdx.c
index 78fe56ca04..59426d6c0f 100644
--- a/block/vhdx.c
+++ b/block/vhdx.c
@@ -16,6 +16,7 @@
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
diff --git a/block/vmdk.c b/block/vmdk.c
index 29c8fc3d02..a1a9371bf8 100644
--- a/block/vmdk.c
+++ b/block/vmdk.c
@@ -24,13 +24,14 @@
*/
#include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qapi/error.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
#include "qapi/qmp/qerror.h"
#include "qemu/error-report.h"
#include "qemu/module.h"
#include "migration/migration.h"
+#include "qemu/cutils.h"
#include <zlib.h>
#include <glib.h>
diff --git a/block/vpc.c b/block/vpc.c
index 8435205a0c..912dfc1a82 100644
--- a/block/vpc.c
+++ b/block/vpc.c
@@ -23,6 +23,7 @@
* THE SOFTWARE.
*/
#include "qemu/osdep.h"
+#include "qapi/error.h"
#include "qemu-common.h"
#include "block/block_int.h"
#include "sysemu/block-backend.h"
diff --git a/block/vvfat.c b/block/vvfat.c
index b8d29e17cd..eb1126cbad 100644
--- a/block/vvfat.c
+++ b/block/vvfat.c
@@ -24,13 +24,14 @@
*/
#include "qemu/osdep.h"
#include <dirent.h>
-#include "qemu-common.h"
+#include "qapi/error.h"
#include "block/block_int.h"
#include "qemu/module.h"
#include "migration/migration.h"
#include "qapi/qmp/qint.h"
#include "qapi/qmp/qbool.h"
#include "qapi/qmp/qstring.h"
+#include "qemu/cutils.h"
#ifndef S_IWGRP
#define S_IWGRP 0