Explorar o código

block: Clean up includes

Clean up includes so that osdep.h is included first and headers
which it implies are not included manually.

This commit was created with scripts/clean-includes.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Peter Maydell %!s(int64=9) %!d(string=hai) anos
pai
achega
80c71a241a
Modificáronse 70 ficheiros con 70 adicións e 34 borrados
  1. 1 0
      block/accounting.c
  2. 1 1
      block/archipelago.c
  3. 1 3
      block/backup.c
  4. 1 0
      block/blkdebug.c
  5. 1 1
      block/blkverify.c
  6. 1 0
      block/block-backend.c
  7. 1 0
      block/bochs.c
  8. 1 0
      block/cloop.c
  9. 1 0
      block/commit.c
  10. 1 0
      block/curl.c
  11. 1 0
      block/dmg.c
  12. 1 0
      block/gluster.c
  13. 1 0
      block/io.c
  14. 1 1
      block/iscsi.c
  15. 1 0
      block/linux-aio.c
  16. 1 0
      block/mirror.c
  17. 1 0
      block/nbd-client.c
  18. 1 2
      block/nbd.c
  19. 1 1
      block/nfs.c
  20. 1 0
      block/null.c
  21. 1 0
      block/parallels.c
  22. 1 0
      block/qapi.c
  23. 1 0
      block/qcow.c
  24. 1 2
      block/qcow2-cache.c
  25. 1 0
      block/qcow2-cluster.c
  26. 1 0
      block/qcow2-refcount.c
  27. 1 0
      block/qcow2-snapshot.c
  28. 1 0
      block/qcow2.c
  29. 1 0
      block/qed-check.c
  30. 1 0
      block/qed-cluster.c
  31. 1 0
      block/qed-gencb.c
  32. 1 0
      block/qed-l2-cache.c
  33. 1 0
      block/qed-table.c
  34. 1 0
      block/qed.c
  35. 1 0
      block/quorum.c
  36. 1 2
      block/raw-posix.c
  37. 1 0
      block/raw-win32.c
  38. 1 0
      block/raw_bsd.c
  39. 1 1
      block/rbd.c
  40. 1 0
      block/sheepdog.c
  41. 1 0
      block/snapshot.c
  42. 1 3
      block/ssh.c
  43. 1 0
      block/stream.c
  44. 1 0
      block/throttle-groups.c
  45. 1 0
      block/vdi.c
  46. 1 0
      block/vhdx-endian.c
  47. 1 0
      block/vhdx-log.c
  48. 1 0
      block/vhdx.c
  49. 1 0
      block/vmdk.c
  50. 1 0
      block/vpc.c
  51. 1 1
      block/vvfat.c
  52. 1 0
      block/win32-aio.c
  53. 1 0
      block/write-threshold.c
  54. 1 0
      hw/block/block.c
  55. 1 0
      hw/block/cdrom.c
  56. 1 0
      hw/block/dataplane/virtio-blk.c
  57. 1 0
      hw/block/ecc.c
  58. 1 0
      hw/block/fdc.c
  59. 1 0
      hw/block/hd-geometry.c
  60. 1 0
      hw/block/m25p80.c
  61. 1 0
      hw/block/nvme.c
  62. 1 0
      hw/block/onenand.c
  63. 1 0
      hw/block/pflash_cfi01.c
  64. 1 0
      hw/block/pflash_cfi02.c
  65. 1 0
      hw/block/tc58128.c
  66. 1 0
      hw/block/virtio-blk.c
  67. 1 11
      hw/block/xen_disk.c
  68. 1 1
      qemu-img.c
  69. 1 0
      qemu-io-cmds.c
  70. 1 4
      qemu-io.c

+ 1 - 0
block/accounting.c

@@ -23,6 +23,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/accounting.h"
 #include "block/accounting.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/timer.h"
 #include "qemu/timer.h"

+ 1 - 1
block/archipelago.c

@@ -50,6 +50,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"
@@ -59,7 +60,6 @@
 #include "qapi/qmp/qjson.h"
 #include "qapi/qmp/qjson.h"
 #include "qemu/atomic.h"
 #include "qemu/atomic.h"
 
 
-#include <inttypes.h>
 #include <xseg/xseg.h>
 #include <xseg/xseg.h>
 #include <xseg/protocol.h>
 #include <xseg/protocol.h>
 
 

