Re: [Qemu-devel] [PATCH 3/3] arm: Rename hw/arm/arm.h to hw/arm/boot.h

2019-05-16 Thread Peter Maydell
On Thu, 16 May 2019 at 19:16, Philippe Mathieu-Daudé  wrote:
>
> On 5/16/19 6:38 PM, Peter Maydell wrote:
> > The header file hw/arm/arm.h now includes only declarations
> > relating to hw/arm/boot.c functionality. Rename it accordingly,
> > and adjust its header comment.
> >
> > The bulk of this commit was created via
> >  perl -pi -e 's|hw/arm/arm.h|hw/arm/boot.h|' hw/arm/*.c include/hw/arm/*.h
> >
> > Signed-off-by: Peter Maydell 
> > ---

> > diff --git a/include/hw/arm/aspeed_soc.h b/include/hw/arm/aspeed_soc.h
> > index 11ec0179db5..24078fd1895 100644
> > --- a/include/hw/arm/aspeed_soc.h
> > +++ b/include/hw/arm/aspeed_soc.h
> > @@ -12,7 +12,7 @@
> >  #ifndef ASPEED_SOC_H
> >  #define ASPEED_SOC_H
> >
> > -#include "hw/arm/arm.h"
> > +#include "hw/arm/boot.h"
>
> I guess we can drop this one...
>
> >  #include "hw/intc/aspeed_vic.h"
> >  #include "hw/misc/aspeed_scu.h"
> >  #include "hw/misc/aspeed_sdmc.h"
> > diff --git a/include/hw/arm/bcm2836.h b/include/hw/arm/bcm2836.h
> > index 93248399ba0..1b04a0e7fe8 100644
> > --- a/include/hw/arm/bcm2836.h
> > +++ b/include/hw/arm/bcm2836.h
> > @@ -11,7 +11,7 @@
> >  #ifndef BCM2836_H
> >  #define BCM2836_H
> >
> > -#include "hw/arm/arm.h"
> > +#include "hw/arm/boot.h"
>
> ... this one too ...
>

> > --- a/hw/arm/msf2-soc.c
> > +++ b/hw/arm/msf2-soc.c
> > @@ -26,7 +26,7 @@
> >  #include "qemu/units.h"
> >  #include "qapi/error.h"
> >  #include "qemu-common.h"
> > -#include "hw/arm/arm.h"
> > +#include "hw/arm/boot.h"
>
> ... and this one too, it is not required.
>
> >  #include "exec/address-spaces.h"
> >  #include "hw/char/serial.h"
> >  #include "hw/boards.h"

I guess so. I decided I didn't really feel like trying to test
whether all of them were needed, since they're at least all
includes in board or SoC sources in hw/arm...

thanks
-- PMM



Re: [Qemu-devel] [PATCH 3/3] arm: Rename hw/arm/arm.h to hw/arm/boot.h

2019-05-16 Thread Philippe Mathieu-Daudé
On 5/16/19 6:38 PM, Peter Maydell wrote:
> The header file hw/arm/arm.h now includes only declarations
> relating to hw/arm/boot.c functionality. Rename it accordingly,
> and adjust its header comment.
> 
> The bulk of this commit was created via
>  perl -pi -e 's|hw/arm/arm.h|hw/arm/boot.h|' hw/arm/*.c include/hw/arm/*.h
> 
> Signed-off-by: Peter Maydell 
> ---
>  include/hw/arm/allwinner-a10.h   | 2 +-
>  include/hw/arm/aspeed_soc.h  | 2 +-
>  include/hw/arm/bcm2836.h | 2 +-
>  include/hw/arm/{arm.h => boot.h} | 8 
>  include/hw/arm/fsl-imx25.h   | 2 +-
>  include/hw/arm/fsl-imx31.h   | 2 +-
>  include/hw/arm/fsl-imx6.h| 2 +-
>  include/hw/arm/fsl-imx6ul.h  | 2 +-
>  include/hw/arm/fsl-imx7.h| 2 +-
>  include/hw/arm/virt.h| 2 +-
>  include/hw/arm/xlnx-versal.h | 2 +-
>  include/hw/arm/xlnx-zynqmp.h | 2 +-
>  hw/arm/armsse.c  | 2 +-
>  hw/arm/armv7m.c  | 2 +-
>  hw/arm/aspeed.c  | 2 +-
>  hw/arm/boot.c| 2 +-
>  hw/arm/collie.c  | 2 +-
>  hw/arm/exynos4210.c  | 2 +-
>  hw/arm/exynos4_boards.c  | 2 +-
>  hw/arm/highbank.c| 2 +-
>  hw/arm/integratorcp.c| 2 +-
>  hw/arm/mainstone.c   | 2 +-
>  hw/arm/microbit.c| 2 +-
>  hw/arm/mps2-tz.c | 2 +-
>  hw/arm/mps2.c| 2 +-
>  hw/arm/msf2-soc.c| 2 +-
>  hw/arm/msf2-som.c| 2 +-
>  hw/arm/musca.c   | 2 +-
>  hw/arm/musicpal.c| 2 +-
>  hw/arm/netduino2.c   | 2 +-
>  hw/arm/nrf51_soc.c   | 2 +-
>  hw/arm/nseries.c | 2 +-
>  hw/arm/omap1.c   | 2 +-
>  hw/arm/omap2.c   | 2 +-
>  hw/arm/omap_sx1.c| 2 +-
>  hw/arm/palm.c| 2 +-
>  hw/arm/raspi.c   | 2 +-
>  hw/arm/realview.c| 2 +-
>  hw/arm/spitz.c   | 2 +-
>  hw/arm/stellaris.c   | 2 +-
>  hw/arm/stm32f205_soc.c   | 2 +-
>  hw/arm/strongarm.c   | 2 +-
>  hw/arm/tosa.c| 2 +-
>  hw/arm/versatilepb.c | 2 +-
>  hw/arm/vexpress.c| 2 +-
>  hw/arm/virt.c| 2 +-
>  hw/arm/xilinx_zynq.c | 2 +-
>  hw/arm/xlnx-versal.c | 2 +-
>  hw/arm/z2.c  | 2 +-
>  49 files changed, 52 insertions(+), 52 deletions(-)
>  rename include/hw/arm/{arm.h => boot.h} (98%)
> 
> diff --git a/include/hw/arm/allwinner-a10.h b/include/hw/arm/allwinner-a10.h
> index 389e128d0fc..6305b9c586f 100644
> --- a/include/hw/arm/allwinner-a10.h
> +++ b/include/hw/arm/allwinner-a10.h
> @@ -3,7 +3,7 @@
>  #include "qemu-common.h"
>  #include "qemu/error-report.h"
>  #include "hw/char/serial.h"
> -#include "hw/arm/arm.h"
> +#include "hw/arm/boot.h"
>  #include "hw/timer/allwinner-a10-pit.h"
>  #include "hw/intc/allwinner-a10-pic.h"
>  #include "hw/net/allwinner_emac.h"
> diff --git a/include/hw/arm/aspeed_soc.h b/include/hw/arm/aspeed_soc.h
> index 11ec0179db5..24078fd1895 100644
> --- a/include/hw/arm/aspeed_soc.h
> +++ b/include/hw/arm/aspeed_soc.h
> @@ -12,7 +12,7 @@
>  #ifndef ASPEED_SOC_H
>  #define ASPEED_SOC_H
>  
> -#include "hw/arm/arm.h"
> +#include "hw/arm/boot.h"

I guess we can drop this one...

>  #include "hw/intc/aspeed_vic.h"
>  #include "hw/misc/aspeed_scu.h"
>  #include "hw/misc/aspeed_sdmc.h"
> diff --git a/include/hw/arm/bcm2836.h b/include/hw/arm/bcm2836.h
> index 93248399ba0..1b04a0e7fe8 100644
> --- a/include/hw/arm/bcm2836.h
> +++ b/include/hw/arm/bcm2836.h
> @@ -11,7 +11,7 @@
>  #ifndef BCM2836_H
>  #define BCM2836_H
>  
> -#include "hw/arm/arm.h"
> +#include "hw/arm/boot.h"

... this one too ...

>  #include "hw/arm/bcm2835_peripherals.h"
>  #include "hw/intc/bcm2836_control.h"
>  
> diff --git a/include/hw/arm/arm.h b/include/hw/arm/boot.h
> similarity index 98%
> rename from include/hw/arm/arm.h
> rename to include/hw/arm/boot.h
> index ba3a9b41422..c48cc4c2bca 100644
> --- a/include/hw/arm/arm.h
> +++ b/include/hw/arm/boot.h
> @@ -1,5 +1,5 @@
>  /*
> - * Misc ARM declarations
> + * ARM kernel loader.
>   *
>   * Copyright (c) 2006 CodeSourcery.
>   * Written by Paul Brook
> @@ -8,8 +8,8 @@
>   *
>   */
>  
> -#ifndef HW_ARM_H
> -#define HW_ARM_H
> +#ifndef HW_ARM_BOOT_H
> +#define HW_ARM_BOOT_H
>  
>  #include "exec/memory.h"
>  #include "target/arm/cpu-qom.h"
> @@ -167,4 +167,4 @@ void arm_write_secure_board_setup_dummy_smc(ARMCPU *cpu,
>  const struct arm_boot_info *info,
>  hwaddr mvbar_addr);
>  
> -#endif /* HW_ARM_H */
> +#endif /* HW_ARM_BOOT_H */
> diff --git a/include/hw/arm/fsl-imx25.h b/include/hw/arm/fsl-imx25.h
> index 65a73714efe..3280ab1fb05 100644
> --- a/include/hw/arm/fsl-imx25.h
> +++ b/include/hw/arm/fsl-imx25.h
> @@ -17,7 

