Message ID | 665967054a5af6d3c673aeaa51ec629986a1a974.1655287429.git.michal.simek@amd.com |
---|---|
State | Superseded |
Delegated to: | Michal Simek |
Headers | show
Return-Path: <u-boot-bounces@lists.denx.de> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=monstr-eu.20210112.gappssmtp.com header.i=@monstr-eu.20210112.gappssmtp.com header.a=rsa-sha256 header.s=20210112 header.b=oHpW0maJ; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=<UNKNOWN>) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4LNLWZ75mzz9vF7 for <incoming@patchwork.ozlabs.org>; Wed, 15 Jun 2022 20:04:42 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BFC198447D; Wed, 15 Jun 2022 12:04:15 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=monstr.eu Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=monstr-eu.20210112.gappssmtp.com header.i=@monstr-eu.20210112.gappssmtp.com header.b="oHpW0maJ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 6375E8445C; Wed, 15 Jun 2022 12:04:11 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ed1-x530.google.com (mail-ed1-x530.google.com [IPv6:2a00:1450:4864:20::530]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 30A3F84431 for <u-boot@lists.denx.de>; Wed, 15 Jun 2022 12:04:09 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=monstr.eu Authentication-Results: phobos.denx.de; spf=none smtp.mailfrom=monstr@monstr.eu Received: by mail-ed1-x530.google.com with SMTP id b8so15320129edj.11 for <u-boot@lists.denx.de>; Wed, 15 Jun 2022 03:04:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monstr-eu.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=LZz9nMb41ih3udryM7OAU05cmrC0T5SgjXD/Ysd2FX8=; b=oHpW0maJQUyWUcH69DqMLMfg5UT13r0itIx/p1RzD8hvkHDeMBn8N0cMsDtCK0CY/6 pPHL4zaamQeZdE/J5IfmO0nklYaebUjJv7bD3Geych8gEqZRAmvdqeVAJRo5MWD+5TWm czwL81f8C+p7Hc9+Z83GnuAvxyyyGlu0LomPKKBjQLgiC+QyuFUgnPwXYswyTVoJCdzs Mv+HWAINxHSRZPSUbTnTiWuYBu8UZCIc3y31WO5cKcQv4jCcEX6S8C/ui3qyoyWEGo28 2n4xi62jD/AsEBZzdqLtga9ERxq4ClD41r9AOYyV0IGnu9mXeRQWaarCqj2Y7v6I2sNi TUtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=LZz9nMb41ih3udryM7OAU05cmrC0T5SgjXD/Ysd2FX8=; b=SawwWfsZV/ikAS8hTY1WF8JPuLwakRMhUfC7Bu8mp7L8xFooKiMwWfnvHhUEMKLsF7 DeIy3MjQlaxFybPKCqZA7O4O8l9Oc9LaH0wwe0E0XTbozHMWnvexFXWzG2Yd2ualsMA2 M1o5lYP4jtfKFFxbK5qV/tfHqfzVIHTCkjVkj8mCe1GYV40Cy6La1jeF5UBDwQyfcwG8 q2z8+EMaqKPUKVg77T680biL/+5CBJQCIoTYWRdROwTb8EJsptOglShbIUAzOjl4Ksgu ClCMcByqb6E6JPjjdFfacrTsN8b9KHtFcuNbHipjo9QgvQDvrqUpHFCvhEUaryeZ5yV7 +Z8A== X-Gm-Message-State: AJIora9XCwHpBYR7lofwg/LvaP4jc2AWFYVtC2vTf7Tp8QVBLBcA6Yg/ 3iY+N0OJxRnF751TyAYQQmXDRtDYOHXcWA== X-Google-Smtp-Source: AGRyM1ukd6RRNvhHSNXuAY7fAmojhVgQGbxeBbs3Hoaiso2TTdnnXZliYKYo2dN8H8MfvQ3brX9HrQ== X-Received: by 2002:a05:6402:5252:b0:42f:b566:c189 with SMTP id t18-20020a056402525200b0042fb566c189mr11485416edd.398.1655287448620; Wed, 15 Jun 2022 03:04:08 -0700 (PDT) Received: from localhost ([2a02:768:2307:40d6::f9e]) by smtp.gmail.com with ESMTPSA id b11-20020a056402350b00b0042de8155fa1sm9373535edd.0.2022.06.15.03.04.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Jun 2022 03:04:07 -0700 (PDT) From: Michal Simek <monstr@monstr.eu> X-Google-Original-From: Michal Simek <michal.simek@amd.com> To: u-boot@lists.denx.de, git@xilinx.com Cc: Alistair Delva <adelva@google.com> Subject: [PATCH v3 03/23] tools: relocate-rela: Use global variables Date: Wed, 15 Jun 2022 12:03:40 +0200 Message-Id: <665967054a5af6d3c673aeaa51ec629986a1a974.1655287429.git.michal.simek@amd.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <cover.1655287429.git.michal.simek@amd.com> References: <cover.1655287429.git.michal.simek@amd.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion <u-boot.lists.denx.de> List-Unsubscribe: <https://lists.denx.de/options/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=unsubscribe> List-Archive: <https://lists.denx.de/pipermail/u-boot/> List-Post: <mailto:u-boot@lists.denx.de> List-Help: <mailto:u-boot-request@lists.denx.de?subject=help> List-Subscribe: <https://lists.denx.de/listinfo/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=subscribe> Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" <u-boot-bounces@lists.denx.de> X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean |
Series |
microblaze: Add support for full relocation
|
expand
|
diff --git a/tools/relocate-rela.c b/tools/relocate-rela.c index 883987111869..67a138aa67d7 100644 --- a/tools/relocate-rela.c +++ b/tools/relocate-rela.c @@ -20,6 +20,8 @@ #define R_AARCH64_RELATIVE 1027 #endif +static uint64_t rela_start, rela_end, text_base; + static const bool debug_en; static void debug(const char *fmt, ...) @@ -63,7 +65,7 @@ int main(int argc, char **argv) { FILE *f; int i, num; - uint64_t rela_start, rela_end, text_base, file_size; + uint64_t file_size; if (argc != 5) { fprintf(stderr, "Statically apply ELF rela relocations\n");
Declare rela_start/end and text_base as global variables. It will help with using these variables for ELF decoding. Signed-off-by: Michal Simek <michal.simek@amd.com> --- (no changes since v1) tools/relocate-rela.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)