From nobody Mon Sep 16 19:20:15 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail(p=none dis=none) header.from=linaro.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1528817011397901.2309847307324; Tue, 12 Jun 2018 08:23:31 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 962C621295B29; Tue, 12 Jun 2018 08:23:30 -0700 (PDT) Received: from mail-wm0-x242.google.com (mail-wm0-x242.google.com [IPv6:2a00:1450:400c:c09::242]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 0A7F321295B20 for ; Tue, 12 Jun 2018 08:23:27 -0700 (PDT) Received: by mail-wm0-x242.google.com with SMTP id j15-v6so24217472wme.0 for ; Tue, 12 Jun 2018 08:23:27 -0700 (PDT) Received: from dogfood.home ([2a01:cb1d:112:6f00:3c84:18ae:27f2:d03]) by smtp.gmail.com with ESMTPSA id e2-v6sm500983wro.97.2018.06.12.08.23.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 12 Jun 2018 08:23:25 -0700 (PDT) X-Original-To: edk2-devel@lists.01.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a00:1450:400c:c09::242; helo=mail-wm0-x242.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=LfLa8F4gsA3noW+oCZVDVbZS3fyISFGwd6SyXz5CxJs=; b=Q6hdJHytDWnObdJpmnSIZdrFav0LlvegpdXuHGearOrqjKXOWRq5OPh1pu4uhoKzzf OF7QBMqzxQTV6GY6ctZR5eU1NS97qxUXqqAnjEM8UMVqlvDNAlGZJcoRK45y6OpPremK yphnCw1cTRQphSUudnaKTMu2TIsVVnoeKGgmU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=LfLa8F4gsA3noW+oCZVDVbZS3fyISFGwd6SyXz5CxJs=; b=crmOa6qNz19ma5wuB5PYvLe0mzzRcuaG33HbBVfzuAVtVB1olm2ip7yyzOQYDU/JBz 6mVIxDAuHAzo0YtQ8gN+LnqwLNKSJ/touCK3KVxwVWRql34StBXYVfNvdbnPwBOf5Gjc JNlvS6+JWlN15YrMti4yXDXJeAwgXe2gzsXhFoZ/lTC6Q6lqqWGY4bvONF8mHTsd5RsG 5lB/I9VzI/1cr83dtx2+MWrdr9UEiGSc+cXMN1UjQ6uvnD1mSdO1fFAecCm//zBfe5PO XmtIScx7Ixn4M+euFpBJ78ysEn0In6BPGE9t1ZNhZiTtMoa/eFgEkVm6qwgUZxQ/XcBA 7WXw== X-Gm-Message-State: APt69E2uu1BgnqXPTdsBoL8iMhz6mFCemIpX0PghkbKTcDo7sCLZKgyI ad1Of35VOfkhMtqQL2pmqTx3RtPqrvI= X-Google-Smtp-Source: ADUXVKK30PPgc/AUztUI/vT/7jXeRfUf2/s0NVSYwgg/yrZdshk4Jo0H1afWtX7SuD3QQLTiaR2TYw== X-Received: by 2002:a1c:f45:: with SMTP id 66-v6mr565986wmp.124.1528817006369; Tue, 12 Jun 2018 08:23:26 -0700 (PDT) From: Ard Biesheuvel To: edk2-devel@lists.01.org Date: Tue, 12 Jun 2018 17:22:56 +0200 Message-Id: <20180612152306.25998-2-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180612152306.25998-1-ard.biesheuvel@linaro.org> References: <20180612152306.25998-1-ard.biesheuvel@linaro.org> Subject: [edk2] [RFC PATCH 01/11] MdePkg/ProcessorBind.h: define macro to decorate module entry points X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ruiyu Ni , Eric Dong , Ard Biesheuvel , Hao Wu , Jordan Justen , Andrew Fish , Leif Lindholm , Liming Gao , Zenith432 , Michael D Kinney , Laszlo Ersek , Star Zeng MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Add a macro EFI_ENTRYPOINT that we will use to decorate functions that serve as the entry points for EFI modules. This is necessary to work around a limitation in GCC, which may prune such routines from the ELF binary if they are defined with hidden visibility, even if they are explicitly referenced as the entry point on the linker command line. The hidden visibility is required to inform the compiler that, even though we are building the code in PIE mode, we are only doing so to get code that can run anywhere in the address space without requiring 64-bit wide absolute symbol references, and we are not interested in other things that PIE code typically provides, such as symbol preemptability and a reduced CoW footprint due to the fact that all dynamic relocations target the same area in the binary. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ard Biesheuvel --- MdePkg/Include/Base.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/MdePkg/Include/Base.h b/MdePkg/Include/Base.h index 4f7bd4449c36..eee48dcd4b29 100644 --- a/MdePkg/Include/Base.h +++ b/MdePkg/Include/Base.h @@ -274,6 +274,13 @@ VERIFY_SIZE_OF (__VERIFY_UINT32_ENUM_SIZE, 4); #define PACKED #endif =20 +#ifndef EFI_ENTRYPOINT + // + // Set to empty value if not already set by the arch-specific header + // + #define EFI_ENTRYPOINT +#endif + /// /// 128 bit buffer containing a unique identifier value. /// Unless otherwise specified, aligned on a 64 bit boundary. --=20 2.17.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel