From patchwork Wed Jan 31 14:48:28 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markus Armbruster X-Patchwork-Id: 10194077 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C76C3603EE for ; Wed, 31 Jan 2018 14:50:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B7EFA28672 for ; Wed, 31 Jan 2018 14:50:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AADD02871B; Wed, 31 Jan 2018 14:50:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8BD0528712 for ; Wed, 31 Jan 2018 14:50:28 +0000 (UTC) Received: from localhost ([::1]:36924 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1egtiV-0001OZ-19 for patchwork-qemu-devel@patchwork.kernel.org; Wed, 31 Jan 2018 09:50:27 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50814) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1egth0-0008Tr-0f for qemu-devel@nongnu.org; Wed, 31 Jan 2018 09:48:56 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1egtgx-0003cO-F0 for qemu-devel@nongnu.org; Wed, 31 Jan 2018 09:48:54 -0500 Received: from mx1.redhat.com ([209.132.183.28]:43640) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1egtgx-0003ba-7Q for qemu-devel@nongnu.org; Wed, 31 Jan 2018 09:48:51 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 638552D1C6; Wed, 31 Jan 2018 14:48:50 +0000 (UTC) Received: from blackfin.pond.sub.org (ovpn-116-148.ams2.redhat.com [10.36.116.148]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 54D4461348; Wed, 31 Jan 2018 14:48:48 +0000 (UTC) Received: by blackfin.pond.sub.org (Postfix, from userid 1000) id 900FF1138646; Wed, 31 Jan 2018 15:48:46 +0100 (CET) From: Markus Armbruster To: qemu-devel@nongnu.org Date: Wed, 31 Jan 2018 15:48:28 +0100 Message-Id: <20180131144846.31697-2-armbru@redhat.com> In-Reply-To: <20180131144846.31697-1-armbru@redhat.com> References: <20180131144846.31697-1-armbru@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Wed, 31 Jan 2018 14:48:50 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH v2 01/19] Use #include "..." for our own headers, <...> for others X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: f4bug@amsat.org Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP System headers should be included with <...>, our own headers with "...". Offenders tracked down with an ugly, brittle and probably buggy Perl script. Previous iteration was commit a9c94277f0. Put the cleaned up system header includes first, except for the ones the next commit will delete. While there, separate #include from file comment with a blank line, Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake Reviewed-by: Thomas Huth --- contrib/vhost-user-scsi/vhost-user-scsi.c | 4 ++-- hw/ide/sii3112.c | 4 ++-- hw/s390x/s390-ccw.c | 3 ++- include/hw/loader-fit.h | 2 +- include/hw/registerfields.h | 2 +- include/hw/s390x/storage-attributes.h | 2 +- target/i386/hax-all.c | 2 +- target/i386/hvf/hvf.c | 2 +- target/i386/hvf/x86_decode.c | 2 +- target/i386/hvf/x86_mmu.c | 7 +++---- target/i386/hvf/x86_task.c | 2 +- target/s390x/gen-features.c | 4 ++-- target/xtensa/core-dc232b/xtensa-modules.c | 2 +- target/xtensa/core-dc233c/xtensa-modules.c | 2 +- target/xtensa/core-de212/xtensa-modules.c | 2 +- target/xtensa/core-fsf/xtensa-modules.c | 2 +- target/xtensa/core-sample_controller/xtensa-modules.c | 2 +- target/xtensa/xtensa-isa.h | 2 +- vl.c | 2 +- 19 files changed, 25 insertions(+), 25 deletions(-) diff --git a/contrib/vhost-user-scsi/vhost-user-scsi.c b/contrib/vhost-user-scsi/vhost-user-scsi.c index 54c1191db0..02c29019d1 100644 --- a/contrib/vhost-user-scsi/vhost-user-scsi.c +++ b/contrib/vhost-user-scsi/vhost-user-scsi.c @@ -11,10 +11,10 @@ */ #include "qemu/osdep.h" +#include +#include #include "contrib/libvhost-user/libvhost-user-glib.h" #include "standard-headers/linux/virtio_scsi.h" -#include "iscsi/iscsi.h" -#include "iscsi/scsi-lowlevel.h" #include diff --git a/hw/ide/sii3112.c b/hw/ide/sii3112.c index 17aa930e39..e3896c65b4 100644 --- a/hw/ide/sii3112.c +++ b/hw/ide/sii3112.c @@ -12,8 +12,8 @@ * http://wiki.osdev.org/User:Quok/Silicon_Image_Datasheets */ -#include -#include +#include "qemu/osdep.h" +#include "hw/ide/pci.h" #include "trace.h" #define TYPE_SII3112_PCI "sii3112" diff --git a/hw/s390x/s390-ccw.c b/hw/s390x/s390-ccw.c index 4a9d4d2534..7fc1c603c0 100644 --- a/hw/s390x/s390-ccw.c +++ b/hw/s390x/s390-ccw.c @@ -10,10 +10,11 @@ * or (at your option) any later version. See the COPYING file in the * top-level directory. */ + #include "qemu/osdep.h" +#include #include "qapi/error.h" #include "hw/sysbus.h" -#include "libgen.h" #include "hw/s390x/css.h" #include "hw/s390x/css-bridge.h" #include "hw/s390x/s390-ccw.h" diff --git a/include/hw/loader-fit.h b/include/hw/loader-fit.h index 9e2a068a20..0284c3e02c 100644 --- a/include/hw/loader-fit.h +++ b/include/hw/loader-fit.h @@ -20,7 +20,7 @@ #ifndef HW_LOADER_FIT_H #define HW_LOADER_FIT_H -#include +#include "exec/hwaddr.h" struct fit_loader_match { const char *compatible; diff --git a/include/hw/registerfields.h b/include/hw/registerfields.h index 44e0b94edf..2659a58737 100644 --- a/include/hw/registerfields.h +++ b/include/hw/registerfields.h @@ -11,7 +11,7 @@ #ifndef REGISTERFIELDS_H #define REGISTERFIELDS_H -#include +#include "qemu/bitops.h" /* Define constants for a 32 bit register */ diff --git a/include/hw/s390x/storage-attributes.h b/include/hw/s390x/storage-attributes.h index 9be954d163..d6403a0a7e 100644 --- a/include/hw/s390x/storage-attributes.h +++ b/include/hw/s390x/storage-attributes.h @@ -12,7 +12,7 @@ #ifndef S390_STORAGE_ATTRIBUTES_H #define S390_STORAGE_ATTRIBUTES_H -#include +#include "hw/qdev.h" #include "monitor/monitor.h" #define TYPE_S390_STATTRIB "s390-storage_attributes" diff --git a/target/i386/hax-all.c b/target/i386/hax-all.c index 934ec4afd1..6874018738 100644 --- a/target/i386/hax-all.c +++ b/target/i386/hax-all.c @@ -30,7 +30,7 @@ #include "exec/ioport.h" #include "qemu-common.h" -#include "strings.h" +#include #include "hax-i386.h" #include "sysemu/accel.h" #include "sysemu/sysemu.h" diff --git a/target/i386/hvf/hvf.c b/target/i386/hvf/hvf.c index 010866ed22..5d00c58129 100644 --- a/target/i386/hvf/hvf.c +++ b/target/i386/hvf/hvf.c @@ -43,7 +43,7 @@ #include "hw/i386/apic_internal.h" #include "hw/boards.h" #include "qemu/main-loop.h" -#include "strings.h" +#include #include "sysemu/accel.h" #include "sysemu/sysemu.h" #include "target/i386/cpu.h" diff --git a/target/i386/hvf/x86_decode.c b/target/i386/hvf/x86_decode.c index bf93e8207d..dcff2073a7 100644 --- a/target/i386/hvf/x86_decode.c +++ b/target/i386/hvf/x86_decode.c @@ -21,7 +21,7 @@ #include "qemu-common.h" #include "panic.h" #include "x86_decode.h" -#include "string.h" +#include #include "vmx.h" #include "x86_mmu.h" #include "x86_descr.h" diff --git a/target/i386/hvf/x86_mmu.c b/target/i386/hvf/x86_mmu.c index 5c1f35acd0..2ad8fcdf70 100644 --- a/target/i386/hvf/x86_mmu.c +++ b/target/i386/hvf/x86_mmu.c @@ -15,18 +15,17 @@ * You should have received a copy of the GNU Lesser General Public * License along with this program; if not, see . */ + #include "qemu/osdep.h" +#include #include "panic.h" - #include "qemu-common.h" #include "cpu.h" #include "x86.h" #include "x86_mmu.h" -#include "string.h" +#include #include "vmcs.h" #include "vmx.h" - -#include "memory.h" #include "exec/address-spaces.h" #define pte_present(pte) (pte & PT_PRESENT) diff --git a/target/i386/hvf/x86_task.c b/target/i386/hvf/x86_task.c index d7f665f8fa..452fad6b2d 100644 --- a/target/i386/hvf/x86_task.c +++ b/target/i386/hvf/x86_task.c @@ -32,7 +32,7 @@ #include "hw/i386/apic_internal.h" #include "hw/boards.h" #include "qemu/main-loop.h" -#include "strings.h" +#include #include "sysemu/accel.h" #include "sysemu/sysemu.h" #include "target/i386/cpu.h" diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c index 0570f597ec..9968974fbe 100644 --- a/target/s390x/gen-features.c +++ b/target/s390x/gen-features.c @@ -13,8 +13,8 @@ */ -#include "inttypes.h" -#include "stdio.h" +#include +#include #include "cpu_features_def.h" #define ARRAY_SIZE(array) (sizeof(array) / sizeof(array[0])) diff --git a/target/xtensa/core-dc232b/xtensa-modules.c b/target/xtensa/core-dc232b/xtensa-modules.c index 2e103cd2f5..0af43c84bb 100644 --- a/target/xtensa/core-dc232b/xtensa-modules.c +++ b/target/xtensa/core-dc232b/xtensa-modules.c @@ -18,7 +18,7 @@ Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ -#include +#include "xtensa-isa.h" #include "xtensa-isa-internal.h" diff --git a/target/xtensa/core-dc233c/xtensa-modules.c b/target/xtensa/core-dc233c/xtensa-modules.c index 2728311c9a..8a41e73659 100644 --- a/target/xtensa/core-dc233c/xtensa-modules.c +++ b/target/xtensa/core-dc233c/xtensa-modules.c @@ -21,7 +21,7 @@ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -#include +#include "xtensa-isa.h" #include "xtensa-isa-internal.h" diff --git a/target/xtensa/core-de212/xtensa-modules.c b/target/xtensa/core-de212/xtensa-modules.c index 4a8735889e..21f3bd8797 100644 --- a/target/xtensa/core-de212/xtensa-modules.c +++ b/target/xtensa/core-de212/xtensa-modules.c @@ -21,7 +21,7 @@ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -#include +#include "xtensa-isa.h" #include "xtensa-isa-internal.h" diff --git a/target/xtensa/core-fsf/xtensa-modules.c b/target/xtensa/core-fsf/xtensa-modules.c index 238800d823..9621f5142a 100644 --- a/target/xtensa/core-fsf/xtensa-modules.c +++ b/target/xtensa/core-fsf/xtensa-modules.c @@ -18,7 +18,7 @@ Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ -#include +#include "xtensa-isa.h" #include "xtensa-isa-internal.h" diff --git a/target/xtensa/core-sample_controller/xtensa-modules.c b/target/xtensa/core-sample_controller/xtensa-modules.c index 2f000199b8..39810e532a 100644 --- a/target/xtensa/core-sample_controller/xtensa-modules.c +++ b/target/xtensa/core-sample_controller/xtensa-modules.c @@ -21,7 +21,7 @@ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -#include +#include "xtensa-isa.h" #include "xtensa-isa-internal.h" diff --git a/target/xtensa/xtensa-isa.h b/target/xtensa/xtensa-isa.h index d06614c187..0f0211f841 100644 --- a/target/xtensa/xtensa-isa.h +++ b/target/xtensa/xtensa-isa.h @@ -1 +1 @@ -#include +#include "hw/xtensa/xtensa-isa.h" diff --git a/vl.c b/vl.c index e517a8d995..d7e4d97814 100644 --- a/vl.c +++ b/vl.c @@ -28,8 +28,8 @@ #include "qemu/uuid.h" #ifdef CONFIG_SECCOMP +#include #include "sysemu/seccomp.h" -#include "sys/prctl.h" #endif #ifdef CONFIG_SDL