[Qemu-devel] [PATCH 3/3] arm: Rename hw/arm/arm.h to hw/arm/boot.h

2019-05-16 Thread Peter Maydell
The header file hw/arm/arm.h now includes only declarations
relating to hw/arm/boot.c functionality. Rename it accordingly,
and adjust its header comment.

The bulk of this commit was created via
 perl -pi -e 's|hw/arm/arm.h|hw/arm/boot.h|' hw/arm/*.c include/hw/arm/*.h

Signed-off-by: Peter Maydell 
---
 include/hw/arm/allwinner-a10.h   | 2 +-
 include/hw/arm/aspeed_soc.h  | 2 +-
 include/hw/arm/bcm2836.h | 2 +-
 include/hw/arm/{arm.h => boot.h} | 8 
 include/hw/arm/fsl-imx25.h   | 2 +-
 include/hw/arm/fsl-imx31.h   | 2 +-
 include/hw/arm/fsl-imx6.h| 2 +-
 include/hw/arm/fsl-imx6ul.h  | 2 +-
 include/hw/arm/fsl-imx7.h| 2 +-
 include/hw/arm/virt.h| 2 +-
 include/hw/arm/xlnx-versal.h | 2 +-
 include/hw/arm/xlnx-zynqmp.h | 2 +-
 hw/arm/armsse.c  | 2 +-
 hw/arm/armv7m.c  | 2 +-
 hw/arm/aspeed.c  | 2 +-
 hw/arm/boot.c| 2 +-
 hw/arm/collie.c  | 2 +-
 hw/arm/exynos4210.c  | 2 +-
 hw/arm/exynos4_boards.c  | 2 +-
 hw/arm/highbank.c| 2 +-
 hw/arm/integratorcp.c| 2 +-
 hw/arm/mainstone.c   | 2 +-
 hw/arm/microbit.c| 2 +-
 hw/arm/mps2-tz.c | 2 +-
 hw/arm/mps2.c| 2 +-
 hw/arm/msf2-soc.c| 2 +-
 hw/arm/msf2-som.c| 2 +-
 hw/arm/musca.c   | 2 +-
 hw/arm/musicpal.c| 2 +-
 hw/arm/netduino2.c   | 2 +-
 hw/arm/nrf51_soc.c   | 2 +-
 hw/arm/nseries.c | 2 +-
 hw/arm/omap1.c   | 2 +-
 hw/arm/omap2.c   | 2 +-
 hw/arm/omap_sx1.c| 2 +-
 hw/arm/palm.c| 2 +-
 hw/arm/raspi.c   | 2 +-
 hw/arm/realview.c| 2 +-
 hw/arm/spitz.c   | 2 +-
 hw/arm/stellaris.c   | 2 +-
 hw/arm/stm32f205_soc.c   | 2 +-
 hw/arm/strongarm.c   | 2 +-
 hw/arm/tosa.c| 2 +-
 hw/arm/versatilepb.c | 2 +-
 hw/arm/vexpress.c| 2 +-
 hw/arm/virt.c| 2 +-
 hw/arm/xilinx_zynq.c | 2 +-
 hw/arm/xlnx-versal.c | 2 +-
 hw/arm/z2.c  | 2 +-
 49 files changed, 52 insertions(+), 52 deletions(-)
 rename include/hw/arm/{arm.h => boot.h} (98%)

diff --git a/include/hw/arm/allwinner-a10.h b/include/hw/arm/allwinner-a10.h
index 389e128d0fc..6305b9c586f 100644
--- a/include/hw/arm/allwinner-a10.h
+++ b/include/hw/arm/allwinner-a10.h
@@ -3,7 +3,7 @@
 #include "qemu-common.h"
 #include "qemu/error-report.h"
 #include "hw/char/serial.h"
-#include "hw/arm/arm.h"
+#include "hw/arm/boot.h"
 #include "hw/timer/allwinner-a10-pit.h"
 #include "hw/intc/allwinner-a10-pic.h"
 #include "hw/net/allwinner_emac.h"
diff --git a/include/hw/arm/aspeed_soc.h b/include/hw/arm/aspeed_soc.h
index 11ec0179db5..24078fd1895 100644
--- a/include/hw/arm/aspeed_soc.h
+++ b/include/hw/arm/aspeed_soc.h
@@ -12,7 +12,7 @@
 #ifndef ASPEED_SOC_H
 #define ASPEED_SOC_H
 
-#include "hw/arm/arm.h"
+#include "hw/arm/boot.h"
 #include "hw/intc/aspeed_vic.h"
 #include "hw/misc/aspeed_scu.h"
 #include "hw/misc/aspeed_sdmc.h"
diff --git a/include/hw/arm/bcm2836.h b/include/hw/arm/bcm2836.h
index 93248399ba0..1b04a0e7fe8 100644
--- a/include/hw/arm/bcm2836.h
+++ b/include/hw/arm/bcm2836.h
@@ -11,7 +11,7 @@
 #ifndef BCM2836_H
 #define BCM2836_H
 
-#include "hw/arm/arm.h"
+#include "hw/arm/boot.h"
 #include "hw/arm/bcm2835_peripherals.h"
 #include "hw/intc/bcm2836_control.h"
 
diff --git a/include/hw/arm/arm.h b/include/hw/arm/boot.h
similarity index 98%
rename from include/hw/arm/arm.h
rename to include/hw/arm/boot.h
index ba3a9b41422..c48cc4c2bca 100644
--- a/include/hw/arm/arm.h
+++ b/include/hw/arm/boot.h
@@ -1,5 +1,5 @@
 /*
- * Misc ARM declarations
+ * ARM kernel loader.
  *
  * Copyright (c) 2006 CodeSourcery.
  * Written by Paul Brook
@@ -8,8 +8,8 @@
  *
  */
 
