From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([2001:6f8:1178:4:290:27ff:fe1d:cc33]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XbVf2-0008Ha-6y for barebox@lists.infradead.org; Tue, 07 Oct 2014 14:22:45 +0000 Received: from dude.hi.pengutronix.de ([2001:67c:670:100:1d::7]) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1XbVee-0003OR-SI for barebox@lists.infradead.org; Tue, 07 Oct 2014 16:22:20 +0200 Received: from jbe by dude.hi.pengutronix.de with local (Exim 4.84) (envelope-from ) id 1XbVee-0004Cv-R3 for barebox@lists.infradead.org; Tue, 07 Oct 2014 16:22:20 +0200 From: Juergen Borleis Date: Tue, 7 Oct 2014 16:22:03 +0200 Message-Id: <1412691738-11145-5-git-send-email-jbe@pengutronix.de> In-Reply-To: <1412691738-11145-1-git-send-email-jbe@pengutronix.de> References: <1412691738-11145-1-git-send-email-jbe@pengutronix.de> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "barebox" Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: [PATCH 04/19] arch/MPC5xxx: Simplify the calculation To: barebox@lists.infradead.org Signed-off-by: Juergen Borleis --- arch/ppc/mach-mpc5xxx/start.S | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/ppc/mach-mpc5xxx/start.S b/arch/ppc/mach-mpc5xxx/start.S index 291f625..6a32718 100644 --- a/arch/ppc/mach-mpc5xxx/start.S +++ b/arch/ppc/mach-mpc5xxx/start.S @@ -66,6 +66,7 @@ * Second stage loader entry. When entered here we assume that spr 311 * is set to the current MBAR address. */ +_base: mfspr r4, MBAR b setup_mbar . = EXC_OFF_SYS_RESET @@ -251,9 +252,8 @@ _continue_init: bl calc_source /* Calculate Source Address */ calc_source: - mfspr r4, LR - subi r4, r4, (calc_source - _start) - subi r4, r4, 0x100 + mflr r4 + subi r4, r4, (calc_source - _base) lis r5, __init_size@h /* Size */ ori r5, r5, __init_size@l -- 2.1.0 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox