[Qemu-devel] [PATCH] hw: Do not include "sysemu/block-backend.h" if it is not necessary
After reviewing a patch from Philippe that removes block-backend.h from hw/lm32/milkymist.c, I noticed that this header is included unnecessarily in a lot of other files, too. Remove those unneeded includes to speed up the compilation process a little bit. Signed-off-by: Thomas Huth --- hw/arm/highbank.c | 1 - hw/arm/msf2-soc.c | 1 - hw/arm/realview.c | 1 - hw/arm/tosa.c | 1 - hw/i386/pc.c | 2 -- hw/i386/pc_piix.c | 1 - hw/ide/ahci-allwinner.c| 1 - hw/ide/cmd646.c| 1 - hw/ide/ich.c | 1 - hw/ide/isa.c | 1 - hw/ide/microdrive.c| 1 - hw/ide/mmio.c | 1 - hw/mips/mips_fulong2e.c| 1 - hw/mips/mips_jazz.c| 1 - hw/ppc/mac_newworld.c | 1 - hw/ppc/mac_oldworld.c | 1 - hw/ppc/prep.c | 1 - hw/scsi/mptendian.c| 1 - hw/sd/core.c | 1 - hw/sparc/sun4m.c | 1 - hw/tricore/tricore_testboard.c | 2 -- 21 files changed, 23 deletions(-) diff --git a/hw/arm/highbank.c b/hw/arm/highbank.c index 287392b..1742cf6 100644 --- a/hw/arm/highbank.c +++ b/hw/arm/highbank.c @@ -27,7 +27,6 @@ #include "sysemu/kvm.h" #include "sysemu/sysemu.h" #include "hw/boards.h" -#include "sysemu/block-backend.h" #include "exec/address-spaces.h" #include "qemu/error-report.h" #include "hw/char/pl011.h" diff --git a/hw/arm/msf2-soc.c b/hw/arm/msf2-soc.c index a8ec2cd..f68df56 100644 --- a/hw/arm/msf2-soc.c +++ b/hw/arm/msf2-soc.c @@ -29,7 +29,6 @@ #include "exec/address-spaces.h" #include "hw/char/serial.h" #include "hw/boards.h" -#include "sysemu/block-backend.h" #include "qemu/cutils.h" #include "hw/arm/msf2-soc.h" #include "hw/misc/unimp.h" diff --git a/hw/arm/realview.c b/hw/arm/realview.c index 87cd1e5..2139a62 100644 --- a/hw/arm/realview.c +++ b/hw/arm/realview.c @@ -20,7 +20,6 @@ #include "sysemu/sysemu.h" #include "hw/boards.h" #include "hw/i2c/i2c.h" -#include "sysemu/block-backend.h" #include "exec/address-spaces.h" #include "qemu/error-report.h" #include "hw/char/pl011.h" diff --git a/hw/arm/tosa.c b/hw/arm/tosa.c index a55b1a3..7a925fa 100644 --- a/hw/arm/tosa.c +++ b/hw/arm/tosa.c @@ -22,7 +22,6 @@ #include "hw/boards.h" #include "hw/i2c/i2c.h" #include "hw/ssi/ssi.h" -#include "sysemu/block-backend.h" #include "hw/sysbus.h" #include "exec/address-spaces.h" #include "sysemu/sysemu.h" diff --git a/hw/i386/pc.c b/hw/i386/pc.c index 55e69d6..7670b45 100644 --- a/hw/i386/pc.c +++ b/hw/i386/pc.c @@ -50,8 +50,6 @@ #include "sysemu/qtest.h" #include "kvm_i386.h" #include "hw/xen/xen.h" -#include "sysemu/block-backend.h" -#include "hw/block/block.h" #include "ui/qemu-spice.h" #include "exec/memory.h" #include "exec/address-spaces.h" diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index 456dc9e..527c922 100644 --- a/hw/i386/pc_piix.c +++ b/hw/i386/pc_piix.c @@ -40,7 +40,6 @@ #include "sysemu/sysemu.h" #include "hw/sysbus.h" #include "sysemu/arch_init.h" -#include "sysemu/block-backend.h" #include "hw/i2c/smbus.h" #include "hw/xen/xen.h" #include "exec/memory.h" diff --git a/hw/ide/ahci-allwinner.c b/hw/ide/ahci-allwinner.c index c3f1604..5397483 100644 --- a/hw/ide/ahci-allwinner.c +++ b/hw/ide/ahci-allwinner.c @@ -18,7 +18,6 @@ #include "qemu/osdep.h" #include "hw/hw.h" #include "qemu/error-report.h" -#include "sysemu/block-backend.h" #include "sysemu/dma.h" #include "hw/ide/internal.h" #include "hw/ide/ahci_internal.h" diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c index 65aff51..6bb92d7 100644 --- a/hw/ide/cmd646.c +++ b/hw/ide/cmd646.c @@ -26,7 +26,6 @@ #include "hw/hw.h" #include "hw/pci/pci.h" #include "hw/isa/isa.h" -#include "sysemu/block-backend.h" #include "sysemu/sysemu.h" #include "sysemu/dma.h" diff --git a/hw/ide/ich.c b/hw/ide/ich.c index c01b24e..134478e 100644 --- a/hw/ide/ich.c +++ b/hw/ide/ich.c @@ -65,7 +65,6 @@ #include "hw/pci/msi.h" #include "hw/pci/pci.h" #include "hw/isa/isa.h" -#include "sysemu/block-backend.h" #include "sysemu/dma.h" #include "hw/ide/pci.h" #include "hw/ide/ahci_internal.h" diff --git a/hw/ide/isa.c b/hw/ide/isa.c index 9fb24fc..028bd61 100644 --- a/hw/ide/isa.c +++ b/hw/ide/isa.c @@ -25,7 +25,6 @@ #include "qemu/osdep.h" #include "hw/hw.h" #include "hw/isa/isa.h" -#include "sysemu/block-backend.h" #include "sysemu/dma.h" #include "hw/ide/internal.h" diff --git a/hw/ide/microdrive.c b/hw/ide/microdrive.c index 58e4f52..34bb98d 100644 --- a/hw/ide/microdrive.c +++ b/hw/ide/microdrive.c @@ -25,7 +25,6 @@ #include "qemu/osdep.h" #include "hw/hw.h" #include "hw/pcmcia.h" -#include "sysemu/block-backend.h" #include "sysemu/dma.h" #include "hw/ide/internal.h" diff --git a/hw/ide/mmio.c b/hw/ide/mmio.c index 6f12f45..42fcf13 100644 --- a/hw/ide/mmio.c +++ b/hw/ide/mmio.c @@ -25,7 +25,6 @@ #include "qemu/osdep.h" #include "hw/hw.h" #include "hw/sy
Re: [Qemu-devel] [PATCH] hw: Do not include "sysemu/block-backend.h" if it is not necessary
On 15.02.2018 09:55, Thomas Huth wrote: > After reviewing a patch from Philippe that removes block-backend.h > from hw/lm32/milkymist.c, I noticed that this header is included > unnecessarily in a lot of other files, too. Remove those unneeded > includes to speed up the compilation process a little bit. > > Signed-off-by: Thomas Huth > --- > hw/arm/highbank.c | 1 - > hw/arm/msf2-soc.c | 1 - > hw/arm/realview.c | 1 - > hw/arm/tosa.c | 1 - > hw/i386/pc.c | 2 -- > hw/i386/pc_piix.c | 1 - > hw/ide/ahci-allwinner.c| 1 - > hw/ide/cmd646.c| 1 - > hw/ide/ich.c | 1 - > hw/ide/isa.c | 1 - > hw/ide/microdrive.c| 1 - > hw/ide/mmio.c | 1 - > hw/mips/mips_fulong2e.c| 1 - > hw/mips/mips_jazz.c| 1 - > hw/ppc/mac_newworld.c | 1 - > hw/ppc/mac_oldworld.c | 1 - > hw/ppc/prep.c | 1 - > hw/scsi/mptendian.c| 1 - > hw/sd/core.c | 1 - > hw/sparc/sun4m.c | 1 - > hw/tricore/tricore_testboard.c | 2 -- > 21 files changed, 23 deletions(-) > > diff --git a/hw/arm/highbank.c b/hw/arm/highbank.c > index 287392b..1742cf6 100644 > --- a/hw/arm/highbank.c > +++ b/hw/arm/highbank.c > @@ -27,7 +27,6 @@ > #include "sysemu/kvm.h" > #include "sysemu/sysemu.h" > #include "hw/boards.h" > -#include "sysemu/block-backend.h" > #include "exec/address-spaces.h" > #include "qemu/error-report.h" > #include "hw/char/pl011.h" > diff --git a/hw/arm/msf2-soc.c b/hw/arm/msf2-soc.c > index a8ec2cd..f68df56 100644 > --- a/hw/arm/msf2-soc.c > +++ b/hw/arm/msf2-soc.c > @@ -29,7 +29,6 @@ > #include "exec/address-spaces.h" > #include "hw/char/serial.h" > #include "hw/boards.h" > -#include "sysemu/block-backend.h" > #include "qemu/cutils.h" > #include "hw/arm/msf2-soc.h" > #include "hw/misc/unimp.h" > diff --git a/hw/arm/realview.c b/hw/arm/realview.c > index 87cd1e5..2139a62 100644 > --- a/hw/arm/realview.c > +++ b/hw/arm/realview.c > @@ -20,7 +20,6 @@ > #include "sysemu/sysemu.h" > #include "hw/boards.h" > #include "hw/i2c/i2c.h" > -#include "sysemu/block-backend.h" > #include "exec/address-spaces.h" > #include "qemu/error-report.h" > #include "hw/char/pl011.h" > diff --git a/hw/arm/tosa.c b/hw/arm/tosa.c > index a55b1a3..7a925fa 100644 > --- a/hw/arm/tosa.c > +++ b/hw/arm/tosa.c > @@ -22,7 +22,6 @@ > #include "hw/boards.h" > #include "hw/i2c/i2c.h" > #include "hw/ssi/ssi.h" > -#include "sysemu/block-backend.h" > #include "hw/sysbus.h" > #include "exec/address-spaces.h" > #include "sysemu/sysemu.h" > diff --git a/hw/i386/pc.c b/hw/i386/pc.c > index 55e69d6..7670b45 100644 > --- a/hw/i386/pc.c > +++ b/hw/i386/pc.c > @@ -50,8 +50,6 @@ > #include "sysemu/qtest.h" > #include "kvm_i386.h" > #include "hw/xen/xen.h" > -#include "sysemu/block-backend.h" > -#include "hw/block/block.h" > #include "ui/qemu-spice.h" > #include "exec/memory.h" > #include "exec/address-spaces.h" > diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c > index 456dc9e..527c922 100644 > --- a/hw/i386/pc_piix.c > +++ b/hw/i386/pc_piix.c > @@ -40,7 +40,6 @@ > #include "sysemu/sysemu.h" > #include "hw/sysbus.h" > #include "sysemu/arch_init.h" > -#include "sysemu/block-backend.h" > #include "hw/i2c/smbus.h" > #include "hw/xen/xen.h" > #include "exec/memory.h" > diff --git a/hw/ide/ahci-allwinner.c b/hw/ide/ahci-allwinner.c > index c3f1604..5397483 100644 > --- a/hw/ide/ahci-allwinner.c > +++ b/hw/ide/ahci-allwinner.c > @@ -18,7 +18,6 @@ > #include "qemu/osdep.h" > #include "hw/hw.h" > #include "qemu/error-report.h" > -#include "sysemu/block-backend.h" > #include "sysemu/dma.h" > #include "hw/ide/internal.h" > #include "hw/ide/ahci_internal.h" > diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c > index 65aff51..6bb92d7 100644 > --- a/hw/ide/cmd646.c > +++ b/hw/ide/cmd646.c > @@ -26,7 +26,6 @@ > #include "hw/hw.h" > #include "hw/pci/pci.h" > #include "hw/isa/isa.h" > -#include "sysemu/block-backend.h" > #include "sysemu/sysemu.h" > #include "sysemu/dma.h" > > diff --git a/hw/ide/ich.c b/hw/ide/ich.c > index c01b24e..134478e 100644 > --- a/hw/ide/ich.c > +++ b/hw/ide/ich.c > @@ -65,7 +65,6 @@ > #include "hw/pci/msi.h" > #include "hw/pci/pci.h" > #include "hw/isa/isa.h" > -#include "sysemu/block-backend.h" > #include "sysemu/dma.h" > #include "hw/ide/pci.h" > #include "hw/ide/ahci_internal.h" > diff --git a/hw/ide/isa.c b/hw/ide/isa.c > index 9fb24fc..028bd61 100644 > --- a/hw/ide/isa.c > +++ b/hw/ide/isa.c > @@ -25,7 +25,6 @@ > #include "qemu/osdep.h" > #include "hw/hw.h" > #include "hw/isa/isa.h" > -#include "sysemu/block-backend.h" > #include "sysemu/dma.h" > > #include "hw/ide/internal.h" > diff --git a/hw/ide/microdrive.c b/hw/ide/microdrive.c > index 58e4f52..34bb98d 100644 > --- a/hw/ide/microdrive.c > +++ b/hw/ide/microdrive.c > @@ -25,7 +25,6 @@ >