+ 1 - 3
block/backup.c

@@ -11,9 +11,7 @@
  *
  *
  */
  */
 
 
-#include <stdio.h>
-#include <errno.h>
-#include <unistd.h>
+#include "qemu/osdep.h"
 
 
 #include "trace.h"
 #include "trace.h"
 #include "block/block.h"
 #include "block/block.h"

+ 1 - 0
block/blkdebug.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/config-file.h"
 #include "qemu/config-file.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 1
block/blkverify.c

@@ -7,7 +7,7 @@
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  */
  */
 
 
-#include <stdarg.h>
+#include "qemu/osdep.h"
 #include "qemu/sockets.h" /* for EINPROGRESS on Windows */
 #include "qemu/sockets.h" /* for EINPROGRESS on Windows */
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qapi/qmp/qdict.h"
 #include "qapi/qmp/qdict.h"

+ 1 - 0
block/block-backend.c

@@ -10,6 +10,7 @@
  * or later.  See the COPYING.LIB file in the top-level directory.
  * or later.  See the COPYING.LIB file in the top-level directory.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/blockjob.h"
 #include "block/blockjob.h"

+ 1 - 0
block/bochs.c

@@ -22,6 +22,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 0
block/cloop.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 0
block/commit.c

@@ -12,6 +12,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/blockjob.h"
 #include "block/blockjob.h"

+ 1 - 0
block/curl.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 0
block/dmg.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/bswap.h"
 #include "qemu/bswap.h"

+ 1 - 0
block/gluster.c

@@ -7,6 +7,7 @@
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  *
  *
  */
  */
+#include "qemu/osdep.h"
 #include <glusterfs/api/glfs.h>
 #include <glusterfs/api/glfs.h>
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/uri.h"
 #include "qemu/uri.h"

+ 1 - 0
block/io.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "block/blockjob.h"
 #include "block/blockjob.h"

+ 1 - 1
block/iscsi.c

@@ -23,7 +23,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
-#include "config-host.h"
+#include "qemu/osdep.h"
 
 
 #include <poll.h>
 #include <poll.h>
 #include <math.h>
 #include <math.h>

+ 1 - 0
block/linux-aio.c

@@ -7,6 +7,7 @@
  * This work is licensed under the terms of the GNU GPL, version 2 or later.
  * This work is licensed under the terms of the GNU GPL, version 2 or later.
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/aio.h"
 #include "block/aio.h"
 #include "qemu/queue.h"
 #include "qemu/queue.h"

+ 1 - 0
block/mirror.c

@@ -11,6 +11,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "block/blockjob.h"
 #include "block/blockjob.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 0
block/nbd-client.c

@@ -26,6 +26,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "nbd-client.h"
 #include "nbd-client.h"
 #include "qemu/sockets.h"
 #include "qemu/sockets.h"
 
 

+ 1 - 2
block/nbd.c

@@ -26,6 +26,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/nbd-client.h"
 #include "block/nbd-client.h"
 #include "qemu/uri.h"
 #include "qemu/uri.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
@@ -36,8 +37,6 @@
 #include "qapi/qmp/qint.h"
 #include "qapi/qmp/qint.h"
 #include "qapi/qmp/qstring.h"
 #include "qapi/qmp/qstring.h"
 
 
-#include <sys/types.h>
-#include <unistd.h>
 
 
 #define EN_OPTSTR ":exportname="
 #define EN_OPTSTR ":exportname="
 
 

+ 1 - 1
block/nfs.c

@@ -22,7 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
-#include "config-host.h"
+#include "qemu/osdep.h"
 
 
 #include <poll.h>
 #include <poll.h>
 #include "qemu-common.h"
 #include "qemu-common.h"

+ 1 - 0
block/null.c

@@ -10,6 +10,7 @@
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 
 
 #define NULL_OPT_LATENCY "latency-ns"
 #define NULL_OPT_LATENCY "latency-ns"

+ 1 - 0
block/parallels.c

@@ -27,6 +27,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 0
block/qapi.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/qapi.h"
 #include "block/qapi.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/throttle-groups.h"
 #include "block/throttle-groups.h"

+ 1 - 0
block/qcow.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 2
block/qcow2-cache.c

@@ -23,7 +23,7 @@
  */
  */
 
 
 /* Needed for CONFIG_MADVISE */
 /* Needed for CONFIG_MADVISE */
