From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A4BC1C433F5 for ; Tue, 11 Oct 2022 13:56:58 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 6AAE784F07; Tue, 11 Oct 2022 15:56:51 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=konsulko.com header.i=@konsulko.com header.b="BBJ8J4Ix"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id E6ACA84567; Tue, 11 Oct 2022 15:56:48 +0200 (CEST) Received: from mail-qt1-x82f.google.com (mail-qt1-x82f.google.com [IPv6:2607:f8b0:4864:20::82f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 6079B84F04 for ; Tue, 11 Oct 2022 15:56:45 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qt1-x82f.google.com with SMTP id h15so4121997qtu.2 for ; Tue, 11 Oct 2022 06:56:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=y8+jFGFZV89PtsqOpg9hkjsi8LnhPiuLDm9dzLmAO8M=; b=BBJ8J4Ixr76O5/FbWly/FrC2yZ4FZ+eDwG4uqkXhKMvdSvZUeHzK2NdmTX7+xO4rbp eBaqscOhIhtuZDfWjQBnnP3yIRbPvS1tJi5knsFKJd99PYNh9CLOd/SRqG8wXiqI0kMQ zOLE8kDdR00PR/O+Tmv0t6lfJId9nOcswnmhE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=y8+jFGFZV89PtsqOpg9hkjsi8LnhPiuLDm9dzLmAO8M=; b=AefCaOrlhj8pRqCTHXlzFpqfh10ZrKG4/MV944sH2/8+ClpzgIA94ImbjWjkkgL0Iw IkA/0/PXcNwzNmPXk2OL4cg9m8epibN6/F/wpG0uzv3PtiDjv+fBgrsuSL0qXLDlfFb/ l2w/uhxWeyWsS/w8osWgmVRcl7mfXJvPiAwMBz/EKEoSlNiPyWSQJxLIDATTwCpz4xDP 4pcrbHGHzKa5gZPFze0FySQsjTp34rbXjOGYdGZs45g+38pZZcKOSpv5zDPSUzn2WoM3 X8FNZ3nd81FHlHXPsH9PqahQbCW6D66dB2ocnGGEPo0r8CGWUTDqj4KvZbyx5O2u9JpE bc+w== X-Gm-Message-State: ACrzQf28ripRQlqun92m4XDwlQsjWWegb/sk/nQapkCXTiJO//sPcEtB OWIbGSI7xaErNtEdAgNM8hu92Q== X-Google-Smtp-Source: AMsMyM4Uo4F8OEYol2uuWUXiQnLz1BWtv759D0MBEy2MKZEo6fJKnM284Y9GCBpWYY0dYcEZ9XGDxw== X-Received: by 2002:a05:622a:5149:b0:38d:961c:a568 with SMTP id ew9-20020a05622a514900b0038d961ca568mr18906394qtb.511.1665496604085; Tue, 11 Oct 2022 06:56:44 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b00-6400-9506-5302-f3bb-a137.res6.spectrum.com. [2603:6081:7b00:6400:9506:5302:f3bb:a137]) by smtp.gmail.com with ESMTPSA id n14-20020ac85a0e000000b00397912cb249sm8643616qta.28.2022.10.11.06.56.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Oct 2022 06:56:43 -0700 (PDT) Date: Tue, 11 Oct 2022 09:56:41 -0400 From: Tom Rini To: Alistair Delva Cc: u-boot@lists.denx.de, Fangrui Song , Nick Desaulniers , Simon Glass Subject: Re: [PATCH] Makefile: apply dynamic relocations for LLD Message-ID: <20221011135641.GZ2020586@bill-the-cat> References: <20220926204740.861969-1-adelva@google.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="worL9B4ITIAQZ1FS" Content-Disposition: inline In-Reply-To: <20220926204740.861969-1-adelva@google.com> X-Clacks-Overhead: GNU Terry Pratchett X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean --worL9B4ITIAQZ1FS Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 26, 2022 at 08:47:40PM +0000, Alistair Delva wrote: > From: Nick Desaulniers >=20 > It seems that for aarch64, unless we apply dynamic relocations to the > location being relocated, we fail to boot. >=20 > As Fangrui notes: > For dynamic relocations using the RELA format (readelf -Wr), GNU ld > sets the initial content to r_addend; ld.lld doesn't do that by > default (needs --apply-dynamic-relocs). >=20 > Otherwise .rodata appears to be full of NUL-bytes before relocation, > causing crashes when trying to invoke the function pointers in > init_sequence_f from initcall_run_list(). >=20 > Link: https://reviews.llvm.org/D42797 > Suggested-by: Fangrui Song > Signed-off-by: Nick Desaulniers > Signed-off-by: Alistair Delva > Cc: Simon Glass > Cc: Tom Rini > Cc: Nick Desaulniers Applied to u-boot/master, thanks! --=20 Tom --worL9B4ITIAQZ1FS Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmNFdhkACgkQFHw5/5Y0 tyxRmgv/V1vYCcnNE21NGhOxTCWDC7eLo1u/CBey0l4/LekSprrRF6Y2M4OhVDh+ gZqx4XFw7bbWj35kctws33R7mBPDjjJxYzjOkNd5M0o0fX1xr7R4ACpf1NOgRzZ/ V+9vREiPvhpdq8EJcnKmuJAk6hA21Eb6i7v4NF9Vsy7PLt3S3nliGtt9I/apq7Dy sw034H0whKp0u36P4wO52FcnmMFiKQszcriBkm+JBvJYfVWVeBIdlLTcUCahsQUJ 8/7R/0URjEKI6ZJxfdPo1Zh04eFLoy9ggf+MRt/Cmepkpwjkq/WfDEGgRz4xp7E5 0hdUFe2pTlS7HLzXfbRTnDOwVrfsxJAy0dW3ZKHl6oLmG+to6AE82rIb6fFU/T68 n08ztqy0ENdfqKGS8urC1oXqrEi7D+mAMQ/H1apt6WhnddaFHjQcgSJDNCJW3Thy kANc8UMv5bRG744uSipck7iMAkOINNTJwAthqOwyVpNd97sITTvhlBB+IdKfT/4S zylJShad =rvly -----END PGP SIGNATURE----- --worL9B4ITIAQZ1FS--