From patchwork Tue Jun 28 04:53:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 585504 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:5036:0:0:0:0 with SMTP id e22csp452484mab; Mon, 27 Jun 2022 22:54:16 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sN6/r94PvmA5UisHC0yrI0BD0tfWPoPmJXwXU6hrqI1pJ0DyaXmQqvgUWBln5+e7hAFd33 X-Received: by 2002:a05:620a:172b:b0:6a7:61b:9bbb with SMTP id az43-20020a05620a172b00b006a7061b9bbbmr10347620qkb.23.1656395656546; Mon, 27 Jun 2022 22:54:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656395656; cv=none; d=google.com; s=arc-20160816; b=AlOUkR1IYpR2GiqzVm49t8WwlF49L8AXeQkQ3BNAdYenW5yb+S9x7H6+xXkLxqYJge KpzQruBZZt36FTZupcX738Xw/Vl3i5dG4hy4AhY2fpHWJi6LBNw013r1QVjQXYC2wKre xww+KSaAzxCg5MBpImRlTU0meiZL1aKQp6/nZJS6jRZ2MXlQ8QKL8OFd3XWxC6kxCRXl i+xjtyUwhsd1eFbIZjfeYLKSe8Pb7CsdEuQhXAZUAVJHZl/6Z86eY1haIpqPsiZxPReU RKswyi8OMjfIj0ag90Os2CVt09m/wE2bUa0wbtQpnYdgX3EUL4+OBGT/zrMGSKsz72Dp EY0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=hL15phHiFTEeYUryTllbE9QTsXahphlhPjpE5IcwyII=; b=bBy33uLf3vkbM7eBWB32AVW/9MylSXj4RoqDxtcFGLTeXG3z67y9nLQHwScYgvLrCv 2RAqkCQX80nWfIDE0CDnHFnF0Fl/R2lDF7m8hrBs3JAnX+nvmuVrj0HveL7NyZf+Lxqh h4Ehzw+Ah667Oq/J79u/JspfAUaBnJsmObjJu2Ihqw3kK6xkmel7gmm5jFY9zXhKV/aD OuxccYLv5267UbSLrVhuzaT98qDPxjegjOzjGTHvtj3uVxUkala9KW1B/CahQlgI8JAJ 2OvAordwOampS/zyG5G8sBqAMmac1nEhdvKBqUU7P8C/y9NAWOCjBZiQxe+yT1iW2Wq3 lesA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ObaKWAu+; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 3-20020a0562140d4300b004726e3e3f0csi2072647qvr.558.2022.06.27.22.54.16 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 27 Jun 2022 22:54:16 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ObaKWAu+; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:35866 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o64Ay-0003fT-2L for patch@linaro.org; Tue, 28 Jun 2022 01:54:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42990) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o63Es-00028p-Io for qemu-devel@nongnu.org; Tue, 28 Jun 2022 00:54:15 -0400 Received: from mail-pj1-x102b.google.com ([2607:f8b0:4864:20::102b]:41800) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o63Eq-0008Fs-TZ for qemu-devel@nongnu.org; Tue, 28 Jun 2022 00:54:14 -0400 Received: by mail-pj1-x102b.google.com with SMTP id g10-20020a17090a708a00b001ea8aadd42bso11520430pjk.0 for ; Mon, 27 Jun 2022 21:54:11 -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=hL15phHiFTEeYUryTllbE9QTsXahphlhPjpE5IcwyII=; b=ObaKWAu++fvAwBnmA9sCc/E7V3/ILjNLMnBfEWlh+RPBOqz2rLfOpnO7EIs8cb3vta vLd0TE9nqaI9rO1hV4jP7M+a10rPe6tVXWDb0PZpjcpyhMklLrIMBvOiZXZXG3qmV6rj L96jSlab4MHHZbgh10gAS7MfINWKNTjAjiw3uHLR27TZ9t6qAZ37PGfEBusF1ZpCvNJZ ZokBonRn0UqQKA0sw2RtsWdkhkYoC8VgNNvatexjqnOfsbAXIWQXfsS7gveTLPAh3V7x 4gRRLlFyVd2xCux581nHBmfCQMftsE/7fkStliwzWmJpFUjXzQjg7HRwhTIQYkxKT3MS He/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hL15phHiFTEeYUryTllbE9QTsXahphlhPjpE5IcwyII=; b=z7gBXdPw2TFXb3Lqm5HSQhfKnjtHvcJ+00BINw8XuvupBatxg0b1aAI0GjklYwfV5G iwu2ejrRhTm/qpw2kmdVDd2dPj7WXjrHpA1oMLDu076rbWRH/kNddg2fqwpjIH/Jzud7 QV906CydW8xe+z+ptGCYOWQfIFuOGpCMzcy/wHpUVetJUB6kV1tnkepUHYhwKtZ4nACV Vqn31X9L0j4vplUnDGLxUB+AoNKvbUVISei+MfB8WxhdV3Qp8LXQbbgwtsle7aZCd1/E dsiLsMreL+pTSeJtvVEd9tf1aZeBexPtfBb60rRFTRMutvsAho9xUdkzwdYCyMeaPkbi b0vQ== X-Gm-Message-State: AJIora8vsMBk3uCzQJHhKlN+E3xbMf96CY/bfHeZ1ZCXE+PnKron94+w 8dfocODmSpqR1aYbWP3cyN2yziwaqWHwFw== X-Received: by 2002:a17:902:d4c8:b0:16a:480b:b79c with SMTP id o8-20020a170902d4c800b0016a480bb79cmr3065266plg.15.1656392050939; Mon, 27 Jun 2022 21:54:10 -0700 (PDT) Received: from stoup.. ([122.255.60.245]) by smtp.gmail.com with ESMTPSA id w8-20020a1709026f0800b00168c523032fsm8073735plk.269.2022.06.27.21.54.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 Jun 2022 21:54:10 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Peter Maydell Subject: [PULL 01/60] semihosting: Move exec/softmmu-semi.h to semihosting/softmmu-uaccess.h Date: Tue, 28 Jun 2022 10:23:04 +0530 Message-Id: <20220628045403.508716-2-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220628045403.508716-1-richard.henderson@linaro.org> References: <20220628045403.508716-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::102b; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x102b.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, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We have a subdirectory for semihosting; move this file out of exec. Rename to emphasize the contents are a replacement for the functions in linux-user/bsd-user uaccess.c. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- .../{exec/softmmu-semi.h => semihosting/softmmu-uaccess.h} | 6 +++--- semihosting/arm-compat-semi.c | 2 +- target/m68k/m68k-semi.c | 2 +- target/mips/tcg/sysemu/mips-semi.c | 2 +- target/nios2/nios2-semi.c | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) rename include/{exec/softmmu-semi.h => semihosting/softmmu-uaccess.h} (95%) diff --git a/include/exec/softmmu-semi.h b/include/semihosting/softmmu-uaccess.h similarity index 95% rename from include/exec/softmmu-semi.h rename to include/semihosting/softmmu-uaccess.h index fbcae88f4b..e69e3c8548 100644 --- a/include/exec/softmmu-semi.h +++ b/include/semihosting/softmmu-uaccess.h @@ -7,8 +7,8 @@ * This code is licensed under the GPL */ -#ifndef SOFTMMU_SEMI_H -#define SOFTMMU_SEMI_H +#ifndef SEMIHOSTING_SOFTMMU_UACCESS_H +#define SEMIHOSTING_SOFTMMU_UACCESS_H #include "cpu.h" @@ -98,4 +98,4 @@ static void softmmu_unlock_user(CPUArchState *env, void *p, target_ulong addr, } #define unlock_user(s, args, len) softmmu_unlock_user(env, s, args, len) -#endif +#endif /* SEMIHOSTING_SOFTMMU_UACCESS_H */ diff --git a/semihosting/arm-compat-semi.c b/semihosting/arm-compat-semi.c index b6ddaf863a..1033e751ef 100644 --- a/semihosting/arm-compat-semi.c +++ b/semihosting/arm-compat-semi.c @@ -370,7 +370,7 @@ static GuestFD *get_guestfd(int guestfd) #ifndef CONFIG_USER_ONLY static target_ulong syscall_err; -#include "exec/softmmu-semi.h" +#include "semihosting/softmmu-uaccess.h" #endif static inline uint32_t set_swi_errno(CPUState *cs, uint32_t code) diff --git a/target/m68k/m68k-semi.c b/target/m68k/m68k-semi.c index 37343d47e2..a31db38fc3 100644 --- a/target/m68k/m68k-semi.c +++ b/target/m68k/m68k-semi.c @@ -25,7 +25,7 @@ #include "qemu.h" #define SEMIHOSTING_HEAP_SIZE (128 * 1024 * 1024) #else -#include "exec/softmmu-semi.h" +#include "semihosting/softmmu-uaccess.h" #include "hw/boards.h" #endif #include "qemu/log.h" diff --git a/target/mips/tcg/sysemu/mips-semi.c b/target/mips/tcg/sysemu/mips-semi.c index b4a383ae90..6d6296e709 100644 --- a/target/mips/tcg/sysemu/mips-semi.c +++ b/target/mips/tcg/sysemu/mips-semi.c @@ -21,7 +21,7 @@ #include "cpu.h" #include "qemu/log.h" #include "exec/helper-proto.h" -#include "exec/softmmu-semi.h" +#include "semihosting/softmmu-uaccess.h" #include "semihosting/semihost.h" #include "semihosting/console.h" diff --git a/target/nios2/nios2-semi.c b/target/nios2/nios2-semi.c index ec88474a73..373e6b9436 100644 --- a/target/nios2/nios2-semi.c +++ b/target/nios2/nios2-semi.c @@ -28,7 +28,7 @@ #if defined(CONFIG_USER_ONLY) #include "qemu.h" #else -#include "exec/softmmu-semi.h" +#include "semihosting/softmmu-uaccess.h" #endif #include "qemu/log.h"