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 A4E94ECAAA1 for ; Tue, 6 Sep 2022 05:57:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232334AbiIFF5s (ORCPT ); Tue, 6 Sep 2022 01:57:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33916 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229755AbiIFF5r (ORCPT ); Tue, 6 Sep 2022 01:57:47 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D080659CA for ; Mon, 5 Sep 2022 22:57:46 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id A808DB81627 for ; Tue, 6 Sep 2022 05:57:44 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5BBE9C433D6 for ; Tue, 6 Sep 2022 05:57:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1662443863; bh=hQca5NtX2FBlPGk+GSQpzGG+VRJ3Z904jrv6Nzdt/3E=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=SFtooTkiyMSeuxJ7f1gN9skE0ZcbsMoAdEObqRVlAgE+qqRi8+Y7L0MkEdLz7yImw DPpisMT4vQUEgLG3x7UMXLspTdF07jST7y2Q+YdRl9WmK5tEa/MtkH+ta9IKcA4Ufg W+UdliA3eRypOxqgRsfxVSUhgjl5jLmVXNw6fsptfMbgUdYS/p484p7gwivWNQn9dX RYqjSNNEQ89o6JQ9w06jSUhUHv7qwIca/JJAz4mSaUZGC4tN31EJrFuZXf/NTADuCT muNViFtcn93xCWQ86S9Ixuzo0nofaDg1rWHwkY8GBuIK+dMHWHYflVChAbqxlf6Vih 3N5uKlAFWLm1g== Received: by mail-ua1-f42.google.com with SMTP id e3so3973535uax.4 for ; Mon, 05 Sep 2022 22:57:43 -0700 (PDT) X-Gm-Message-State: ACgBeo3KR+7AY5h8oLZzXeMa4YMRPh1jFDgCfBeZTCkPzezMoYs5PZI4 nvBu/+UUncaL5gSE2F50Huc2eW4egXSVuCUHQek= X-Google-Smtp-Source: AA6agR7Qo1zXs+K6mR1O8A31AAZ4nJZysXhwJLbVHgukToP4OsQw3zKXMyPs74Vq8WWlLFPb/sc7svi8F6oSnwLSXzI= X-Received: by 2002:ab0:d82:0:b0:39e:db4c:c80c with SMTP id i2-20020ab00d82000000b0039edb4cc80cmr15008458uak.22.1662443862305; Mon, 05 Sep 2022 22:57:42 -0700 (PDT) MIME-Version: 1.0 References: <20220830104806.128365-1-xry111@xry111.site> <5b87173faeef587a2ffaaa6f58d34e0940231067.camel@xry111.site> <97291c0fe5a660c844475ff019c8db6af77ecf86.camel@xry111.site> <8d0f96e2977c5c78f17bb410087f2aad986ef5a4.camel@xry111.site> <6a3e185eaaac4a1397abe43026004548d47ee305.camel@xry111.site> In-Reply-To: <6a3e185eaaac4a1397abe43026004548d47ee305.camel@xry111.site> From: Huacai Chen Date: Tue, 6 Sep 2022 13:57:31 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v7 0/5] LoongArch: Support toolchain with new relocation types To: Xi Ruoyao Cc: Ard Biesheuvel , Jinyang He , WANG Xuerui , loongarch@lists.linux.dev, LKML , Youling Tang Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Ruoyao, On Tue, Sep 6, 2022 at 1:01 PM Xi Ruoyao wrote: > > 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". The names of those options are confusing. > > > (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.) 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? I know that should be changed. I just don't like the one-line patch and hope it can be squashed to the original patch. Of course Ard is free to decide how to handle it. Huacai > > -- > Xi Ruoyao > School of Aerospace Science and Technology, Xidian University