From patchwork Fri Feb 6 22:06:46 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_Bie=C3=9Fmann?= X-Patchwork-Id: 437701 X-Patchwork-Delegate: andreas.biessmann@googlemail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id B8C93140172 for ; Sun, 8 Feb 2015 23:32:37 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id A34764A04E; Sun, 8 Feb 2015 13:32:31 +0100 (CET) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id x7GYBTq5_8mC; Sun, 8 Feb 2015 13:32:31 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 662FD4B174; Sun, 8 Feb 2015 13:32:21 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id C8AD24B5B9 for ; Fri, 6 Feb 2015 23:07:54 +0100 (CET) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id QrUISaIyX7oo for ; Fri, 6 Feb 2015 23:07:54 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-we0-f180.google.com (mail-we0-f180.google.com [74.125.82.180]) by theia.denx.de (Postfix) with ESMTPS id 523154A054 for ; Fri, 6 Feb 2015 23:07:48 +0100 (CET) Received: by mail-we0-f180.google.com with SMTP id m14so16286157wev.11 for ; Fri, 06 Feb 2015 14:07:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=QGtKVJ9s+X1GqVx/DnhPm+iFm4oR4I8OuUQ3mLNXT+o=; b=KUFqO4tWt8is4nO2GcoT2c6TzOKQgVcw0OPXpsTUCsUWfT7Da9J4KwVH1/2jW/kNXC fP+y5egiyB3F17sAsmfhHyHUQUAtsxJrP5WxK0LwpH78DHF/Z7T/8mrpPkWhVWk2e1hs NRJprSKJyDGsEIw8WcgWjtZwfAgK6PM+LjpN6tqojKC2iJJ4FCrRwalLMmsFdqFkZe/8 9Vphxy6uSA9xvH8/bbmNsSRuNTOFipK944O09AJ1GSG3b3gGtiOUc31VM/3DNXiWemdH C3ZswYZGMxGPjyA0woXGKZqqZhdaH5l+mPCFsm/fY09VCCb1NtcwR9WIQc68RWD14OLq 8n7g== X-Received: by 10.194.61.65 with SMTP id n1mr12650940wjr.53.1423260468577; Fri, 06 Feb 2015 14:07:48 -0800 (PST) Received: from localhost (dockstar.er.biessmann.org. [2a01:198:47b:1::10]) by mx.google.com with ESMTPSA id r3sm3150643wic.10.2015.02.06.14.07.47 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 06 Feb 2015 14:07:47 -0800 (PST) From: =?UTF-8?q?Andreas=20Bie=C3=9Fmann?= To: U-Boot List Date: Fri, 6 Feb 2015 23:06:46 +0100 Message-Id: <1423260410-9290-9-git-send-email-andreas.devel@googlemail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1423260410-9290-1-git-send-email-andreas.devel@googlemail.com> References: <1423260410-9290-1-git-send-email-andreas.devel@googlemail.com> MIME-Version: 1.0 X-Mailman-Approved-At: Sun, 08 Feb 2015 13:32:15 +0100 Cc: Jeroen Hofstee , Kim Phillips , Waldemar Brodkorb , Kumar Gala , Thierry Reding , Ian Campbell , Andy Fleming , Stefan Roese Subject: [U-Boot] [PATCH v3 08/12] common/board_r: manual relocation for cmd table X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This is required for architectures still need manual relocation like avr32, m68k microblaze and maybe others. Signed-off-by: Andreas Bießmann Reviewed-by: Simon Glass Tested-by: Michal Simek --- Changes in v3: None Changes in v2: None Changes in v1: None common/board_r.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/common/board_r.c b/common/board_r.c index 68a9448..f7a3b55 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -294,6 +294,15 @@ static int initr_announce(void) return 0; } +#ifdef CONFIG_NEEDS_MANUAL_RELOC +static int initr_manual_reloc_cmdtable(void) +{ + fixup_cmdtable(ll_entry_start(cmd_tbl_t, cmd), + ll_entry_count(cmd_tbl_t, cmd)); + return 0; +} +#endif + #if !defined(CONFIG_SYS_NO_FLASH) static int initr_flash(void) { @@ -702,6 +711,9 @@ init_fnc_t init_sequence_r[] = { initr_serial, initr_announce, INIT_FUNC_WATCHDOG_RESET +#ifdef CONFIG_NEEDS_MANUAL_RELOC + initr_manual_reloc_cmdtable, +#endif #ifdef CONFIG_PPC initr_trap, #endif