From patchwork Wed Aug 10 15:17:54 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 73666 Delivered-To: patch@linaro.org Received: by 10.140.29.52 with SMTP id a49csp456156qga; Wed, 10 Aug 2016 08:19:08 -0700 (PDT) X-Received: by 10.66.132.105 with SMTP id ot9mr8236327pab.88.1470842348222; Wed, 10 Aug 2016 08:19:08 -0700 (PDT) Return-Path: Received: from ml01.01.org (ml01.01.org. [2001:19d0:306:5::1]) by mx.google.com with ESMTPS id 15si48889042pfv.78.2016.08.10.08.19.07 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 10 Aug 2016 08:19:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) client-ip=2001:19d0:306:5::1; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id D1A651A1E64; Wed, 10 Aug 2016 08:18:56 -0700 (PDT) X-Original-To: edk2-devel@lists.01.org Delivered-To: edk2-devel@lists.01.org Received: from mail-wm0-x22e.google.com (mail-wm0-x22e.google.com [IPv6:2a00:1450:400c:c09::22e]) (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 DB3891A1E2C for ; Wed, 10 Aug 2016 08:18:55 -0700 (PDT) Received: by mail-wm0-x22e.google.com with SMTP id o80so111024906wme.1 for ; Wed, 10 Aug 2016 08:18:55 -0700 (PDT) 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=mU0Q2Fa27Jmco/TuBe2c0RzPcyXrI6XG3n80j4OmRhM=; b=Cq1OYTzaMU1SJNn08Un6ondP5DlBrhiK9ML6fgl5COgan0GSJHdm6b85iWMBzH2sdo x9QjipeiwxZy7PFabCUDkUno5skSggStl+ZFPsIg4QvwPklWuTtYoUoGLDwRcvzvHg50 DmUynVQ36LubMznmvJcFWeSfDH9IEtlxK0E18= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=mU0Q2Fa27Jmco/TuBe2c0RzPcyXrI6XG3n80j4OmRhM=; b=QWvVHYYqDzV0HedhPZSzG+rKwe3vNUN9FF9FC3h7Yq1EvL4DHdsAV5u10uNE8fRCDF nHKV6y+UhC0RkEnLqk/wunTV/11mAPQvGO2JlFZwUL6ivQJzInHF38FY2jL0YYfyo4UN a+DH5Yf6z6g6lS8JSAkZ+/gJ/+U67IfOWeYfnbZK3Vm03qHa5m/3l3ZHVEszfzvawqou +tF2nNT+4zG3JlM4meSrWtiErN1x9B0OXkQhwWdZ4Rv2/N9GkVacPIxKQBEH/WV4F6tK G0SekOHtq4MxsROwWqbd4A9+alG8SdbDzft2EQlAaQ2D6tmogTn3PjKLm46RDPlpvGEy iKjQ== X-Gm-Message-State: AEkoouvONO6qtbMC6GWCC46qmn4OdvjHy+spaj7/ZXb204ozt75mNPTy7PzDzMB3sB1lb45I X-Received: by 10.194.27.133 with SMTP id t5mr4442044wjg.15.1470842334309; Wed, 10 Aug 2016 08:18:54 -0700 (PDT) Received: from localhost.localdomain (46.red-81-37-107.dynamicip.rima-tde.net. [81.37.107.46]) by smtp.gmail.com with ESMTPSA id c16sm8908374wme.4.2016.08.10.08.18.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 10 Aug 2016 08:18:53 -0700 (PDT) From: Ard Biesheuvel To: edk2-devel@lists.01.org, leif.lindholm@linaro.org, eugene@hp.com Date: Wed, 10 Aug 2016 17:17:54 +0200 Message-Id: <1470842282-8415-19-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1470842282-8415-1-git-send-email-ard.biesheuvel@linaro.org> References: <1470842282-8415-1-git-send-email-ard.biesheuvel@linaro.org> Subject: [edk2] [PATCH 18/26] ArmPkg/SemihostLib: switch to ASM_FUNC() asm macro X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: lersek@redhat.com, Ard Biesheuvel MIME-Version: 1.0 Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel --- ArmPkg/Library/SemihostLib/AArch64/GccSemihost.S | 7 ++----- ArmPkg/Library/SemihostLib/Arm/GccSemihost.S | 8 ++------ 2 files changed, 4 insertions(+), 11 deletions(-) -- 2.7.4 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel diff --git a/ArmPkg/Library/SemihostLib/AArch64/GccSemihost.S b/ArmPkg/Library/SemihostLib/AArch64/GccSemihost.S index 42211cf4ff8f..43a780c9ed3e 100644 --- a/ArmPkg/Library/SemihostLib/AArch64/GccSemihost.S +++ b/ArmPkg/Library/SemihostLib/AArch64/GccSemihost.S @@ -13,11 +13,8 @@ # #------------------------------------------------------------------------------ -.text -.align 2 +#include -.globl ASM_PFX(GccSemihostCall) - -ASM_PFX(GccSemihostCall): +ASM_FUNC(GccSemihostCall) hlt #0xf000 ret diff --git a/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S b/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S index c9d13183f61e..770e512cfbca 100644 --- a/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S +++ b/ArmPkg/Library/SemihostLib/Arm/GccSemihost.S @@ -12,11 +12,7 @@ # #------------------------------------------------------------------------------ -.text -.align 2 - -.globl ASM_PFX(GccSemihostCall) -INTERWORK_FUNC(GccSemihostCall) +#include /* Semihosting operation request mechanism @@ -32,7 +28,7 @@ INTERWORK_FUNC(GccSemihostCall) the svc lr register. That happens to be the one we are using, so we must save it or we will not be able to return. */ -ASM_PFX(GccSemihostCall): +ASM_FUNC(GccSemihostCall) stmfd sp!, {lr} svc #0x123456 ldmfd sp!, {lr}