From nobody Tue Feb 10 01:35:19 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1618581522; cv=none; d=zohomail.com; s=zohoarc; b=dPnZpgL6T6EoOwYYWjSN2oSPXMcXLk9R9OTUzGeL1fUNJWys3mtOHjWho70VeL1A8EdVFOubY5n/vVXp4+ppdx89HG/Hr7ze3W/xocKDbbdonQ7Y3OKXv0QtU+rV13OtnkhitiHZ54FBfitJr4lzxzsbIWWewveyIzT9an3ruRQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618581522; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=cZehfILUJtGk9HUzuIGzJjH/JKzgTkA2dSQh0622GUc=; b=kbLSiV1nfIFzLQBDbAoto8UJd0mt+RPoz8QawRiruXwx69J0xeDmzO2zjBjJFDDJIs8/OmyMcYvygWnlgAKkA3wa5DDsI7KL1h/l8FeEs9H+Uldi0FZzrS0qWyHJszNiyHbF6IX1gnl24w0dj4ZGSEcOICmWgGS1TzLQLfTXgVY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1618581522022431.95703861176946; Fri, 16 Apr 2021 06:58:42 -0700 (PDT) Received: from localhost ([::1]:36548 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXOzY-0002KC-RY for importer@patchew.org; Fri, 16 Apr 2021 09:58:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37384) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lXOwo-0007HU-1n for qemu-devel@nongnu.org; Fri, 16 Apr 2021 09:55:50 -0400 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]:46689) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lXOwm-0004xz-E0 for qemu-devel@nongnu.org; Fri, 16 Apr 2021 09:55:49 -0400 Received: by mail-wr1-x431.google.com with SMTP id c15so17848138wro.13 for ; Fri, 16 Apr 2021 06:55:48 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id p14sm10686528wrn.49.2021.04.16.06.55.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Apr 2021 06:55:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=cZehfILUJtGk9HUzuIGzJjH/JKzgTkA2dSQh0622GUc=; b=dNXtTYHnny80kgrQ7dz46aEA/bgDs0WX+Vq0PbbQ4bHZkpnaWiLPy+XTPNL+yo2RfB PpfxPfTelVY/1jz7lOhLGHNhy2YaaRJ22vg0CuuwKN4e2lGYgdSR6w2lKQPusgITj+4X mi415NcY3n3ZzJK4a4nXqjkQrLM8KftGlj9fs4oOdMtBT4ik27YgE5VY4ED5rrSSruJu XuBwWtnqo1zMYbX/DuLEtkAs8XEPWZrv2mhhHaBMWPYojtxPzzzFVq01tiQYkVyL3V5G 6m818YdvVj03wm0ZlcKIX4hMzEgXrQX+rRYrcvxLvVfOyB88YhG7ecVy8kUOYIBT+t+U k9ZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=cZehfILUJtGk9HUzuIGzJjH/JKzgTkA2dSQh0622GUc=; b=gJfj1VSxvGoRBScilDn0wyyxs2wWAW7qybxFW40P777IuuAzG9qhHoxLHy5r2mbXRS xSvaB5wq7mL8B69KSqjA9xA31zq6wLCl6HwxJmzdc9R3lst1N0CV+3nffjDRNyh559QZ cChDppyfTa/9mxcfK/Stg6GUPtz+EfQS9AUa2IoCSRJz91egj40qh1QNRJR0Kl3EuTL/ j3nAXsGP1kI1+tXKZix4J/UqXzlSWGfOHRPNk1QfQYmnWMhkDc3QcjSUDyosBXxdhJ5V r7NYaBfOkAux3FXGOzpTx4H8bbQ3LSYvZ9AUbenFjtA63/bvDzU4kfFV9nkgqr2uYEu8 Eczw== X-Gm-Message-State: AOAM530VUxD8ewV/wxR2snd2XsmiY8Q3EoFaaDT0L+hqslIVy+zlt5vU X8kS82FyTXTq+/eppR7KQGQIG2mvWjPqWgmY X-Google-Smtp-Source: ABdhPJw07lkIYGLxJkaLJZHEvfZ+qQGobzUmmTYasx7wG65PjE2GGnneUrncBXpsq5nTFBWDK4t4hA== X-Received: by 2002:a05:6000:178c:: with SMTP id e12mr9318241wrg.42.1618581347192; Fri, 16 Apr 2021 06:55:47 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PATCH for-6.0? 3/6] include/qemu/osdep.h: Move system includes to top Date: Fri, 16 Apr 2021 14:55:40 +0100 Message-Id: <20210416135543.20382-4-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20210416135543.20382-1-peter.maydell@linaro.org> References: <20210416135543.20382-1-peter.maydell@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=peter.maydell@linaro.org; helo=mail-wr1-x431.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , "Daniel P. Berrange" Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) Mostly osdep.h puts the system includes at the top of the file; but there are a couple of exceptions where we include a system header halfway through the file. Move these up to the top with the rest so that all the system headers we include are included before we include os-win32.h or os-posix.h. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Daniel P. Berrang=C3=A9 Message-id: 20210414184343.26235-1-peter.maydell@linaro.org Reviewed-by: Richard Henderson --- include/qemu/osdep.h | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/include/qemu/osdep.h b/include/qemu/osdep.h index 6d8562eaf40..cb2a07e472e 100644 --- a/include/qemu/osdep.h +++ b/include/qemu/osdep.h @@ -104,6 +104,15 @@ QEMU_EXTERN_C int daemon(int, int); #include #include =20 +#ifdef CONFIG_IOVEC +#include +#endif + +#if defined(__linux__) && defined(__sparc__) +/* The SPARC definition of QEMU_VMALLOC_ALIGN needs SHMLBA */ +#include +#endif + #ifndef _WIN32 #include #else @@ -111,6 +120,10 @@ QEMU_EXTERN_C int daemon(int, int); #define WEXITSTATUS(x) (x) #endif =20 +#ifdef __APPLE__ +#include +#endif + /* * This is somewhat like a system header; it must be outside any extern "C" * block because it includes system headers itself, including glib.h, @@ -130,10 +143,6 @@ extern "C" { #include "sysemu/os-posix.h" #endif =20 -#ifdef __APPLE__ -#include -#endif - #include "qemu/typedefs.h" =20 /* @@ -469,7 +478,6 @@ void qemu_anon_ram_free(void *ptr, size_t size); /* Use 1 MiB (segment size) alignment so gmap can be used by KVM. */ # define QEMU_VMALLOC_ALIGN (256 * 4096) #elif defined(__linux__) && defined(__sparc__) -#include # define QEMU_VMALLOC_ALIGN MAX(qemu_real_host_page_size, SHMLBA) #else # define QEMU_VMALLOC_ALIGN qemu_real_host_page_size @@ -549,8 +557,6 @@ struct iovec { =20 ssize_t readv(int fd, const struct iovec *iov, int iov_cnt); ssize_t writev(int fd, const struct iovec *iov, int iov_cnt); -#else -#include #endif =20 #ifdef _WIN32 --=20 2.20.1