From patchwork Sun Sep 22 09:23:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 3500 Return-Path: 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 EF8CD40D67 for ; Sun, 22 Sep 2024 11:23:36 +0200 (CEST) Received: by mail-ed1-f70.google.com with SMTP id 4fb4d7f45d1cf-5c5b83b6718sf1046626a12.3 for ; Sun, 22 Sep 2024 02:23:36 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1726997016; cv=pass; d=google.com; s=arc-20240605; b=Yahi3Y9/ANnnQ9NflHaNXCZIfhJjfTiXHxEjWRKsB46zQGZSs/UVxoqW9zZETfUQ3x xPvhX/cCU845Rh7/mrGsMFGtcG7b41hXcxAYd2kgHqNfq7cCTwSSAyf5DCCJrIEHfhKq kC8CBMP3WUo6TagLJqB1TKSfwUyaPgRQoJzVR3h7dWEPiJTiEpAN01NQlOv8tOYbIN/7 A7IFGd6yhc2y9Xwy5Oku7adYnb8rocILQah1Fdm/BQFcC9CisFrLXDEakVJufRaSZgg9 +jHwInO1n7FR9PckS1YqB6Oqflc19ZASCD9yAw/WNjo0Pc7wVWgoM5oY0sJ+gRNXHKV0 wutw== 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=Ik3bG4NykGNTNBjGnmKq6QQXWgCpvoIlniPgl2L+2RQ=; fh=MayP9cNA89VsqNbN9/K1cPrF9aD5EWaETdBqHmJ56rM=; b=RsaPNANzdanQWbLjrX7i+Uc0qpZxACoRC4Tb0+Oixygf2u4l5QmGEyKMAfHsSPIFVr lnGdaqfO/wuftwRuGVpVrbXYN4STfxaVWZpFhgw44/b3mYQjaMPR0ZktIZnzaEMffSsV ecS/TskF9Dy++q5KQilBEoUR/OrL7WocmozyMN3n+NkCHEMd9W50ANAlfbGjNOe5nz/b 59hk4V/LuvyOC4BKnIiwmzIHvTuL1rUOZC0ECT43V1vpWrbDBa5CWc5KOZFQM0PfMb3Y dNeWAPVHrXiujrczDswCOkvC0HiIFYjI9t/hbAcrDOJS9UmdVTeg44DzT65CtWbF1ZIK Y9UA==; darn=patchwork.amarulasolutions.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=F+q2Neeh; 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=1726997016; x=1727601816; 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=Ik3bG4NykGNTNBjGnmKq6QQXWgCpvoIlniPgl2L+2RQ=; b=dn4r+Sec9OKxcNLbh1leb2Vcbh11J+o9kYqjyQAhHuQmQCHR0K87aVd4jGrK6fe9Z7 0208zMe410CFUd3Nj9it2kF5CTmwA05x4mQFrVKXBy1lgdl1MgawKU+fWL3fvkTiz8/T mRmRjRAHMET+OSg9ZUkT9nfALLDH58/yHcdfY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726997016; x=1727601816; 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=Ik3bG4NykGNTNBjGnmKq6QQXWgCpvoIlniPgl2L+2RQ=; b=DwVkxzkMfPtCxIkDRTK0xikblR7wSalsaVFibFdqKryYeHh9nlzZbF+GIktYhxWnO9 ZoWozDnKePQ76dyi+p4ogqg6gEVdgc+x9lygQqJXJyKQewNqV3vrSop6HgyagbOLs6VI Ltv+ZbSrc/kQ7MfcopmeLX/b3FBMbOsq8UTxkXlTCzb6vCbyx8Xe+fPvuthx7LZN4BFD tu7YCaPRZhbAJSFH10+SddMcZSHqWWZ+MjbncVuP1Gl2GeF/g/Kh6KRUruBJD+u0nyxK i5dsuxgbzlZxgwkPjAac95tEQ8lUHdB8p0Y+VGh0Z3WhwbhXNTvnRpo4I1f3MnodbEQ5 Z1gA== X-Forwarded-Encrypted: i=2; AJvYcCVR5B6y1HBiF+rz91e0hA4JXtma6MKGOa+/ADoxWiJxuOo6j1mcujRJpFc9Efam31IBor2SPfnbImEQl9I0@patchwork.amarulasolutions.com X-Gm-Message-State: AOJu0Yz769g8mhmNwZ9UikuspduJn9ZG7aduFMbEOXFUZwT2wFneOowS ZEhyc5TVFnoAIFyRlptgRNQQt82pbvFFN89xAz0Feq41qusHjg2L757l54O3RZZetQ== X-Google-Smtp-Source: AGHT+IFsDP5ho5ICTdSYHc8HdvFlan3PGgMQ2ojZk3rq/ieS25ySDT9DWHC5FlLhAaBeRzsPbtBreQ== X-Received: by 2002:a05:6402:5113:b0:5c2:6311:8445 with SMTP id 4fb4d7f45d1cf-5c464a3855dmr5638593a12.2.1726997016139; Sun, 22 Sep 2024 02:23:36 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6402:35cf:b0:5c4:2278:28dd with SMTP id 4fb4d7f45d1cf-5c45995355als1324384a12.2.-pod-prod-06-eu; Sun, 22 Sep 2024 02:23:34 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCX1ksKede3SQNcWm7/ifwQxQ9m5wDhq6W8tK5H8fvMBIHSTzCN2oFht8zfmz2DHESNyJDPLTSV6aI5AZq6Q@amarulasolutions.com X-Received: by 2002:a17:907:e6a7:b0:a8a:87d5:2f5e with SMTP id a640c23a62f3a-a90d4ffc882mr768272466b.34.1726997014354; Sun, 22 Sep 2024 02:23:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1726997014; cv=none; d=google.com; s=arc-20160816; b=A3RwHSRc8jzCegOoriHwes4kASrOIyn5f2GIVYgL/DgDSyEnIZ+IIhQd+hBjDtu6Va TXR/vFs2koPJEy4xIlFZ6GtMKbV3RTh4Gv+8WS1uDIiFld4uPebdy66VGfKvgKz+k4mL dTWEbiYhVhz0871IQoOy5UhrclTi496Rd1XP9hW12GEC7uJcGM6FyJOdqhrGeCQqQ0PL L9b7voi/V7Z06g2UNqVHyneW3OZ+Qs/mvgJjGJqbOeBoHcdaSCwh/Qm86cFUTZpkhCyG bXQIu8q8vdlUzo4HoiW1VWdO36sDY7XGHj79HKpyUsms76OQZ7/y15JA3uefD3oaqOyR egjw== 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=A1fwdrkxR9UaBIlKgHknDI6TdyU+F9Gj3rb8SiV9Hkk=; fh=M9nsWg8ljrhe9WXOZbDA7QdFBGYmcFbKMCxSiSVbZZc=; b=x3jZwr+6IQIMNv+MWTUQKZzOqQbDv3eu2S3Ui7m1bk3OgtbtXfq8skFYfMYWGNEAKx x77OQcJErgozSsje78ZC1HwLzdkdpomlHtQt16fioaR8KZJUT7kuzl8r7wxSdy2aUAv1 uKUWPTQtwYL3AuAZT2Zv7UP5MF1Z3DkWiUpmXhNEUQZQhiPhnZqfRmUMitVFBx+AJhxg MlZnEKrxaIXs/Nq6gDrRBZmGB4iOdYiRsS1vT/uIFVm6+YluBCEksT0tQ3+JnFQ2xZHx i8O6eWSBTicKG6KkoW3Kgy5HMAlIKtTurJ3sgDuMB8rdTATFvG1RPx5Y/6BcwloLrMTj IJIQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=F+q2Neeh; 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-a90610f11dcsor644636266b.5.2024.09.22.02.23.34 for (Google Transport Security); Sun, 22 Sep 2024 02:23:34 -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; AJvYcCUSflGgm0V4apUeRFb6VoIX4xjyDv4kXlmseFmR16V94DYPKV5ypPpuH7AaieHnsStrvK3KaQgtNrInlQ9h@amarulasolutions.com X-Received: by 2002:a17:906:c113:b0:a86:af10:6a47 with SMTP id a640c23a62f3a-a90d51093famr883238666b.60.1726997013831; Sun, 22 Sep 2024 02:23:33 -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.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 22 Sep 2024 02:23:32 -0700 (PDT) From: Dario Binacchi To: buildroot@buildroot.org Cc: Giulio Benetti , Waldemar Brodkorb , Romain Naour , Dario Binacchi , Thomas Petazzoni , yann.morin.1998@free.fr, Ben Wolsieffer , linux-amarula@amarulasolutions.com, Ben Wolsieffer Subject: [PATCH v2 1/9] Revert: "arch: drop now useless support for FDPIC" Date: Sun, 22 Sep 2024 11:23:04 +0200 Message-ID: <20240922092312.2061358-2-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=F+q2Neeh; 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: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Ben Wolsieffer This reverts commit 58dcd28dfbed481becb822b009583a63efbc6ffa. ARM supports FDPIC, so this code is needed once again. Signed-off-by: Ben Wolsieffer Signed-off-by: Waldemar Brodkorb Signed-off-by: Dario Binacchi --- No changes since v1 arch/Config.in | 14 ++++++++++++++ package/uclibc/uclibc.mk | 7 +++++++ 2 files changed, 21 insertions(+) diff --git a/arch/Config.in b/arch/Config.in index 2e7ac080efc5..bd5f9ce47058 100644 --- a/arch/Config.in +++ b/arch/Config.in @@ -12,6 +12,9 @@ config BR2_SOFT_FLOAT config BR2_USE_MMU bool +config BR2_ARCH_HAS_FDPIC_SUPPORT + bool + choice prompt "Target Architecture" default BR2_i386 @@ -430,6 +433,7 @@ endif choice prompt "Target Binary Format" default BR2_BINFMT_ELF if BR2_USE_MMU + default BR2_BINFMT_FDPIC if BR2_ARCH_HAS_FDPIC_SUPPORT default BR2_BINFMT_FLAT config BR2_BINFMT_ELF @@ -441,6 +445,16 @@ config BR2_BINFMT_ELF and executables used across different architectures and operating systems. +config BR2_BINFMT_FDPIC + bool "FDPIC" + depends on BR2_ARCH_HAS_FDPIC_SUPPORT + select BR2_BINFMT_SUPPORTS_SHARED + help + ELF FDPIC binaries are based on ELF, but allow the individual + load segments of a binary to be located in memory + independently of each other. This makes this format ideal for + use in environments where no MMU is available. + config BR2_BINFMT_FLAT bool "FLAT" depends on !BR2_USE_MMU diff --git a/package/uclibc/uclibc.mk b/package/uclibc/uclibc.mk index de834bac4f2a..600d72ce7ba8 100644 --- a/package/uclibc/uclibc.mk +++ b/package/uclibc/uclibc.mk @@ -57,6 +57,13 @@ UCLIBC_LOCALES = \ endif # noMMU binary formats +ifeq ($(BR2_BINFMT_FDPIC),y) +define UCLIBC_BINFMT_CONFIG + $(call KCONFIG_DISABLE_OPT,UCLIBC_FORMAT_FLAT,$(@D)/.config) + $(call KCONFIG_DISABLE_OPT,UCLIBC_FORMAT_FLAT_SEP_DATA,$(@D)/.config) + $(call KCONFIG_ENABLE_OPT,UCLIBC_FORMAT_FDPIC_ELF,$(@D)/.config) +endef +endif ifeq ($(BR2_BINFMT_FLAT),y) define UCLIBC_BINFMT_CONFIG $(call KCONFIG_ENABLE_OPT,UCLIBC_FORMAT_FLAT)