From patchwork Mon May 1 23:47:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 68613 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id E0F7E3856DFE for ; Mon, 1 May 2023 23:48:44 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pj1-x102a.google.com (mail-pj1-x102a.google.com [IPv6:2607:f8b0:4864:20::102a]) by sourceware.org (Postfix) with ESMTPS id 478503858D28 for ; Mon, 1 May 2023 23:48:29 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 478503858D28 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pj1-x102a.google.com with SMTP id 98e67ed59e1d1-247048f86c7so2156286a91.2 for ; Mon, 01 May 2023 16:48:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1682984908; x=1685576908; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=AMW2sRhqcAQfyBSWZe5LIpuc8/DKNNYwTj8z6bHy9tk=; b=u35fSfAXCxLf3HCgWyaWTL6W7APjYDhvClq2uEo7cfj1ngLqxPJtqLudW+GbK8YoCD tcoQG5L0scW+ZkauidIhpDc3rQ1WzqkkaztT1//JsRWzPfkYb76IXDMfuoQzR2fpEPur XeHAOrsKmW+iJoR36+J8ijb+7wVLAbJcfoScwtvn5Jgy/qIUue+BK6qfTFh0niw6hgdt 9u5lQaEO8+TX+8ugCbeoMvV3pMH79tco4KgpxgYa9BKfEMECgtI5/e6OjOeMAYiFdetd D1iuFvEguS549aI7lRTqSiKotO17Lf58i8z/j8wxLVTWa8wr9In+sIy+kVQ02efDsv2N W3CQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682984908; x=1685576908; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=AMW2sRhqcAQfyBSWZe5LIpuc8/DKNNYwTj8z6bHy9tk=; b=e3TLJ4vMqem7qA4XIWXc4sA2aaFPNxGzqmBmlCsblDMg3Wz2O/mZ+CGWr9XsX82oui kTHdHxroDF1xewyzCX9P51bh85CGd2mDUroY9pt0caJ65YSDB2auXZqXrSuYI7xE1Cjl nkfoEuSZ7M0sN9qQGdIf7TFuyNr2+/CITIQeRDqS5QuA38hCtxqWL78NrwZonpJZVAkc VnJCnOLdD7egik1ptK6Dq0d4YjKdHEhMGN2boPS2KKWlItbT6NQrn6NDNVj6X5RbSmgD SJVx+UMU7xy7OjRf+hb+/ga3/Oxllas8sZUhPgVbIUAjLBywM77uZfW06L9GUhPseUH4 H6dQ== X-Gm-Message-State: AC+VfDzWupCeqVwUFjhIGxg/LFHipZBCOFTaF87Rj9PaU3sa+Rjx/ehY KqjqG3ii4RvxYkSgTbPb0mcya9ENHun3c+1yrVw= X-Google-Smtp-Source: ACHHUZ7qmcphZcrAvzK5K9psDUBqNxGhKhl0awd9t/35pFm7W4OArba7PJWRgaSblKRfo8QW8DeWvQ== X-Received: by 2002:a17:90b:895:b0:24e:14ad:24c7 with SMTP id bj21-20020a17090b089500b0024e14ad24c7mr2676436pjb.13.1682984908077; Mon, 01 May 2023 16:48:28 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id t20-20020a17090aba9400b0023b4d4ca3a9sm6358859pjr.50.2023.05.01.16.48.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 16:48:27 -0700 (PDT) Subject: [PATCH v3 1/6] elf.h, scripts: Don't error on duplicate DT_RISCV_NUM Date: Mon, 1 May 2023 16:47:34 -0700 Message-Id: <20230501234739.7264-2-palmer@rivosinc.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501234739.7264-1-palmer@rivosinc.com> References: <20230501234739.7264-1-palmer@rivosinc.com> MIME-Version: 1.0 Cc: libc-alpha@sourceware.org, Palmer Dabbelt From: Palmer Dabbelt To: maskray@google.com, joseph@codesourcery.com X-Spam-Status: No, score=-11.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" DT_RISCV_NUM is just the count of d_tag entries, so it's OK if it has the same value as some other entry. Other architectures allow this duplication, do so for RISC-V as well. Reported-by: Joseph S. Myers Fixes: 117e8b341c ("riscv: Resolve symbols directly for symbols with STO_RISCV_VARIANT_CC.") Link: https://inbox.sourceware.org/libc-alpha/mhng-0d9fb5a0-63fa-4b02-8029-7c20232f39ee@palmer-ri-x1c9/T/#t Signed-off-by: Palmer Dabbelt --- elf/tst-glibcelf.py | 1 + scripts/glibcelf.py | 1 + 2 files changed, 2 insertions(+) diff --git a/elf/tst-glibcelf.py b/elf/tst-glibcelf.py index 6142ca28ae..41d1b18022 100644 --- a/elf/tst-glibcelf.py +++ b/elf/tst-glibcelf.py @@ -182,6 +182,7 @@ DT_NUM DT_PPC64_NUM DT_PPC_NUM DT_PROCNUM +DT_RISCV_NUM DT_SPARC_NUM DT_VALNUM DT_VALRNGHI diff --git a/scripts/glibcelf.py b/scripts/glibcelf.py index 6f48eee129..9d36ea60cd 100644 --- a/scripts/glibcelf.py +++ b/scripts/glibcelf.py @@ -450,6 +450,7 @@ DT_IA_64_NUM DT_MIPS_NUM DT_PPC_NUM DT_PPC64_NUM +DT_RISCV_NUM DT_SPARC_NUM '''.strip().split() _register_elf_h(DtAARCH64, prefix='DT_AARCH64_', skip=_dt_skip, parent=Dt) From patchwork Mon May 1 23:47:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 68614 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 05DE93858291 for ; Mon, 1 May 2023 23:48:49 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pg1-x52f.google.com (mail-pg1-x52f.google.com [IPv6:2607:f8b0:4864:20::52f]) by sourceware.org (Postfix) with ESMTPS id 6D53B3858D39 for ; Mon, 1 May 2023 23:48:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6D53B3858D39 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pg1-x52f.google.com with SMTP id 41be03b00d2f7-52c30fbccd4so980582a12.0 for ; Mon, 01 May 2023 16:48:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1682984909; x=1685576909; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=ZLqi/qV4bdw9dmUvOlNkuy/LyCWHAYfn3KdRs4rZd7A=; b=fCAxMbZYahSm40O6yRgYNiH3b6WfD8r9x7KV5twn2tsJwermsj8mj/Xr2RQq9cHGgW G2V6QJ+u34F3Bs/RcTuu8CoF34jGAHdEGwXMEx1FyEkW/QWfnwdJ4ui1jTdWV/RpRRxp xh26ikrXkuHGvQbRaIt8/tdVPqlpKuXnBUvp1bURjfTPs1VVFIigYBskXDt/PLiloTnq bI495gp0IVAnPdqAqG3Q02I1pqmEkni74zPFCJwI9PjmFa1wFBC2AYogqnIJUqy7a4Xl db8U5JqzmPGOMJIDgO8lpbnzLw0viU6LvJy8gYOvjlIpgN9BnuoF3dPHs2ZarIy2csUv J4AQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682984909; x=1685576909; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZLqi/qV4bdw9dmUvOlNkuy/LyCWHAYfn3KdRs4rZd7A=; b=iEHfCjdSODpXaByiLBajaoirICR/UdlKi97I5fXNfax9O66RCzQknwzlJvVxPNDEWD BfLHaBVG0NrruSwpNk5yqZrmIfkoBOL6F0d1yBe8Ywk63P0J7sfEUBS5ZaFtwoGrX+V9 AWI7lz/F18NRTynndQOosnFsR6eGJEJjAVNA7D2OvXbCmt2faAM3bxCnRCigkK96kNgX W2NAOdzt9sz/kWZDDiTHSYGF/gml3Rat6BhFGHVBNd5K4ApBTI5evxFaMJTz8tkz5DBU O60/8TpLlmwzR9iFIdLbghhpLToO/0WZ4GvZoxWdSoDOFNKuMpmjzI1Jdb/60X+1w3+9 qmiA== X-Gm-Message-State: AC+VfDw3gwH7JR0aZuzC8fydDzz7fLIbOkklB7RpX7ltyKD5km+q9lCl GVEEu7EvY3KqV5nLggAAtER/za+NZbiWbHeAbDk= X-Google-Smtp-Source: ACHHUZ40ZtQHDjpovA620Boon0ChWSS8DXp4n3U8Yk+8xtPoLWrtQA8KzyBc3TYQz+kvR90w6f8G2Q== X-Received: by 2002:a17:902:f68e:b0:1a6:7510:3341 with SMTP id l14-20020a170902f68e00b001a675103341mr18622935plg.69.1682984909185; Mon, 01 May 2023 16:48:29 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id m23-20020a170902bb9700b001ab025acc8fsm1219542pls.260.2023.05.01.16.48.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 16:48:28 -0700 (PDT) Subject: [PATCH v3 2/6] elf.h: Remove duplicate STO_RISCV_VARIANT_CC Date: Mon, 1 May 2023 16:47:35 -0700 Message-Id: <20230501234739.7264-3-palmer@rivosinc.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501234739.7264-1-palmer@rivosinc.com> References: <20230501234739.7264-1-palmer@rivosinc.com> MIME-Version: 1.0 Cc: libc-alpha@sourceware.org, Palmer Dabbelt From: Palmer Dabbelt To: maskray@google.com, joseph@codesourcery.com X-Spam-Status: No, score=-11.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" I missed the update from last year that included these already, having duplicates breaks the build due to redefinition errors like elf/elf.h:4013: error: macro STO_RISCV_VARIANT_CC redefined elf.h:3941: note: location of previous definition Reported-by: Joseph S. Myers Fixes: 117e8b341c ("riscv: Resolve symbols directly for symbols with STO_RISCV_VARIANT_CC.") Link: https://inbox.sourceware.org/libc-alpha/mhng-0d9fb5a0-63fa-4b02-8029-7c20232f39ee@palmer-ri-x1c9/T/#t Signed-off-by: Palmer Dabbelt --- elf/elf.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/elf/elf.h b/elf/elf.h index 4f65b5a32d..0cbd4510c6 100644 --- a/elf/elf.h +++ b/elf/elf.h @@ -3937,9 +3937,6 @@ enum #define DT_RISCV_VARIANT_CC (DT_LOPROC + 1) #define DT_RISCV_NUM 2 -/* RISC-V specific values for the st_other field. */ -#define STO_RISCV_VARIANT_CC 0x80 - /* RISC-V ELF Flags */ #define EF_RISCV_RVC 0x0001 #define EF_RISCV_FLOAT_ABI 0x0006 From patchwork Mon May 1 23:47:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 68616 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id C9E1B385702B for ; Mon, 1 May 2023 23:49:09 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pl1-x630.google.com (mail-pl1-x630.google.com [IPv6:2607:f8b0:4864:20::630]) by sourceware.org (Postfix) with ESMTPS id 79A893858C83 for ; Mon, 1 May 2023 23:48:31 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 79A893858C83 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pl1-x630.google.com with SMTP id d9443c01a7336-1aaec6f189cso14395855ad.3 for ; Mon, 01 May 2023 16:48:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1682984910; x=1685576910; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=DXlat9UW5n+OiClggah4jJNItXPGvDRUYJ0IWREOQIE=; b=F8MxLfoogmeU3pwsG9WBg4Bgzj1brnWBjNKVF9OwYYYWB/zHusa7DE7C8OEVFWfrWE XGMxkRtHrJttPDnzVqCba9OnJ91Max2wHQ9AsgbP1Wk9mY9vMkuDnZaHpZ9A5nEcZi/+ swmyociCKaY8ZfUkWEE7HFLIJGNIaAYiAZGDk/gJHPTnvRg2za4dRBw6NFd4RpnC1WH0 jbv3eSj2Bwlvs/mz3KuvRQY4jU8tF0tBKlC5DNQYxnm6LyT2AMj/kiQGrWZp5iuE+3d5 CL0c6aNNCio5VgxWBz3w9QW7HhC+LMx/6B/+2AiOdxTDZvWxbN9MDn+HpC+fAlWIQPMO HetQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682984910; x=1685576910; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=DXlat9UW5n+OiClggah4jJNItXPGvDRUYJ0IWREOQIE=; b=U6aPTv60Zw9DHvb74/eLU3iCd0EhmponUVMI0q5xZhpZLGz0oPiGXgcXUAijFYA8lE AZODI1CLTStHPvikBG659SU4Iry5yNqN+5icx2mh1U7aF3ecTCUbiL6FGvJQnblctJQy Q7g2j3rsXuwCmuvj7HaG/7HWJ8ZHE3HbTThqbC6b7gpSE1qy/TV7w4RwK8Os2TYsaPbh wFRuEjni3IyU/GD4VFziRSsjqZ8udwY9HWGL/r+ZsJpHNnsFkTzTy95q05KUl50S+sKK A8HWZ4ihOzLlV1fVgmytITMzxOnVD+tisHqUaZb842+GGZwZBhvJj4kF8iTIyhHPpzpD bqCQ== X-Gm-Message-State: AC+VfDxoXYCsZP8PRBGIIokwOO79bxrvObElKE7h7U+6ZIENZmyXPxMf P61RrggvCoz5LNJ0DgKFpDLwQoTLO0A7LPYnMWs= X-Google-Smtp-Source: ACHHUZ68VDwru8KIEXP/+jwCmtTl9zDUSJalKBfdh5c0BTf8sskx8m+rGZHqpUPvB+g3jZHl9EaFEw== X-Received: by 2002:a17:902:f649:b0:1a6:a988:b858 with SMTP id m9-20020a170902f64900b001a6a988b858mr14444482plg.58.1682984910257; Mon, 01 May 2023 16:48:30 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id o4-20020a170902778400b001a2135e7eabsm18379583pll.16.2023.05.01.16.48.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 16:48:29 -0700 (PDT) Subject: [PATCH v3 3/6] elf.h: Remove duplicate DT_RISCV_VARIANT_CC Date: Mon, 1 May 2023 16:47:36 -0700 Message-Id: <20230501234739.7264-4-palmer@rivosinc.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501234739.7264-1-palmer@rivosinc.com> References: <20230501234739.7264-1-palmer@rivosinc.com> MIME-Version: 1.0 Cc: libc-alpha@sourceware.org, Palmer Dabbelt From: Palmer Dabbelt To: maskray@google.com, joseph@codesourcery.com X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" I missed the update from last year that included these already, having duplicates breaks the build due to redefinition errors like elf/elf.h:4023: error: macro DT_RISCV_VARIANT_CC redefined elf/elf.h:3937: note: location of previous definition Reported-by: Joseph S. Myers Fixes: 117e8b341c ("riscv: Resolve symbols directly for symbols with STO_RISCV_VARIANT_CC.") Link: https://inbox.sourceware.org/libc-alpha/mhng-0d9fb5a0-63fa-4b02-8029-7c20232f39ee@palmer-ri-x1c9/T/#t Signed-off-by: Palmer Dabbelt --- elf/elf.h | 1 - 1 file changed, 1 deletion(-) diff --git a/elf/elf.h b/elf/elf.h index 0cbd4510c6..4c61d3a5ee 100644 --- a/elf/elf.h +++ b/elf/elf.h @@ -3934,7 +3934,6 @@ enum #define R_TILEGX_NUM 130 /* RISC-V specific values for the Dyn d_tag field. */ -#define DT_RISCV_VARIANT_CC (DT_LOPROC + 1) #define DT_RISCV_NUM 2 /* RISC-V ELF Flags */ From patchwork Mon May 1 23:47:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 68615 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 15E013858417 for ; Mon, 1 May 2023 23:48:53 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pg1-x531.google.com (mail-pg1-x531.google.com [IPv6:2607:f8b0:4864:20::531]) by sourceware.org (Postfix) with ESMTPS id B61683858C27 for ; Mon, 1 May 2023 23:48:32 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B61683858C27 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pg1-x531.google.com with SMTP id 41be03b00d2f7-517c840f181so1569216a12.3 for ; Mon, 01 May 2023 16:48:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1682984911; x=1685576911; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=zhFwVyV749PTlqvgj/Y3AoTijF7AAsKCO60KhMnJU1M=; b=5Z8+vjTUkFTd4ZQbTLyqrDQcFB9uhWGOhEkwz3FR99Z3x3t+IRGJCf7FTezOcsBC0/ ub9q7UwVe3/fFIuFwn+bQIZJwhaZl/FUalL6s/oF/SgmScVV3fBCXOOUseh8f5e9N1Wp uXlO+AiYM9xNgnsv5bgRPz0s9XGJJKFVrdbMX+4e66IH+0Cb+Tnb6Xxyj9HdA7r1eijf 0oBjO40TCFBGrfiD/iQg1bMLIFn788ATgzqJIqqe7nZ1xDo8gNVx1IaI4/L+d4O+3J1J eA4MUOEDexM/HxCuHhdNOMEN6ZHkeEXMbhhbB+yQXl5sBM3Ex99RcWopH60O3ksN/eFl lwYA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682984911; x=1685576911; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=zhFwVyV749PTlqvgj/Y3AoTijF7AAsKCO60KhMnJU1M=; b=Vbw0Oz6pVBgS8hK86lhsDMhA8ipKonks1ViTVTi4UfNpuhtBIptzYIX5jBsO30BDwg N8o52hqzU3z+PkXCCqeZj0taybBSRUiRsxMT+7ugCdZAb8CxThI3Ml1Ehxr1V2DLdjrF V1+MlKDEyUZVAcfb4JwhD2jVJjJkUv8EqglSdO2GQlOofmc3OD2JyH94jS8V3xvU+wA8 Q8GME5TiWsQ1cq+oLVkav5xfy8/Lre82hlLLqJTGr7is1s4K2fpigbFvGhprZDtjOMXG rjOro0jM4tPsbLV/B0RApVH0GGvtm4naaZ8XsFgz1MvfWHyhjw6PInugit/1JZo8dlKy cNLg== X-Gm-Message-State: AC+VfDx5K8bWPoCFker1uryXPm7OAEOsqXNL70L/KTSDeIKEtjEn5a4b AE1KrotfBsUU33LLiyG+KQx5GOMhdSgFrPyFhHk= X-Google-Smtp-Source: ACHHUZ6vCKwP5iC4Q3bOB8QZkiQ3tuawjXaKIFcRVWGBBHwKybMFPEkrBCQ1ZyjD33hAcigCQ2TGDg== X-Received: by 2002:a17:902:f54d:b0:1a1:e01e:7279 with SMTP id h13-20020a170902f54d00b001a1e01e7279mr17979714plf.4.1682984911380; Mon, 01 May 2023 16:48:31 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id q16-20020a170902dad000b00194caf3e975sm18377237plx.208.2023.05.01.16.48.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 16:48:30 -0700 (PDT) Subject: [PATCH v3 4/6] elf.h: Reorder DT_RISCV_* Date: Mon, 1 May 2023 16:47:37 -0700 Message-Id: <20230501234739.7264-5-palmer@rivosinc.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501234739.7264-1-palmer@rivosinc.com> References: <20230501234739.7264-1-palmer@rivosinc.com> MIME-Version: 1.0 Cc: libc-alpha@sourceware.org, Palmer Dabbelt From: Palmer Dabbelt To: maskray@google.com, joseph@codesourcery.com X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" These match the MIPS ordering. Reported-by: Fangrui Song Signed-off-by: Palmer Dabbelt Reviewed-by: Fangrui Song --- elf/elf.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/elf/elf.h b/elf/elf.h index 4c61d3a5ee..f9d169e4e2 100644 --- a/elf/elf.h +++ b/elf/elf.h @@ -3933,9 +3933,6 @@ enum #define R_TILEGX_NUM 130 -/* RISC-V specific values for the Dyn d_tag field. */ -#define DT_RISCV_NUM 2 - /* RISC-V ELF Flags */ #define EF_RISCV_RVC 0x0001 #define EF_RISCV_FLOAT_ABI 0x0006 @@ -4017,6 +4014,7 @@ enum /* RISC-V specific values for the d_tag field. */ #define DT_RISCV_VARIANT_CC (DT_LOPROC + 1) +#define DT_RISCV_NUM 2 /* BPF specific declarations. */ From patchwork Mon May 1 23:47:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 68617 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id D69453858C2B for ; Mon, 1 May 2023 23:49:31 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pg1-x534.google.com (mail-pg1-x534.google.com [IPv6:2607:f8b0:4864:20::534]) by sourceware.org (Postfix) with ESMTPS id BF1EC385842E for ; Mon, 1 May 2023 23:48:33 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org BF1EC385842E Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pg1-x534.google.com with SMTP id 41be03b00d2f7-52c3ffc8d13so389638a12.2 for ; Mon, 01 May 2023 16:48:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1682984912; x=1685576912; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=O1YLR/1n8nX1V20L+aQoGVpsj5gmP/JuQtoEtCfxLvQ=; b=hr4rhYlzGtGVhfXzfah5tD9cPP53c/9vcI85YpOPkfKTADxAZhR7k4CP9XyjaXFFxL anDDn/yNlclo2A3QJ/ffkGK0Zv2i1f70DaCRyRvUPMYVUAqFZbcUJzQrjIjCX4Z3wULO gus+3nZ7VZp8ZLafNK98c4TAIzJGqt4mOK6TmNzFNWl05BegocaD4INdM3/oFOHWWWun u6DhaUlLCjzZ10ab+zEYpAM+hX4lpTBo7E8PbhOHude/C7S79sd7Gu7DOaJxcLKbpiyU iBn3W1KfZWSEdzmxZVAITkBIHzolEkzmhuPvXyzEwNcmQ+rjMn/x6CDho+ZEk7ZzXQO3 /vgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682984912; x=1685576912; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=O1YLR/1n8nX1V20L+aQoGVpsj5gmP/JuQtoEtCfxLvQ=; b=CDnGYAGvuW061AcxgnAdBfRay9I6ex3otTZFfinmlw8wVK2NuxyCFrdGTgD9i8qd4x uG+Ho3ubbn3tmkklN3/NmgsEyZjX7GKkzowMPLfXT3t8ONGynYXKhATzonCeKCSTpVoy yogjIjNb0ain7zc2IreU9F9UF7lRmSMcArisVwKdiObkcKiCv1xkw4rQKALUWTz7xirl oSGoLncuwRcDKzRsuReDEmj9TheJQrG7h7fzKIvV0oZfmAMpTCXV1JI0khDGS7E3tGQx T1SsBSQ28a4+gmrs41tKHkvATuVRtN7OIle3/OhhxLiQMM6EqSaN2yueIFBIfdnD9FWA 9SSw== X-Gm-Message-State: AC+VfDzsmnNaBCUWwWWgCnOlXy263rk4aeyZ0QgTcTLYHxyBfgV9Oftp ysrWBYiSJ4tIpqPIJ/VwCj+AKmoykH2die3WrR0= X-Google-Smtp-Source: ACHHUZ4ikQKkim5FdYPIp/V6uJB2bT9cuWE7r0NRKYl6TUyQBQvrivTk3hJ1/e4TStyRb2oufMATaw== X-Received: by 2002:a17:902:f68e:b0:1a6:7510:3341 with SMTP id l14-20020a170902f68e00b001a675103341mr18623042plg.69.1682984912466; Mon, 01 May 2023 16:48:32 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id c24-20020a170902d91800b001ab05828797sm621904plz.179.2023.05.01.16.48.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 16:48:32 -0700 (PDT) Subject: [PATCH v3 5/6] elf.h: Reorder SHT_RISCV_* Date: Mon, 1 May 2023 16:47:38 -0700 Message-Id: <20230501234739.7264-6-palmer@rivosinc.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501234739.7264-1-palmer@rivosinc.com> References: <20230501234739.7264-1-palmer@rivosinc.com> MIME-Version: 1.0 Cc: libc-alpha@sourceware.org, Palmer Dabbelt From: Palmer Dabbelt To: maskray@google.com, joseph@codesourcery.com X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" These match the MIPS ordering. Signed-off-by: Palmer Dabbelt --- elf/elf.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/elf/elf.h b/elf/elf.h index f9d169e4e2..f4627a3b4f 100644 --- a/elf/elf.h +++ b/elf/elf.h @@ -4002,13 +4002,13 @@ enum #define R_RISCV_NUM 59 +/* RISC-V specific values for the sh_type field. */ +#define SHT_RISCV_ATTRIBUTES (SHT_LOPROC + 3) + /* RISC-V specific values for the st_other field. */ #define STO_RISCV_VARIANT_CC 0x80 /* Function uses variant calling convention */ -/* RISC-V specific values for the sh_type field. */ -#define SHT_RISCV_ATTRIBUTES (SHT_LOPROC + 3) - /* RISC-V specific values for the p_type field. */ #define PT_RISCV_ATTRIBUTES (PT_LOPROC + 3) From patchwork Mon May 1 23:47:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 68618 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id C97E23851C3D for ; Mon, 1 May 2023 23:49:53 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pl1-x630.google.com (mail-pl1-x630.google.com [IPv6:2607:f8b0:4864:20::630]) by sourceware.org (Postfix) with ESMTPS id 71FB9385840D for ; Mon, 1 May 2023 23:48:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 71FB9385840D Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pl1-x630.google.com with SMTP id d9443c01a7336-1aaec6f189cso14396185ad.3 for ; Mon, 01 May 2023 16:48:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1682984914; x=1685576914; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=fvnCupBJjMPlKy0rpb1IUikQ9jMpIHO9Q3cVc2WI84E=; b=KQ/ExYEkD2Yi6xJ+PVrqg++3aVrnpm66x8XFaRNW0Fg0nwfC57OlhKCM4qdJcrHjFa 19QP6L/Ucn8Dh/tAJ/hq1EEg9E1EPdthBid8qU71egMgOcJC0yUgV4gOZMvUGJC4Y87Q /7o9ag90EmP9yJ/fFlO7SYVwol6fE4m3MWGY/tR/a1CPxy7OMhEuhIjKFc9A4ZtgF+Fl x4iv1ADxUzTJ9YT1rh9limPA3rujjyqjqOpbJN/aKwnj0bSpAjOKP7iE4NmCQNF33QKe U4H7bQORb72btKqzVzbnNzeK6FoUTR0Or8IDgZ8++z4wuq8ZjRJzTiRGyvucKfttfIg7 YKbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682984914; x=1685576914; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fvnCupBJjMPlKy0rpb1IUikQ9jMpIHO9Q3cVc2WI84E=; b=QjbJUeZl6qlvVV61nGQoxbHzh76b8rIHYYLQxxsoq1fPURFDzwyd4udLlq+DrcV1vq ZOiZSWfVFSQGCyYRQzp5dSgSHAN+iUot/FX8tglE1Z/bRum8vpGhtqAm31Z9PO6Wp8Z0 YfNGk4QBOPeuHGwB0+pJ3rAAoqfS8Fzotizmotp+C+r9I+mUfP+789iXInSZFdH3Z0uD zglUh9c+Z4EhTflH99OeGIx45aQak3KuVXiKRg89O/irhTrVKOuesBnQEBoqDZt9U6CG 4VSS6gyjw+9Lwr0W78jD69UwE+pJ5Ni3CpqDZh7myCRiWxwwQ37PchqirVHFXjEs2Cv/ KgpA== X-Gm-Message-State: AC+VfDyucenxGGHQZt/dKVi+Ol28Rbp7tMqS4pO0ofL2FVcwrwJUcetP /3NOqZ3pmcmegMQKOEDTQCl0rPxsfrrJ0xyhE70= X-Google-Smtp-Source: ACHHUZ4t5mk3Jhm0N0pzm1s4gOpEbGqG9iELM33VHifPAaNzEEuqit2U/pI5HPR2qyrqT9ypd9pDdQ== X-Received: by 2002:a17:902:c38d:b0:19d:1bc1:ce22 with SMTP id g13-20020a170902c38d00b0019d1bc1ce22mr15886880plg.5.1682984913626; Mon, 01 May 2023 16:48:33 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id y2-20020a17090322c200b001aad714400asm4614169plg.229.2023.05.01.16.48.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 16:48:33 -0700 (PDT) Subject: [PATCH v3 6/6] elf.h: Reorder PT_RISCV_* Date: Mon, 1 May 2023 16:47:39 -0700 Message-Id: <20230501234739.7264-7-palmer@rivosinc.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501234739.7264-1-palmer@rivosinc.com> References: <20230501234739.7264-1-palmer@rivosinc.com> MIME-Version: 1.0 Cc: libc-alpha@sourceware.org, Palmer Dabbelt From: Palmer Dabbelt To: maskray@google.com, joseph@codesourcery.com X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" These match the MIPS ordering. Signed-off-by: Palmer Dabbelt --- elf/elf.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/elf/elf.h b/elf/elf.h index f4627a3b4f..0b35354dbe 100644 --- a/elf/elf.h +++ b/elf/elf.h @@ -4002,6 +4002,9 @@ enum #define R_RISCV_NUM 59 +/* RISC-V specific values for the p_type field. */ +#define PT_RISCV_ATTRIBUTES (PT_LOPROC + 3) + /* RISC-V specific values for the sh_type field. */ #define SHT_RISCV_ATTRIBUTES (SHT_LOPROC + 3) @@ -4009,9 +4012,6 @@ enum #define STO_RISCV_VARIANT_CC 0x80 /* Function uses variant calling convention */ -/* RISC-V specific values for the p_type field. */ -#define PT_RISCV_ATTRIBUTES (PT_LOPROC + 3) - /* RISC-V specific values for the d_tag field. */ #define DT_RISCV_VARIANT_CC (DT_LOPROC + 1) #define DT_RISCV_NUM 2