From: "Daniel P. Berrange" <berrange@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
qemu-devel@nongnu.org, Markus Armbruster <armbru@redhat.com>,
patches@linaro.org
Subject: Re: [Qemu-devel] [PATCH 2/3] target-arm: Clean up includes
Date: Mon, 11 Jan 2016 15:26:10 +0000 [thread overview]
Message-ID: <20160111152609.GC12607@redhat.com> (raw)
In-Reply-To: <1449505425-32022-3-git-send-email-peter.maydell@linaro.org>
On Mon, Dec 07, 2015 at 04:23:44PM +0000, Peter Maydell wrote:
> 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>
> ---
> target-arm/arm-semi.c | 8 +-------
> target-arm/cpu.c | 1 +
> target-arm/cpu64.c | 1 +
> target-arm/crypto_helper.c | 2 +-
> target-arm/gdbstub.c | 2 +-
> target-arm/gdbstub64.c | 2 +-
> target-arm/helper-a64.c | 1 +
> target-arm/helper.c | 1 +
> target-arm/iwmmxt_helper.c | 3 +--
> target-arm/kvm-stub.c | 1 +
> target-arm/kvm.c | 3 +--
> target-arm/kvm32.c | 3 +--
> target-arm/kvm64.c | 4 +---
> target-arm/machine.c | 1 +
> target-arm/neon_helper.c | 3 +--
> target-arm/op_helper.c | 1 +
> target-arm/psci.c | 1 +
> target-arm/translate-a64.c | 6 +-----
> target-arm/translate.c | 6 +-----
> 19 files changed, 19 insertions(+), 31 deletions(-)
>
> diff --git a/target-arm/arm-semi.c b/target-arm/arm-semi.c
> index d7cff3d..76c33b9 100644
> --- a/target-arm/arm-semi.c
> +++ b/target-arm/arm-semi.c
> @@ -18,13 +18,7 @@
> * along with this program; if not, see <http://www.gnu.org/licenses/>.
> */
>
> -#include <sys/types.h>
> -#include <sys/stat.h>
> -#include <fcntl.h>
> -#include <unistd.h>
> -#include <stdlib.h>
> -#include <stdio.h>
> -#include <time.h>
> +#include "qemu/osdep.h"
>
> #include "cpu.h"
> #include "exec/semihost.h"
> diff --git a/target-arm/cpu.c b/target-arm/cpu.c
> index 30739fc..72cb65f 100644
> --- a/target-arm/cpu.c
> +++ b/target-arm/cpu.c
> @@ -18,6 +18,7 @@
> * <http://www.gnu.org/licenses/gpl-2.0.html>
> */
>
> +#include "qemu/osdep.h"
> #include "cpu.h"
> #include "internals.h"
> #include "qemu-common.h"
> diff --git a/target-arm/cpu64.c b/target-arm/cpu64.c
> index 63c8b1c..5f8a177 100644
> --- a/target-arm/cpu64.c
> +++ b/target-arm/cpu64.c
> @@ -18,6 +18,7 @@
> * <http://www.gnu.org/licenses/gpl-2.0.html>
> */
>
> +#include "qemu/osdep.h"
> #include "cpu.h"
> #include "qemu-common.h"
> #if !defined(CONFIG_USER_ONLY)
> diff --git a/target-arm/crypto_helper.c b/target-arm/crypto_helper.c
> index 5d22838..3b6df3f 100644
> --- a/target-arm/crypto_helper.c
> +++ b/target-arm/crypto_helper.c
> @@ -9,7 +9,7 @@
> * version 2 of the License, or (at your option) any later version.
> */
>
> -#include <stdlib.h>
> +#include "qemu/osdep.h"
>
> #include "cpu.h"
> #include "exec/exec-all.h"
> diff --git a/target-arm/gdbstub.c b/target-arm/gdbstub.c
> index 1c34396..08b91a4 100644
> --- a/target-arm/gdbstub.c
> +++ b/target-arm/gdbstub.c
> @@ -17,7 +17,7 @@
> * You should have received a copy of the GNU Lesser General Public
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
> -#include "config.h"
> +#include "qemu/osdep.h"
> #include "qemu-common.h"
> #include "exec/gdbstub.h"
>
> diff --git a/target-arm/gdbstub64.c b/target-arm/gdbstub64.c
> index 8f3b8d1..634c6bc 100644
> --- a/target-arm/gdbstub64.c
> +++ b/target-arm/gdbstub64.c
> @@ -16,7 +16,7 @@
> * You should have received a copy of the GNU Lesser General Public
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
> -#include "config.h"
> +#include "qemu/osdep.h"
> #include "qemu-common.h"
> #include "exec/gdbstub.h"
>
> diff --git a/target-arm/helper-a64.c b/target-arm/helper-a64.c
> index deb8dbe..c46af93 100644
> --- a/target-arm/helper-a64.c
> +++ b/target-arm/helper-a64.c
> @@ -17,6 +17,7 @@
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
>
> +#include "qemu/osdep.h"
> #include "cpu.h"
> #include "exec/gdbstub.h"
> #include "exec/helper-proto.h"
> diff --git a/target-arm/helper.c b/target-arm/helper.c
> index afc4163..18d60ff 100644
> --- a/target-arm/helper.c
> +++ b/target-arm/helper.c
> @@ -1,3 +1,4 @@
> +#include "qemu/osdep.h"
> #include "cpu.h"
> #include "internals.h"
> #include "exec/gdbstub.h"
> diff --git a/target-arm/iwmmxt_helper.c b/target-arm/iwmmxt_helper.c
> index a506914..7d87e1a 100644
> --- a/target-arm/iwmmxt_helper.c
> +++ b/target-arm/iwmmxt_helper.c
> @@ -19,8 +19,7 @@
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
>
> -#include <stdlib.h>
> -#include <stdio.h>
> +#include "qemu/osdep.h"
>
> #include "cpu.h"
> #include "exec/exec-all.h"
> diff --git a/target-arm/kvm-stub.c b/target-arm/kvm-stub.c
> index db2edc2..38bf433 100644
> --- a/target-arm/kvm-stub.c
> +++ b/target-arm/kvm-stub.c
> @@ -9,6 +9,7 @@
> * See the COPYING file in the top-level directory.
> *
> */
> +#include "qemu/osdep.h"
> #include "qemu-common.h"
> #include "kvm_arm.h"
>
> diff --git a/target-arm/kvm.c b/target-arm/kvm.c
> index 79ef4c6..c1c5584 100644
> --- a/target-arm/kvm.c
> +++ b/target-arm/kvm.c
> @@ -8,8 +8,7 @@
> *
> */
>
> -#include <stdio.h>
> -#include <sys/types.h>
> +#include "qemu/osdep.h"
> #include <sys/ioctl.h>
> #include <sys/mman.h>
>
> diff --git a/target-arm/kvm32.c b/target-arm/kvm32.c
> index df1e2b0..646ba41 100644
> --- a/target-arm/kvm32.c
> +++ b/target-arm/kvm32.c
> @@ -8,8 +8,7 @@
> *
> */
>
> -#include <stdio.h>
> -#include <sys/types.h>
> +#include "qemu/osdep.h"
> #include <sys/ioctl.h>
> #include <sys/mman.h>
>
> diff --git a/target-arm/kvm64.c b/target-arm/kvm64.c
> index ceebfeb..d409259 100644
> --- a/target-arm/kvm64.c
> +++ b/target-arm/kvm64.c
> @@ -8,14 +8,12 @@
> *
> */
>
> -#include <stdio.h>
> -#include <sys/types.h>
> +#include "qemu/osdep.h"
> #include <sys/ioctl.h>
> #include <sys/mman.h>
>
> #include <linux/kvm.h>
>
> -#include "config-host.h"
> #include "qemu-common.h"
> #include "qemu/timer.h"
> #include "sysemu/sysemu.h"
> diff --git a/target-arm/machine.c b/target-arm/machine.c
> index 36a0d15..97cbfe3 100644
> --- a/target-arm/machine.c
> +++ b/target-arm/machine.c
> @@ -1,3 +1,4 @@
> +#include "qemu/osdep.h"
> #include "hw/hw.h"
> #include "hw/boards.h"
> #include "qemu/error-report.h"
> diff --git a/target-arm/neon_helper.c b/target-arm/neon_helper.c
> index 47d13e9..1f1844f 100644
> --- a/target-arm/neon_helper.c
> +++ b/target-arm/neon_helper.c
> @@ -6,8 +6,7 @@
> *
> * This code is licensed under the GNU GPL v2.
> */
> -#include <stdlib.h>
> -#include <stdio.h>
> +#include "qemu/osdep.h"
>
> #include "cpu.h"
> #include "exec/exec-all.h"
> diff --git a/target-arm/op_helper.c b/target-arm/op_helper.c
> index 6cd54c8..af5a783 100644
> --- a/target-arm/op_helper.c
> +++ b/target-arm/op_helper.c
> @@ -16,6 +16,7 @@
> * You should have received a copy of the GNU Lesser General Public
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
> +#include "qemu/osdep.h"
> #include "cpu.h"
> #include "exec/helper-proto.h"
> #include "internals.h"
> diff --git a/target-arm/psci.c b/target-arm/psci.c
> index 20e4cb6..c55487f 100644
> --- a/target-arm/psci.c
> +++ b/target-arm/psci.c
> @@ -15,6 +15,7 @@
> * 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 "qemu/osdep.h"
> #include <cpu.h>
> #include <cpu-qom.h>
> #include <exec/helper-proto.h>
> diff --git a/target-arm/translate-a64.c b/target-arm/translate-a64.c
> index 14e8131..80f6c20 100644
> --- a/target-arm/translate-a64.c
> +++ b/target-arm/translate-a64.c
> @@ -16,11 +16,7 @@
> * You should have received a copy of the GNU Lesser General Public
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
> -#include <stdarg.h>
> -#include <stdlib.h>
> -#include <stdio.h>
> -#include <string.h>
> -#include <inttypes.h>
> +#include "qemu/osdep.h"
>
> #include "cpu.h"
> #include "tcg-op.h"
> diff --git a/target-arm/translate.c b/target-arm/translate.c
> index 5d22879..48884ab 100644
> --- a/target-arm/translate.c
> +++ b/target-arm/translate.c
> @@ -18,11 +18,7 @@
> * You should have received a copy of the GNU Lesser General Public
> * License along with this library; if not, see <http://www.gnu.org/licenses/>.
> */
> -#include <stdarg.h>
> -#include <stdlib.h>
> -#include <stdio.h>
> -#include <string.h>
> -#include <inttypes.h>
> +#include "qemu/osdep.h"
>
> #include "cpu.h"
> #include "internals.h"
> --
Looks like the script is producing sane results
Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
next prev parent reply other threads:[~2016-01-11 15:26 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-07 16:23 [Qemu-devel] [PATCH 0/3] clean-includes script to add osdep.h to everything Peter Maydell
2015-12-07 16:23 ` [Qemu-devel] [PATCH 1/3] scripts: Add new clean-includes script to fix C include directives Peter Maydell
2016-01-11 15:23 ` Daniel P. Berrange
2015-12-07 16:23 ` [Qemu-devel] [PATCH 2/3] target-arm: Clean up includes Peter Maydell
2016-01-11 15:26 ` Daniel P. Berrange [this message]
2015-12-07 16:23 ` [Qemu-devel] [PATCH 3/3] hw/arm: " Peter Maydell
2016-01-11 13:08 ` [Qemu-devel] [PATCH 0/3] clean-includes script to add osdep.h to everything Peter Maydell
2016-01-11 15:19 ` Daniel P. Berrange
2016-01-18 16:33 ` Peter Maydell
2016-01-18 17:08 ` Peter Maydell
2016-01-19 7:27 ` Markus Armbruster
2016-01-19 8:46 ` Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160111152609.GC12607@redhat.com \
--to=berrange@redhat.com \
--cc=armbru@redhat.com \
--cc=patches@linaro.org \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.