From nobody Mon Aug 26 04:53:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Wsdbg5Qg3z5VCDN; Mon, 26 Aug 2024 04:53:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Wsdbg4npBz54XQ; Mon, 26 Aug 2024 04:53:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1724647999; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lFpepENUAm5HS9itt8K+jfRp2XklO5PIZ4n7c6XXVGA=; b=q1CMb+dzU1dzqOUHPh2+F7zpI7c/XMb6pMLw2LGqe/zSYcbJ/pZviFYgHATU2ZUupTQq9G Luxse5H9sRBM/oHrdT2r3x5dmwNgXV5rNqJoNgMLE2iCiyelzoXpOmZmm5x3RHgOGMZjvS eilt3FcGGR//1BxJBF2ON468nkXv6EZqEXFeXb1CILJhYBHaeietZSh95Q8R6I2j9AP7N3 YsdNZn77yL/tAPhX2tUGgHcIHqmeRJqNvk35YQX4lSvVbZhV+52l4SVnKQg4N96Y7kJvBN pLSH4SbYCnt2WKIu2uGZe9emGjpu+sbiZWWMU/EWZnqcDHsPSqs7AwpdYXRSmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1724647999; a=rsa-sha256; cv=none; b=dwb7yME9wSJxPeWVDYofev8Nad5NanLkFSJxOS6zNEMeGegVZpo/ZlPOWjo/HBZd94vXvr IA58hHyrwhQ9V4N+E47QMAToJVbCkbrtRPzU0OM3FO67G32R/fxOkyJOFEJiIV7gJcQVTu WSDM6ftJGDpf6RkCr/1VVFMc495cstVgcgYyW3m4NrAK9ef3+5qd7VHhaj3Rl1WMKji6n9 U8TnefY3CzT7qSlCTQjrLhT5u87ZHOIy531UNPuJHDQPKGxSo9Z0ItgzwMCCflDltDvv0r RRBcIQm7xki/THaNFlJ00M7nsWKGhR+QjwT87oUbJX1nZeXGbx7edtVzp2pfjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1724647999; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lFpepENUAm5HS9itt8K+jfRp2XklO5PIZ4n7c6XXVGA=; b=moGHUvb1N6ycbSqeHnqECelz4tvDWWoZKpT6YNyzJeOdY3xUu2xY3G3UFSUzv30hqwvKqU AuBVU5wB4ODNmCXfWEWfUtfuZkwk3FJglSvvqNVyM1ANlvNm/Y/ocMd3WBA1YTHMsXjm3I 3oqb50mf8TFdTwjgLmO3uADCSf09k3SGhNuxbNVJDHD0stYekDB3QjBtDkodArvYdnuovk BDGkAvafw8HMQl/B2nY3NOq2hy5q8eGZLglq6KmWPewTaWYv2b16uxzZaX3M8D47+cEO5t SzxLKbFqLfW+d6FNU7BMUoBviAWEelL0eGCBewJsSQKmqErwlFJdTlVw+WNCkQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Wsdbg4NqDzt1B; Mon, 26 Aug 2024 04:53:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 47Q4rJjU099725; Mon, 26 Aug 2024 04:53:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 47Q4rJ6J099722; Mon, 26 Aug 2024 04:53:19 GMT (envelope-from git) Date: Mon, 26 Aug 2024 04:53:19 GMT Message-Id: <202408260453.47Q4rJ6J099722@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alex Richardson Subject: git: 04262ed78d23 - main - rtld-elf: Add CFI annotation for .rtld_start on RISC-V List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: arichardson X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 04262ed78d2368a9e1f64755fb92a22872a20cac Auto-Submitted: auto-generated The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=04262ed78d2368a9e1f64755fb92a22872a20cac commit 04262ed78d2368a9e1f64755fb92a22872a20cac Author: Alex Richardson AuthorDate: 2024-08-26 04:51:55 +0000 Commit: Alex Richardson CommitDate: 2024-08-26 04:51:55 +0000 rtld-elf: Add CFI annotation for .rtld_start on RISC-V Without this change, unwinders such as LLVM libunwind will attempt to unwind beyond the start of RTLD and get stuck in an infinite loop or crash (depending on the current values on the stack). This fixes an infinite loop in the LLVM libunwind test suite on RISC-V. See also https://reviews.freebsd.org/D40844 for AArch64 Reviewed By: #riscv, jhb MFC After: 2 weeks Differential Revision: https://reviews.freebsd.org/D46406 --- libexec/rtld-elf/riscv/rtld_start.S | 1 + 1 file changed, 1 insertion(+) diff --git a/libexec/rtld-elf/riscv/rtld_start.S b/libexec/rtld-elf/riscv/rtld_start.S index 5459089fa1e6..e0b8157c964f 100644 --- a/libexec/rtld-elf/riscv/rtld_start.S +++ b/libexec/rtld-elf/riscv/rtld_start.S @@ -39,6 +39,7 @@ */ ENTRY(.rtld_start) + .cfi_undefined ra /* Do not attempt to unwind any further. */ mv s0, a0 /* Put ps_strings in a callee-saved register */ mv s1, sp /* And the stack pointer */