| Message ID | 20240922092312.2061358-5-dario.binacchi@amarulasolutions.com |
|---|---|
| State | New |
| Headers |
Return-Path:
<linux-amarula+bncBCQ4XFG47UFRBG6EX63QMGQENIFVNZI@amarulasolutions.com>
X-Original-To: linux-amarula@patchwork.amarulasolutions.com
Delivered-To: linux-amarula@patchwork.amarulasolutions.com
Received: from mail-ed1-f70.google.com (mail-ed1-f70.google.com
[209.85.208.70])
by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 8ACAC3F14C
for <linux-amarula@patchwork.amarulasolutions.com>;
Sun, 22 Sep 2024 11:23:40 +0200 (CEST)
Received: by mail-ed1-f70.google.com with SMTP id
4fb4d7f45d1cf-5c3c398b511sf2944762a12.2
for <linux-amarula@patchwork.amarulasolutions.com>;
Sun, 22 Sep 2024 02:23:40 -0700 (PDT)
ARC-Seal: i=2; a=rsa-sha256; t=1726997020; cv=pass;
d=google.com; s=arc-20240605;
b=GObO5PB4xNkCsKlhuVElyUT9UzNBWoq7kAJFpazaOw160cG9RSzVEI0DlqSlWlHZgd
x/rS1VEmTUALBkyaOA1sKSkM6dh1hwSGotpAvsM0B7MIntLJ+wYLzarMgftc/VvavUnT
UTe+NWRUNScYNhN5HzY1cnEoPpCytF29W5k10iXKbb/xZqd3VqqmRYuWNT5/WPTzdnCE
S9nfhYCptDK+5yDmiuVPFt3ki1lelnJ1KxFi74zEAekkPlkqNmLss8XIYOZSLNJ/voAG
n8yA4UlwF6QyUta6bfLc/iH+yEN3omnRVE51BViQFGfyFh0r+EI4CIbuRvqdffvrWQFF
Wa2Q==
ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com;
s=arc-20240605;
h=list-unsubscribe:list-archive:list-help:list-post:list-id
:mailing-list:precedence:mime-version:references:in-reply-to
:message-id:date:subject:cc:to:from:dkim-signature;
bh=j2Io9KP0o8RPAShVbJcT4KynydBaUXiI7rOd3Hrv36Q=;
fh=XqS87H4LBtUUn/7ENxI7ZjN7NjZLyjMxY0xNWbssQL0=;
b=ai8g3JJ9+7EK3a3AmPxCRufe/zsiQedDIbrWJSouVIjyDKJrIavzmyjk1WFl+jffyC
Wko3p2w8wFtm4io9Wm5ojzHwJ64VkisVbggimUzkw5gTywjyBTbWs4TykFgMssDQAw4g
ENYXRD6c2buGzKifRQBnUxhepeDcKBvQs2lkM8512oIdPpH12uUXPZR/6hX53Q0pPmBW
BwH/xA0Jq0u3Au5cEGnDcIerBIJO5hUkGgcO75K+hzcjlmSlPNZFaDRzDUf3XR/yNkmd
IzOE1eeHPK67W03sryyjdU4MQO9Dmq60KW3fvnOXIV+eEbNmBzk5PE6Z6Lja/CcyqxAe
zz4w==;
darn=patchwork.amarulasolutions.com
ARC-Authentication-Results: i=2; mx.google.com;
dkim=pass header.i=@amarulasolutions.com header.s=google
header.b=OuADWZCh;
spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com
designates 209.85.220.41 as permitted sender)
smtp.mailfrom=dario.binacchi@amarulasolutions.com;
dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com;
dara=pass header.i=@amarulasolutions.com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=amarulasolutions.com; s=google; t=1726997020; x=1727601820;
darn=patchwork.amarulasolutions.com;
h=list-unsubscribe:list-archive:list-help:list-post:list-id
:mailing-list:precedence:x-original-authentication-results
:x-original-sender:mime-version:references:in-reply-to:message-id
:date:subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to;
bh=j2Io9KP0o8RPAShVbJcT4KynydBaUXiI7rOd3Hrv36Q=;
b=C+RdD39hPuUdLClNI2rWJSVtMVVORFy1hlO2Q2MTVTI6xXzmPK+luN5qicfX70w51e
f9XHSQwQVrV+inYCrgKbp90kaoDExn8x9nAxWn9+bb8mvMNFWee5w9FbB3y1vRH5T4u3
x3oijXMk0VLxxx9V8wUuX354tPApCCQPVqM9s=
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20230601; t=1726997020; x=1727601820;
h=list-unsubscribe:list-archive:list-help:list-post
:x-spam-checked-in-group:list-id:mailing-list:precedence
:x-original-authentication-results:x-original-sender:mime-version
:references:in-reply-to:message-id:date:subject:cc:to:from
:x-beenthere:x-gm-message-state:from:to:cc:subject:date:message-id
:reply-to;
bh=j2Io9KP0o8RPAShVbJcT4KynydBaUXiI7rOd3Hrv36Q=;
b=PEDMXPzESMcAnuDcY1akqNH31ui8rVbfAUcAXtJ2tc0Rn3tfOPvhm/TBfPoYHS4cE7
DTQvqTGkjyoWgMNZRWFFs7gre3T8dM3r7VRvvCBjdWxVhrthxMu43AwXrM7Vvs4I/IHL
Gfbybx/I4lHKrV0wHDyAqIVRh9348HTYON7fNanbWEO+lfX8RkMjg6DSfxOC10ebRZta
F+bMMvJz/WXFW8Y59i+bWzKdF+5smAWXZcDog4CDzhqknUSZpwoo2hBszwNqHY8tdukQ
I2jXInWvy13teGRsMg7uZ37PBxohxqjNc1XZPzTy8fRXSi6/QC+NcjJ7xGC3onUorHwv
PUNg==
X-Forwarded-Encrypted: i=2;
AJvYcCWz7JEgjV0MJx6G5tiw41PbwjH91h8BCHi0qNP5m2NPyu/HnfYHergAU5/E0FzJ1PLedoUV1fJnTNDGSCO1@patchwork.amarulasolutions.com
X-Gm-Message-State: AOJu0Ywn4mMUdvlIV58xdfOevGRFygm9JotKrH1Xy53Jv3EyezEUIojO
eV82bp29Pd585acIUqMRHeG6e76894D0JWyY6Oydx3bcl4fUihLVhubvmMpl0rS9Mg==
X-Google-Smtp-Source:
AGHT+IFSFQjmyofoio8iNB0CJcnzztUev/ooRb5lA7EpQlSdc6oGx8qjF01Rf74AMqA97BuSLwo1ww==
X-Received: by 2002:a05:6402:d0a:b0:5c4:2f65:cc28 with SMTP id
4fb4d7f45d1cf-5c464dfbc6bmr6910621a12.31.1726997020099;
Sun, 22 Sep 2024 02:23:40 -0700 (PDT)
X-BeenThere: linux-amarula@amarulasolutions.com
Received: by 2002:a05:6402:234d:b0:5bf:bf:efe4 with SMTP id
4fb4d7f45d1cf-5c45994f1bfls1329265a12.2.-pod-prod-08-eu; Sun, 22 Sep 2024
02:23:38 -0700 (PDT)
X-Forwarded-Encrypted: i=2;
AJvYcCWS/Zqv5nc0KBjusjzBFfTYRr1TqgWtI8TVBTSQBgJuhkeW3snn9sTUP+4KP31suvFpK6iGCK19rczVxPxv@amarulasolutions.com
X-Received: by 2002:a17:906:c10c:b0:a86:a56a:3596 with SMTP id
a640c23a62f3a-a90d58c9befmr861960966b.60.1726997018531;
Sun, 22 Sep 2024 02:23:38 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1726997018; cv=none;
d=google.com; s=arc-20160816;
b=AYWan9eWhi0TIzs8v3hF/U/KTdxc9+8KShGc1r+m7dThTPBgD70NHAheyRsls6LBKz
G8MbGBSS7CCp0fAqQY3iOZcNfdc4gyFEcQyUOhDcBUwK4r1VDgLx3FgJagYXJ7IBpbG0
vzeRhXMGVmromWxBNNEFoQ5AnhC8KhzSAUbF8NMdRosYvoJK5C/i0f2g9slZshpKH5y+
xhQxKZEu++NujqUdSrp4bSJdgjJrDc3PIHMGdrOyQe5DHtAPoMicEjfWQxntyyVb6XJ8
0/3c3G6f3XNmBvByP+tDbVs/PRtbn2vwESQfPNJRGwdO194mPPRg9KIgs3Il15sj7e8k
cDjw==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com;
s=arc-20160816;
h=content-transfer-encoding:mime-version:references:in-reply-to
:message-id:date:subject:cc:to:from:dkim-signature;
bh=BqQnF3E7ciw9GbEgIOpbevSW9KmfWN9UV4R/GKU3/vQ=;
fh=QrcKTdnITlSdy/pSwUGewr5EA4x6U75Cxocfcra6MR8=;
b=jtWubawTaUFR/k/t884acZR7hCJtzHnAbNFOGCJHUUUX9n0BQnzYWWNSZmhPQ7N7Hp
K5R8A4sYLSJwB1R/3NFu4dfUOvNSkVfjKRnjUWxThrO4PqIey1+9KqfBi9PhvafAd8Lv
tEU8BFJ/RGWDbPENICgmJqRvmIc4AxRxOtab88tA6NjMVUOSkIAD99JbSuhVH+vFgFYb
3Q5ULJyyN+ONiVUTZvkITG1fJLTpmcLop3hxmbFuZlfFDQW3TpqM/CgS3nBCoA1Rhj1d
wfogV5xsbDoXyB6f5zicZAfwEQg3KPpuoloI1+aXmtotpf51sHl21JtjIe6n2pQZMcOl
t47A==;
dara=google.com
ARC-Authentication-Results: i=1; mx.google.com;
dkim=pass header.i=@amarulasolutions.com header.s=google
header.b=OuADWZCh;
spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com
designates 209.85.220.41 as permitted sender)
smtp.mailfrom=dario.binacchi@amarulasolutions.com;
dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com;
dara=pass header.i=@amarulasolutions.com
Received: from mail-sor-f41.google.com (mail-sor-f41.google.com.
[209.85.220.41])
by mx.google.com with SMTPS id
a640c23a62f3a-a90612ef517sor477796166b.18.2024.09.22.02.23.38
for <linux-amarula@amarulasolutions.com>
(Google Transport Security);
Sun, 22 Sep 2024 02:23:38 -0700 (PDT)
Received-SPF: pass (google.com: domain of dario.binacchi@amarulasolutions.com
designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41;
X-Forwarded-Encrypted: i=1;
AJvYcCUX7pfDe7o3lioVdp2CYLf2POZwNRqMg2gBNNC/kc9C1MYU+Dk+QE5ZJBKpc4Y4bnAiIm9NQ5qdlJuFLpeu@amarulasolutions.com
X-Received: by 2002:a17:907:e656:b0:a80:7193:bd93 with SMTP id
a640c23a62f3a-a90d565bf4cmr904021866b.25.1726997018087;
Sun, 22 Sep 2024 02:23:38 -0700 (PDT)
Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it
(host-79-20-102-52.retail.telecomitalia.it. [79.20.102.52])
by smtp.gmail.com with ESMTPSA id
a640c23a62f3a-a90612b33fasm1065235866b.139.2024.09.22.02.23.37
(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
Sun, 22 Sep 2024 02:23:37 -0700 (PDT)
From: Dario Binacchi <dario.binacchi@amarulasolutions.com>
To: buildroot@buildroot.org
Cc: Giulio Benetti <giulio.benetti@benettiengineering.com>,
Waldemar Brodkorb <wbx@openadk.org>,
Romain Naour <romain.naour@gmail.com>,
Dario Binacchi <dario.binacchi@amarulasolutions.com>,
Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
yann.morin.1998@free.fr,
Ben Wolsieffer <Ben.Wolsieffer@hefring.com>,
linux-amarula@amarulasolutions.com,
Ben Wolsieffer <ben.wolsieffer@hefring.com>
Subject: [PATCH v2 4/9] arch/arm: add support for FDPIC
Date: Sun, 22 Sep 2024 11:23:07 +0200
Message-ID: <20240922092312.2061358-5-dario.binacchi@amarulasolutions.com>
X-Mailer: git-send-email 2.43.0
In-Reply-To: <20240922092312.2061358-1-dario.binacchi@amarulasolutions.com>
References: <20240922092312.2061358-1-dario.binacchi@amarulasolutions.com>
MIME-Version: 1.0
X-Original-Sender: dario.binacchi@amarulasolutions.com
X-Original-Authentication-Results: mx.google.com; dkim=pass
header.i=@amarulasolutions.com header.s=google header.b=OuADWZCh;
spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com
designates 209.85.220.41 as permitted sender)
smtp.mailfrom=dario.binacchi@amarulasolutions.com;
dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com;
dara=pass header.i=@amarulasolutions.com
Content-Type: text/plain; charset="UTF-8"
Precedence: list
Mailing-list: list linux-amarula@amarulasolutions.com;
contact linux-amarula+owners@amarulasolutions.com
List-ID: <linux-amarula.amarulasolutions.com>
X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com
X-Google-Group-Id: 476853432473
List-Post:
<https://groups.google.com/a/amarulasolutions.com/group/linux-amarula/post>,
<mailto:linux-amarula@amarulasolutions.com>
List-Help:
<https://support.google.com/a/amarulasolutions.com/bin/topic.py?topic=25838>,
<mailto:linux-amarula+help@amarulasolutions.com>
List-Archive:
<https://groups.google.com/a/amarulasolutions.com/group/linux-amarula/>
List-Unsubscribe:
<mailto:googlegroups-manage+476853432473+unsubscribe@googlegroups.com>,
<https://groups.google.com/a/amarulasolutions.com/group/linux-amarula/subscribe>
|
| Series |
add ARM FDPIC support
|
|
Commit Message
Dario Binacchi
Sept. 22, 2024, 9:23 a.m. UTC
From: Ben Wolsieffer <ben.wolsieffer@hefring.com> Linux on ARM supports FDPIC binaries intended for use on no-MMU systems. This patch enables support for building a toolchain that produces FDPIC binaries. The target name for a FDPIC toolchain must be arm-<vendor>-uclinuxfdpiceabi, which doesn't follow the standard format and requires a special case. According to the kernel help for CONFIG_BINFMT_ELF_FDPIC, "It is also possible to run FDPIC ELF binaries on MMU linux," so FDPIC support is available on all ARM platforms, not just no-MMU. Signed-off-by: Ben Wolsieffer <Ben.Wolsieffer@hefring.com> Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com> --- No changes since v1 arch/Config.in | 1 + package/Makefile.in | 6 ++++++ 2 files changed, 7 insertions(+)
Comments
On Sun, 22 Sep 2024 11:23:07 +0200 Dario Binacchi <dario.binacchi@amarulasolutions.com> wrote: > The target name for a FDPIC toolchain must be > arm-<vendor>-uclinuxfdpiceabi, which doesn't follow the standard format > and requires a special case. > > According to the kernel help for CONFIG_BINFMT_ELF_FDPIC, "It is also > possible to run FDPIC ELF binaries on MMU linux," so FDPIC support is > available on all ARM platforms, not just no-MMU. but then I guess the tuple would not be arm-<vendor>-uclinuxfdpiceabi, but something with "linux" instead? Did you test this support for FDPIC on MMU systems? Unless it has been tested to be working, I believe I would prefer to allow FDPIC only on noMMU systems, for which it has been tested. Thanks! Thomas
diff --git a/arch/Config.in b/arch/Config.in index 52efe3aabda1..cd258b2530d8 100644 --- a/arch/Config.in +++ b/arch/Config.in @@ -39,6 +39,7 @@ config BR2_arceb config BR2_arm bool "ARM (little endian)" + select BR2_ARCH_HAS_FDPIC_SUPPORT # MMU support is set by the subarchitecture file, arch/Config.in.arm help ARM is a 32-bit reduced instruction set computer (RISC) diff --git a/package/Makefile.in b/package/Makefile.in index 808b71a93e99..829636900ba9 100644 --- a/package/Makefile.in +++ b/package/Makefile.in @@ -39,7 +39,13 @@ $(error BR2_TOOLCHAIN_BUILDROOT_VENDOR cannot be 'unknown'. \ endif # Compute GNU_TARGET_NAME +# FDPIC on ARM requires a special target name: it has no OS field and must +# use the suffix -uclinuxfdpiceabi. +ifeq ($(BR2_arm)$(BR2_armeb):$(BR2_BINFMT_FDPIC),y:y) +GNU_TARGET_NAME = $(ARCH)-$(TARGET_VENDOR)-uclinuxfdpiceabi +else GNU_TARGET_NAME = $(ARCH)-$(TARGET_VENDOR)-$(TARGET_OS)-$(LIBC)$(ABI) +endif # FLAT binary format needs uclinux, except RISC-V which needs the # regular linux name.