From patchwork Fri Jun 30 13:21:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 697936 Delivered-To: patch@linaro.org Received: by 2002:adf:fcc5:0:0:0:0:0 with SMTP id f5csp450090wrs; Fri, 30 Jun 2023 06:23:26 -0700 (PDT) X-Google-Smtp-Source: APBJJlFNSxj/HQjYYp+wjk64GjGEgW+NIFiYm089g2WtXUFVvG0WsehHNWLaJdlZSY8ODJn0qUqx X-Received: by 2002:a05:620a:25d1:b0:765:5ba6:a5ce with SMTP id y17-20020a05620a25d100b007655ba6a5cemr2395458qko.45.1688131406029; Fri, 30 Jun 2023 06:23:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688131406; cv=none; d=google.com; s=arc-20160816; b=Pdrl6qJTiJXmVd+iEJ8grkdvOJZUCCsETzuZRJ8G/iGrKYpKwCxGd0+qycMGFifb+7 aW2KaTUlK25jwcPArrobgAvx0Ohoq6omEbR8tPZTPt6TKkENChl3QV/Rr0uT3G3Wvnvh cWZfvvP5lsMDFYhqQLIkXu+k0SYqu/8kXWInnJjg0Je3qQPbzo9XiBWtrkUmg1aY5TQw JYxMPQMJXih6x5hP37WLXvbHfPj6y6Y8Xz+MiBTYALV5sysmw6rBsQif5mXNcnkUcet5 UpARxUqnoNpj91T323mbaeh4z6PqW43+8ge1ALo20780uVlRPGjyiFX0EzXZNL/jJurB ZnvA== 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=eRhCAakrEPIhhwkjbQqX6qZEbetcXESvazfsDHoPFvs=; fh=6bnXD+ip8BuPvzTWf97csbR5QVhpZvBV1AID0n9STS8=; b=JrRtgQ6ucZfKjRLPZuHgktLp7BiyfIRb3QBkuJ3m+nU3M8tJyj55nVMsup4+KQlv/5 zlCsFFkL9C7B1N+cS2n6yEGuEvuYNjFCxRyjl8FEUXHxVuMCG0Wj8M4daFcQqb+yV6DC 6CR13VRL68bchyoWsGZYZrvwo4lTwmXO+ts6PDFbQYI9x0ER0Fx/etO92TO+ZWw1wkrp iwNpnDDQ/LD8aGvrc96Q68IkkOEhVjlRidFf71pcuztf1JvuOsFzyJTNkYQXS6zfI/jO LTlcd2n1zPLtSg8BvPHLmOhiEARzgQ5DtnZWNoXkA7Xt6pKV5TlQBWMjZqJ3LggMyZM+ g2Bg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RMz1tbrS; 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 m6-20020a05620a214600b007463cdd2a59si3800588qkm.675.2023.06.30.06.23.25 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 30 Jun 2023 06:23:26 -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=RMz1tbrS; 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] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qFE4f-0007bW-V0; Fri, 30 Jun 2023 09:22:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qFE4f-0007ax-27 for qemu-devel@nongnu.org; Fri, 30 Jun 2023 09:22:09 -0400 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qFE4c-0003Mi-Hj for qemu-devel@nongnu.org; Fri, 30 Jun 2023 09:22:08 -0400 Received: by mail-wr1-x432.google.com with SMTP id ffacd0b85a97d-313e34ab99fso2025410f8f.1 for ; Fri, 30 Jun 2023 06:22:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1688131325; x=1690723325; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=eRhCAakrEPIhhwkjbQqX6qZEbetcXESvazfsDHoPFvs=; b=RMz1tbrSPx1JOTe3Klwj+xUvY4wBZJaFu8Hvrlq00ABSgLVY3Zh+DNwluYtuHJ3+iU RfaTL3oUzvKuzLQJMEHZNv1MmvnVIw5QJD1JiVHqDvQNx1+GzdU7BZYRvcZGJCz1TUCr iAq04tLs9af1G1ryJFOvlElv2xnqKse4qKsDF/YPqtXqXKMNfLZaF+vsXG1y/tJR+Ca7 LLsgGh4n4xHVuQ5LDKeVupv5BKGaDeg4dOnyOaDyqwTCWnSTwVODXx2C8OPKtl2GvDht 8tL89/yu81dOyipPcp//ehMkED/2wt8CNBeiGQawsJ03i+UJijOeydiqI7zinRmCiCXz QGHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688131325; x=1690723325; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=eRhCAakrEPIhhwkjbQqX6qZEbetcXESvazfsDHoPFvs=; b=LWnbBYlN+yF19xiD+qh7BDOUh2LwYMNzBEZ5wRItadqL0LIPaZU6Po8xQ4iBGIwzPD KTeL7W3C84Y3K/fsBJFukvgEDoINhCkF6AJGjabLVv7H4mMAgxGMVtZHM6dNG3X1RS+B /IpF7WL7nRl5QHYmFtj03xxBhUeVESb0qhNFTWWBSGvbkpT74Rt3O05SkxEXNODbx/ww Lp4XTxmp3EwhWxCjZwniVp4NXpVj1DrBxNvbbsIhJF4GXzwcHHGu31POSkAqzmOdE+aP Sxz6Jmu/MU5tOgU3s7TqYS639q/vw2H6oZpYACc2xFsZJ+3wx/KWcJQkZTiZhrKxNRbJ /Nww== X-Gm-Message-State: ABy/qLZaUWBTpFWLGv7oxh1Lb4nIWIH8cQsmxjUSHwQkLq/zaegqAYZF EF9TYHnJeuNEC/Tr0R7xitvj206mgUFf6pugM8OReQ== X-Received: by 2002:adf:ead2:0:b0:30d:d85c:4472 with SMTP id o18-20020adfead2000000b0030dd85c4472mr1954864wrn.62.1688131324899; Fri, 30 Jun 2023 06:22:04 -0700 (PDT) Received: from localhost.localdomain ([139.47.41.96]) by smtp.gmail.com with ESMTPSA id a16-20020adfdd10000000b00313ef2150dcsm14571092wrm.45.2023.06.30.06.22.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Jun 2023 06:22:04 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: mjt@tls.msk.ru, laurent@vivier.eu Subject: [PATCH 05/24] linux-user: Split TARGET_PROT_* out of syscall_defs.h Date: Fri, 30 Jun 2023 15:21:40 +0200 Message-Id: <20230630132159.376995-6-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230630132159.376995-1-richard.henderson@linaro.org> References: <20230630132159.376995-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=richard.henderson@linaro.org; helo=mail-wr1-x432.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-bounces+patch=linaro.org@nongnu.org Move the values into the per-target target_mman.h headers Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- linux-user/aarch64/target_mman.h | 3 +++ linux-user/generic/target_mman.h | 4 ++++ linux-user/mips/target_mman.h | 2 ++ linux-user/syscall_defs.h | 11 ----------- linux-user/xtensa/target_mman.h | 2 ++ 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/linux-user/aarch64/target_mman.h b/linux-user/aarch64/target_mman.h index e7ba6070fe..7f15cab25e 100644 --- a/linux-user/aarch64/target_mman.h +++ b/linux-user/aarch64/target_mman.h @@ -1 +1,4 @@ +#define TARGET_PROT_BTI 0x10 +#define TARGET_PROT_MTE 0x20 + #include "../generic/target_mman.h" diff --git a/linux-user/generic/target_mman.h b/linux-user/generic/target_mman.h index 7b888fb7f8..39a650e751 100644 --- a/linux-user/generic/target_mman.h +++ b/linux-user/generic/target_mman.h @@ -1,6 +1,10 @@ #ifndef LINUX_USER_TARGET_MMAN_H #define LINUX_USER_TARGET_MMAN_H +#ifndef TARGET_PROT_SEM +#define TARGET_PROT_SEM 0x08 +#endif + /* These are defined in linux/mmap.h */ #define TARGET_MAP_SHARED 0x01 #define TARGET_MAP_PRIVATE 0x02 diff --git a/linux-user/mips/target_mman.h b/linux-user/mips/target_mman.h index d1d96decf5..e9f3905a52 100644 --- a/linux-user/mips/target_mman.h +++ b/linux-user/mips/target_mman.h @@ -1,3 +1,5 @@ +#define TARGET_PROT_SEM 0x10 + #define TARGET_MAP_NORESERVE 0x0400 #define TARGET_MAP_ANONYMOUS 0x0800 #define TARGET_MAP_GROWSDOWN 0x1000 diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h index 118a8ac7da..9387ed422d 100644 --- a/linux-user/syscall_defs.h +++ b/linux-user/syscall_defs.h @@ -1251,17 +1251,6 @@ struct target_winsize { #include "termbits.h" -#if defined(TARGET_MIPS) || defined(TARGET_XTENSA) -#define TARGET_PROT_SEM 0x10 -#else -#define TARGET_PROT_SEM 0x08 -#endif - -#ifdef TARGET_AARCH64 -#define TARGET_PROT_BTI 0x10 -#define TARGET_PROT_MTE 0x20 -#endif - #include "target_mman.h" #if (defined(TARGET_I386) && defined(TARGET_ABI32)) \ diff --git a/linux-user/xtensa/target_mman.h b/linux-user/xtensa/target_mman.h index d1d96decf5..e9f3905a52 100644 --- a/linux-user/xtensa/target_mman.h +++ b/linux-user/xtensa/target_mman.h @@ -1,3 +1,5 @@ +#define TARGET_PROT_SEM 0x10 + #define TARGET_MAP_NORESERVE 0x0400 #define TARGET_MAP_ANONYMOUS 0x0800 #define TARGET_MAP_GROWSDOWN 0x1000