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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id ED2DAECAAA1 for ; Tue, 6 Sep 2022 05:01:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232100AbiIFFBj (ORCPT ); Tue, 6 Sep 2022 01:01:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32962 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230377AbiIFFBe (ORCPT ); Tue, 6 Sep 2022 01:01:34 -0400 Received: from xry111.site (xry111.site [IPv6:2001:470:683e::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3B3875F122 for ; Mon, 5 Sep 2022 22:01:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=xry111.site; s=default; t=1662440491; bh=1oNtxf1c5bbGEwVSqkKGWodjPqD73sS9Q23KWDUkQ6g=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=aX6nT/2JzHVMgDszWnrupgVW3cEl6rr1OHFw95xgVFGoIfsOSegPaE4yzhx5DK0Dd folpTg84mXDIFjOPKbbx7TKGcYj4uBDfhJS5GDM7cFZpZbCd1sKLGix+GJQxKDM6JL NDQYjTTvZo+xAf7IrRnSCKpkNRve+8QD07ZIXGz8= Received: from localhost.localdomain (xry111.site [IPv6:2001:470:683e::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-384) server-digest SHA384) (Client did not present a certificate) (Authenticated sender: xry111@xry111.site) by xry111.site (Postfix) with ESMTPSA id 5BDB965C37; Tue, 6 Sep 2022 01:01:29 -0400 (EDT) Message-ID: <6a3e185eaaac4a1397abe43026004548d47ee305.camel@xry111.site> Subject: Re: [PATCH v7 0/5] LoongArch: Support toolchain with new relocation types From: Xi Ruoyao To: Huacai Chen , Ard Biesheuvel Cc: Jinyang He , WANG Xuerui , loongarch@lists.linux.dev, LKML , Youling Tang Date: Tue, 06 Sep 2022 13:01:27 +0800 In-Reply-To: References: <20220830104806.128365-1-xry111@xry111.site> <5b87173faeef587a2ffaaa6f58d34e0940231067.camel@xry111.site> <97291c0fe5a660c844475ff019c8db6af77ecf86.camel@xry111.site> <8d0f96e2977c5c78f17bb410087f2aad986ef5a4.camel@xry111.site> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.45.3 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2022-09-06 at 12:43 +0800, Huacai Chen wrote: > > Note that -fpic/-fPIC is "position-independent code *suitable for > > use in a shared library*", while -fpie/-fPIE is more like just > > "position-independent code".=C2=A0 The names of those options are confu= sing. > > (When -fpic was invented first time, people mostly believed "PIC had > > been only for shared libraries", so it's named -fpic instead of -shlib > > or something.)=C2=A0 IMO in the EFI stub for other ports, -fpie should = be > > used instead of -fpic as well because the EFI stub is not similar to a > > shared library in any means. > You are right, but I guess that Ard doesn't want to squash the efistub > change into the LoongArch efistub support patch. :) It only changes cflags-$(CONFIG_LOONGARCH), which is LoongArch specific. And arm64 is also using -fpie. Should I send the one-line EFI stub change to linux-efi first? --=20 Xi Ruoyao School of Aerospace Science and Technology, Xidian University