-#include "config-host.h"
+#include "qemu/osdep.h"
 
 
 #if defined(CONFIG_MADVISE) || defined(CONFIG_POSIX_MADVISE)
 #if defined(CONFIG_MADVISE) || defined(CONFIG_POSIX_MADVISE)
 #include <sys/mman.h>
 #include <sys/mman.h>
@@ -31,7 +31,6 @@
 
 
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
-#include "qemu/osdep.h"
 #include "qcow2.h"
 #include "qcow2.h"
 #include "trace.h"
 #include "trace.h"
 
 

+ 1 - 0
block/qcow2-cluster.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include <zlib.h>
 #include <zlib.h>
 
 
 #include "qemu-common.h"
 #include "qemu-common.h"

+ 1 - 0
block/qcow2-refcount.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/qcow2.h"
 #include "block/qcow2.h"

+ 1 - 0
block/qcow2-snapshot.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/qcow2.h"
 #include "block/qcow2.h"

+ 1 - 0
block/qcow2.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 0
block/qed-check.c

@@ -11,6 +11,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qed.h"
 #include "qed.h"
 
 
 typedef struct {
 typedef struct {

+ 1 - 0
block/qed-cluster.c

@@ -12,6 +12,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qed.h"
 #include "qed.h"
 
 
 /**
 /**

+ 1 - 0
block/qed-gencb.c

@@ -11,6 +11,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qed.h"
 #include "qed.h"
 
 
 void *gencb_alloc(size_t len, BlockCompletionFunc *cb, void *opaque)
 void *gencb_alloc(size_t len, BlockCompletionFunc *cb, void *opaque)

+ 1 - 0
block/qed-l2-cache.c

@@ -50,6 +50,7 @@
  * table will be deleted in favor of the existing cache entry.
  * table will be deleted in favor of the existing cache entry.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "qed.h"
 #include "qed.h"
 
 

+ 1 - 0
block/qed-table.c

@@ -12,6 +12,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "qemu/sockets.h" /* for EINPROGRESS on Windows */
 #include "qemu/sockets.h" /* for EINPROGRESS on Windows */
 #include "qed.h"
 #include "qed.h"

+ 1 - 0
block/qed.c

@@ -12,6 +12,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu/timer.h"
 #include "qemu/timer.h"
 #include "trace.h"
 #include "trace.h"
 #include "qed.h"
 #include "qed.h"

+ 1 - 0
block/quorum.c

@@ -13,6 +13,7 @@
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qapi/qmp/qbool.h"
 #include "qapi/qmp/qbool.h"
 #include "qapi/qmp/qdict.h"
 #include "qapi/qmp/qdict.h"

+ 1 - 2
block/raw-posix.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"
 #include "qemu/timer.h"
 #include "qemu/timer.h"
@@ -51,8 +52,6 @@
 #include <sys/dkio.h>
 #include <sys/dkio.h>
 #endif
 #endif
 #ifdef __linux__
 #ifdef __linux__
-#include <sys/types.h>
-#include <sys/stat.h>
 #include <sys/ioctl.h>
 #include <sys/ioctl.h>
 #include <sys/param.h>
 #include <sys/param.h>
 #include <linux/cdrom.h>
 #include <linux/cdrom.h>

+ 1 - 0
block/raw-win32.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/timer.h"
 #include "qemu/timer.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 0
block/raw_bsd.c

@@ -26,6 +26,7 @@
  * IN THE SOFTWARE.
  * IN THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/option.h"
 #include "qemu/option.h"
 
 

+ 1 - 1
block/rbd.c

@@ -11,7 +11,7 @@
  * GNU GPL, version 2 or (at your option) any later version.
  * GNU GPL, version 2 or (at your option) any later version.
  */
  */
 
 
-#include <inttypes.h>
+#include "qemu/osdep.h"
 
 
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"

+ 1 - 0
block/sheepdog.c

@@ -12,6 +12,7 @@
  * GNU GPL, version 2 or (at your option) any later version.
  * GNU GPL, version 2 or (at your option) any later version.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/uri.h"
 #include "qemu/uri.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"

+ 1 - 0
block/snapshot.c

@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/snapshot.h"
 #include "block/snapshot.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qapi/qmp/qerror.h"
 #include "qapi/qmp/qerror.h"

+ 1 - 3
block/ssh.c

@@ -22,9 +22,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdarg.h>
+#include "qemu/osdep.h"
 
 
 #include <libssh2.h>
 #include <libssh2.h>
 #include <libssh2_sftp.h>
 #include <libssh2_sftp.h>

+ 1 - 0
block/stream.c

@@ -11,6 +11,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/blockjob.h"
 #include "block/blockjob.h"

+ 1 - 0
block/throttle-groups.c

@@ -22,6 +22,7 @@
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/throttle-groups.h"
 #include "block/throttle-groups.h"
 #include "qemu/queue.h"
 #include "qemu/queue.h"
 #include "qemu/thread.h"
 #include "qemu/thread.h"

+ 1 - 0
block/vdi.c

@@ -49,6 +49,7 @@
  * so this seems to be reasonable.
  * so this seems to be reasonable.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 0
block/vhdx-endian.c

@@ -15,6 +15,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "block/vhdx.h"
 #include "block/vhdx.h"

+ 1 - 0
block/vhdx-log.c

@@ -17,6 +17,7 @@
  * See the COPYING.LIB file in the top-level directory.
  * See the COPYING.LIB file in the top-level directory.
  *
  *
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"

+ 1 - 0
block/vhdx.c

@@ -15,6 +15,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 0
block/vmdk.c

@@ -23,6 +23,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qapi/qmp/qerror.h"
 #include "qapi/qmp/qerror.h"

+ 1 - 0
block/vpc.c

@@ -22,6 +22,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/module.h"
 #include "qemu/module.h"

+ 1 - 1
block/vvfat.c

@@ -22,7 +22,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
-#include <sys/stat.h>
+#include "qemu/osdep.h"
 #include <dirent.h>
 #include <dirent.h>
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 0
block/win32-aio.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/timer.h"
 #include "qemu/timer.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 0
block/write-threshold.c

@@ -10,6 +10,7 @@
  * See the COPYING.LIB file in the top-level directory.
  * See the COPYING.LIB file in the top-level directory.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "block/block_int.h"
 #include "block/block_int.h"
 #include "qemu/coroutine.h"
 #include "qemu/coroutine.h"
 #include "block/write-threshold.h"
 #include "block/write-threshold.h"

+ 1 - 0
hw/block/block.c

@@ -7,6 +7,7 @@
  * later.  See the COPYING file in the top-level directory.
  * later.  See the COPYING file in the top-level directory.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "sysemu/blockdev.h"
 #include "sysemu/blockdev.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "hw/block/block.h"
 #include "hw/block/block.h"

+ 1 - 0
hw/block/cdrom.c

@@ -25,6 +25,7 @@
 /* ??? Most of the ATAPI emulation is still in ide.c.  It should be moved
 /* ??? Most of the ATAPI emulation is still in ide.c.  It should be moved
    here.  */
    here.  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "hw/scsi/scsi.h"
 #include "hw/scsi/scsi.h"
 
 

+ 1 - 0
hw/block/dataplane/virtio-blk.c

@@ -12,6 +12,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "trace.h"
 #include "trace.h"
 #include "qemu/iov.h"
 #include "qemu/iov.h"
 #include "qemu/thread.h"
 #include "qemu/thread.h"

+ 1 - 0
hw/block/ecc.c

@@ -11,6 +11,7 @@
  * GNU GPL, version 2 or (at your option) any later version.
  * GNU GPL, version 2 or (at your option) any later version.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "hw/block/flash.h"
 #include "hw/block/flash.h"
 
 

+ 1 - 0
hw/block/fdc.c

@@ -27,6 +27,7 @@
  * way. There are changes in DOR register and DMA is not available.
  * way. There are changes in DOR register and DMA is not available.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "hw/block/fdc.h"
 #include "hw/block/fdc.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"

+ 1 - 0
hw/block/hd-geometry.c

@@ -30,6 +30,7 @@
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "hw/block/block.h"
 #include "hw/block/block.h"
 #include "trace.h"
 #include "trace.h"

+ 1 - 0
hw/block/m25p80.c

@@ -21,6 +21,7 @@
  * with this program; if not, see <http://www.gnu.org/licenses/>.
  * with this program; if not, see <http://www.gnu.org/licenses/>.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/blockdev.h"
 #include "sysemu/blockdev.h"

+ 1 - 0
hw/block/nvme.c

@@ -20,6 +20,7 @@
  *      -device nvme,drive=<drive_id>,serial=<serial>,id=<id[optional]>
  *      -device nvme,drive=<drive_id>,serial=<serial>,id=<id[optional]>
  */
  */
 
 
+#include "qemu/osdep.h"
 #include <hw/block/block.h>
 #include <hw/block/block.h>
 #include <hw/hw.h>
 #include <hw/hw.h>
 #include <hw/pci/msix.h>
 #include <hw/pci/msix.h>

+ 1 - 0
hw/block/onenand.c

@@ -18,6 +18,7 @@
  * with this program; if not, see <http://www.gnu.org/licenses/>.
  * with this program; if not, see <http://www.gnu.org/licenses/>.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "hw/block/flash.h"
 #include "hw/block/flash.h"

+ 1 - 0
hw/block/pflash_cfi01.c

@@ -36,6 +36,7 @@
  * It does not implement much more ...
  * It does not implement much more ...
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "hw/block/flash.h"
 #include "hw/block/flash.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"

+ 1 - 0
hw/block/pflash_cfi02.c

@@ -35,6 +35,7 @@
  * It does not implement multiple sectors erase
  * It does not implement multiple sectors erase
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "hw/block/flash.h"
 #include "hw/block/flash.h"
 #include "qemu/timer.h"
 #include "qemu/timer.h"

+ 1 - 0
hw/block/tc58128.c

@@ -1,3 +1,4 @@
+#include "qemu/osdep.h"
 #include "hw/hw.h"
 #include "hw/hw.h"
 #include "hw/sh4/sh.h"
 #include "hw/sh4/sh.h"
 #include "hw/loader.h"
 #include "hw/loader.h"

+ 1 - 0
hw/block/virtio-blk.c

@@ -11,6 +11,7 @@
  *
  *
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/iov.h"
 #include "qemu/iov.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"

+ 1 - 11
hw/block/xen_disk.c

@@ -19,18 +19,8 @@
  *  GNU GPL, version 2 or (at your option) any later version.
  *  GNU GPL, version 2 or (at your option) any later version.
  */
  */
 
 
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <unistd.h>
-#include <inttypes.h>
-#include <time.h>
-#include <fcntl.h>
-#include <errno.h>
+#include "qemu/osdep.h"
 #include <sys/ioctl.h>
 #include <sys/ioctl.h>
-#include <sys/types.h>
-#include <sys/stat.h>
 #include <sys/mman.h>
 #include <sys/mman.h>
 #include <sys/uio.h>
 #include <sys/uio.h>
 
 

+ 1 - 1
qemu-img.c

@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  * THE SOFTWARE.
  */
  */
+#include "qemu/osdep.h"
 #include "qapi-visit.h"
 #include "qapi-visit.h"
 #include "qapi/qmp-output-visitor.h"
 #include "qapi/qmp-output-visitor.h"
 #include "qapi/qmp/qerror.h"
 #include "qapi/qmp/qerror.h"
@@ -28,7 +29,6 @@
 #include "qemu-common.h"
 #include "qemu-common.h"
 #include "qemu/option.h"
 #include "qemu/option.h"
 #include "qemu/error-report.h"
 #include "qemu/error-report.h"
-#include "qemu/osdep.h"
 #include "sysemu/sysemu.h"
 #include "sysemu/sysemu.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "block/block_int.h"
 #include "block/block_int.h"

+ 1 - 0
qemu-io-cmds.c

@@ -8,6 +8,7 @@
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  */
  */
 
 
+#include "qemu/osdep.h"
 #include "qemu-io.h"
 #include "qemu-io.h"
 #include "sysemu/block-backend.h"
 #include "sysemu/block-backend.h"
 #include "block/block.h"
 #include "block/block.h"

+ 1 - 4
qemu-io.c

@@ -7,10 +7,7 @@
  * This work is licensed under the terms of the GNU GPL, version 2 or later.
  * This work is licensed under the terms of the GNU GPL, version 2 or later.
  * See the COPYING file in the top-level directory.
  * See the COPYING file in the top-level directory.
  */
  */
-#include <sys/time.h>
-#include <sys/types.h>
-#include <stdarg.h>
-#include <stdio.h>
+#include "qemu/osdep.h"
 #include <getopt.h>
 #include <getopt.h>
 #include <libgen.h>
 #include <libgen.h>