diff options
author | Markus Armbruster <armbru@redhat.com> | 2010-06-02 18:48:27 +0200 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2010-06-04 15:20:47 +0200 |
commit | 666daa68234b5b1758652633cab07d5ca6046a5b (patch) | |
tree | d4511a0094915ab279c7c02e74fbc6b53c524157 /hw | |
parent | 7b370f513002b340a383fac961dc8c6fdf39eddc (diff) |
blockdev: Collect block device code in new blockdev.c
Anything that moves hundreds of lines out of vl.c can't be all bad.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/acpi_piix4.c | 1 | ||||
-rw-r--r-- | hw/apb_pci.c | 1 | ||||
-rw-r--r-- | hw/device-hotplug.c | 2 | ||||
-rw-r--r-- | hw/fdc.c | 1 | ||||
-rw-r--r-- | hw/fdc.h | 2 | ||||
-rw-r--r-- | hw/ide/core.c | 2 | ||||
-rw-r--r-- | hw/ide/qdev.c | 1 | ||||
-rw-r--r-- | hw/lan9118.c | 1 | ||||
-rw-r--r-- | hw/nand.c | 3 | ||||
-rw-r--r-- | hw/omap2.c | 2 | ||||
-rw-r--r-- | hw/onenand.c | 3 | ||||
-rw-r--r-- | hw/parallel.c | 1 | ||||
-rw-r--r-- | hw/pc.c | 1 | ||||
-rw-r--r-- | hw/pc_piix.c | 1 | ||||
-rw-r--r-- | hw/pci-hotplug.c | 2 | ||||
-rw-r--r-- | hw/pcmcia.h | 2 | ||||
-rw-r--r-- | hw/qdev-properties.c | 1 | ||||
-rw-r--r-- | hw/qdev.h | 2 | ||||
-rw-r--r-- | hw/scsi-bus.c | 1 | ||||
-rw-r--r-- | hw/scsi-disk.c | 2 | ||||
-rw-r--r-- | hw/scsi-generic.c | 1 | ||||
-rw-r--r-- | hw/serial.c | 1 | ||||
-rw-r--r-- | hw/usb-hid.c | 1 | ||||
-rw-r--r-- | hw/usb-msd.c | 2 | ||||
-rw-r--r-- | hw/virtio-blk.c | 2 | ||||
-rw-r--r-- | hw/virtio-pci.c | 1 |
26 files changed, 17 insertions, 23 deletions
diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c index 0fce958d07..a87286b917 100644 --- a/hw/acpi_piix4.c +++ b/hw/acpi_piix4.c @@ -21,6 +21,7 @@ #include "pm_smbus.h" #include "pci.h" #include "acpi.h" +#include "sysemu.h" //#define DEBUG diff --git a/hw/apb_pci.c b/hw/apb_pci.c index b53e3c3bf9..31c8d705a2 100644 --- a/hw/apb_pci.c +++ b/hw/apb_pci.c @@ -31,6 +31,7 @@ #include "pci_host.h" #include "rwhandler.h" #include "apb_pci.h" +#include "sysemu.h" /* debug APB */ //#define DEBUG_APB diff --git a/hw/device-hotplug.c b/hw/device-hotplug.c index a3fe99ea77..c1a9a561d7 100644 --- a/hw/device-hotplug.c +++ b/hw/device-hotplug.c @@ -25,8 +25,6 @@ #include "hw.h" #include "boards.h" #include "net.h" -#include "block_int.h" -#include "sysemu.h" DriveInfo *add_init_drive(const char *optstr) { @@ -29,7 +29,6 @@ #include "hw.h" #include "fdc.h" -#include "block.h" #include "qemu-timer.h" #include "isa.h" #include "sysbus.h" @@ -2,7 +2,7 @@ #define HW_FDC_H /* fdc.c */ -#include "sysemu.h" +#include "blockdev.h" #define MAX_FD 2 typedef struct FDCtrl FDCtrl; diff --git a/hw/ide/core.c b/hw/ide/core.c index 70af1b6043..045d18db2b 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -26,8 +26,6 @@ #include <hw/pc.h> #include <hw/pci.h> #include <hw/scsi.h> -#include "block.h" -#include "block_int.h" #include "qemu-timer.h" #include "sysemu.h" #include "dma.h" diff --git a/hw/ide/qdev.c b/hw/ide/qdev.c index 6231d7716c..0f9f22e30f 100644 --- a/hw/ide/qdev.c +++ b/hw/ide/qdev.c @@ -17,7 +17,6 @@ * License along with this library; if not, see <http://www.gnu.org/licenses/>. */ #include <hw/hw.h> -#include "sysemu.h" #include "dma.h" #include <hw/ide/internal.h> diff --git a/hw/lan9118.c b/hw/lan9118.c index 16d33304d5..b996dc4f0c 100644 --- a/hw/lan9118.c +++ b/hw/lan9118.c @@ -10,6 +10,7 @@ #include "sysbus.h" #include "net.h" #include "devices.h" +#include "sysemu.h" /* For crc32 */ #include <zlib.h> @@ -13,9 +13,8 @@ # include "hw.h" # include "flash.h" -# include "block.h" +# include "blockdev.h" /* FIXME: Pass block device as an argument. */ -# include "sysemu.h" # define NAND_CMD_READ0 0x00 # define NAND_CMD_READ1 0x01 diff --git a/hw/omap2.c b/hw/omap2.c index bd1b35e661..666c15adb2 100644 --- a/hw/omap2.c +++ b/hw/omap2.c @@ -17,6 +17,8 @@ * You should have received a copy of the GNU General Public License along * with this program; if not, see <http://www.gnu.org/licenses/>. */ + +#include "blockdev.h" #include "hw.h" #include "arm-misc.h" #include "omap.h" diff --git a/hw/onenand.c b/hw/onenand.c index c1e7e4d608..4118db922d 100644 --- a/hw/onenand.c +++ b/hw/onenand.c @@ -21,8 +21,7 @@ #include "qemu-common.h" #include "flash.h" #include "irq.h" -#include "sysemu.h" -#include "block.h" +#include "blockdev.h" /* 11 for 2kB-page OneNAND ("2nd generation") and 10 for 1kB-page chips */ #define PAGE_SHIFT 11 diff --git a/hw/parallel.c b/hw/parallel.c index be8e2d5479..6b11672e15 100644 --- a/hw/parallel.c +++ b/hw/parallel.c @@ -26,6 +26,7 @@ #include "qemu-char.h" #include "isa.h" #include "pc.h" +#include "sysemu.h" //#define DEBUG_PARALLEL @@ -35,6 +35,7 @@ #include "elf.h" #include "multiboot.h" #include "mc146818rtc.h" +#include "sysemu.h" /* output Bochs bios info messages */ //#define DEBUG_BIOS diff --git a/hw/pc_piix.c b/hw/pc_piix.c index 70f563a67e..dc46846923 100644 --- a/hw/pc_piix.c +++ b/hw/pc_piix.c @@ -32,6 +32,7 @@ #include "boards.h" #include "ide.h" #include "kvm.h" +#include "sysemu.h" #define MAX_IDE_BUS 2 diff --git a/hw/pci-hotplug.c b/hw/pci-hotplug.c index a8f3df1701..c39e640089 100644 --- a/hw/pci-hotplug.c +++ b/hw/pci-hotplug.c @@ -26,10 +26,8 @@ #include "boards.h" #include "pci.h" #include "net.h" -#include "sysemu.h" #include "pc.h" #include "monitor.h" -#include "block_int.h" #include "scsi.h" #include "virtio-blk.h" #include "qemu-config.h" diff --git a/hw/pcmcia.h b/hw/pcmcia.h index cf2db9d325..360292395b 100644 --- a/hw/pcmcia.h +++ b/hw/pcmcia.h @@ -1,7 +1,7 @@ /* PCMCIA/Cardbus */ #include "qemu-common.h" -#include "sysemu.h" +#include "blockdev.h" typedef struct { qemu_irq irq; diff --git a/hw/qdev-properties.c b/hw/qdev-properties.c index 48a6b45cda..5a8739debe 100644 --- a/hw/qdev-properties.c +++ b/hw/qdev-properties.c @@ -1,4 +1,3 @@ -#include "sysemu.h" #include "net.h" #include "qdev.h" #include "qerror.h" @@ -2,7 +2,7 @@ #define QDEV_H #include "hw.h" -#include "sysemu.h" +#include "blockdev.h" #include "qemu-queue.h" #include "qemu-char.h" #include "qemu-option.h" diff --git a/hw/scsi-bus.c b/hw/scsi-bus.c index 383240bc07..055a94d255 100644 --- a/hw/scsi-bus.c +++ b/hw/scsi-bus.c @@ -2,7 +2,6 @@ #include "qemu-error.h" #include "scsi.h" #include "scsi-defs.h" -#include "block.h" #include "qdev.h" static struct BusInfo scsi_bus_info = { diff --git a/hw/scsi-disk.c b/hw/scsi-disk.c index a3559d1fcd..a9bf7d261a 100644 --- a/hw/scsi-disk.c +++ b/hw/scsi-disk.c @@ -33,9 +33,9 @@ do { fprintf(stderr, "scsi-disk: " fmt , ## __VA_ARGS__); } while (0) #include "qemu-common.h" #include "qemu-error.h" -#include "block.h" #include "scsi.h" #include "scsi-defs.h" +#include "sysemu.h" #define SCSI_DMA_BUF_SIZE 131072 #define SCSI_MAX_INQUIRY_LEN 256 diff --git a/hw/scsi-generic.c b/hw/scsi-generic.c index c9aa853cc4..e31060e944 100644 --- a/hw/scsi-generic.c +++ b/hw/scsi-generic.c @@ -13,7 +13,6 @@ #include "qemu-common.h" #include "qemu-error.h" -#include "block.h" #include "scsi.h" #ifdef __linux__ diff --git a/hw/serial.c b/hw/serial.c index 9102edb77b..c7e4e77cb0 100644 --- a/hw/serial.c +++ b/hw/serial.c @@ -27,6 +27,7 @@ #include "isa.h" #include "pc.h" #include "qemu-timer.h" +#include "sysemu.h" //#define DEBUG_SERIAL diff --git a/hw/usb-hid.c b/hw/usb-hid.c index 8e6c6e0322..228d0a052a 100644 --- a/hw/usb-hid.c +++ b/hw/usb-hid.c @@ -25,6 +25,7 @@ #include "hw.h" #include "console.h" #include "usb.h" +#include "sysemu.h" /* HID interface requests */ #define GET_REPORT 0xa101 diff --git a/hw/usb-msd.c b/hw/usb-msd.c index 0ba4a64d7c..003bd8a4cd 100644 --- a/hw/usb-msd.c +++ b/hw/usb-msd.c @@ -11,10 +11,10 @@ #include "qemu-option.h" #include "qemu-config.h" #include "usb.h" -#include "block.h" #include "scsi.h" #include "console.h" #include "monitor.h" +#include "sysemu.h" //#define DEBUG_MSD diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c index 80d51c4c0c..cdcb492c14 100644 --- a/hw/virtio-blk.c +++ b/hw/virtio-blk.c @@ -12,9 +12,7 @@ */ #include <qemu-common.h> -#include <sysemu.h> #include "virtio-blk.h" -#include "block_int.h" #ifdef __linux__ # include <scsi/sg.h> #endif diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c index 7ddf612282..e101fa0a7d 100644 --- a/hw/virtio-pci.c +++ b/hw/virtio-pci.c @@ -22,7 +22,6 @@ #include "qemu-error.h" #include "msix.h" #include "net.h" -#include "block_int.h" #include "loader.h" #include "kvm.h" |