-#ifndef HW_ARM_H
-#define HW_ARM_H
+#ifndef HW_ARM_BOOT_H
+#define HW_ARM_BOOT_H
 
 #include "exec/memory.h"
 #include "target/arm/cpu-qom.h"
@@ -167,4 +167,4 @@ void arm_write_secure_board_setup_dummy_smc(ARMCPU *cpu,
 const struct arm_boot_info *info,
 hwaddr mvbar_addr);
 
-#endif /* HW_ARM_H */
+#endif /* HW_ARM_BOOT_H */
diff --git a/include/hw/arm/fsl-imx25.h b/include/hw/arm/fsl-imx25.h
index 65a73714efe..3280ab1fb05 100644
--- a/include/hw/arm/fsl-imx25.h
+++ b/include/hw/arm/fsl-imx25.h
@@ -17,7 +17,7 @@
 #ifndef FSL_IMX25_H
 #define FSL_IMX25_H
 
-#include "hw/arm/arm.h"
+#include "hw/arm/boot.h"
 #include "hw/intc/imx_avic.h"
 #include "hw/misc/imx25_ccm.h"
 #include "hw/char/imx_serial.h"
diff --git a/include/hw/arm/fsl-imx31.h b/include/hw/arm/fsl-imx31.h
index d408abbba0d..e68a81efd75 100644
--- a/include/hw/arm/fsl-imx31.h
+++