From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gRD27-0000f0-25 for barebox@lists.infradead.org; Mon, 26 Nov 2018 09:18:25 +0000 From: Oleksij Rempel Date: Mon, 26 Nov 2018 10:18:01 +0100 Message-Id: <20181126091807.19398-5-o.rempel@pengutronix.de> In-Reply-To: <20181126091807.19398-1-o.rempel@pengutronix.de> References: <20181126091807.19398-1-o.rempel@pengutronix.de> MIME-Version: 1.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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 v1 04/10] MIPS: start: preserve DTB pointer for later use To: barebox@lists.infradead.org Cc: Oleksij Rempel We will get DTB pointer in a0 register. Since a0 is used as argument by other functions, we need to preserve it and then pass as argument to the main_entry(). Signed-off-by: Oleksij Rempel --- arch/mips/boot/start.S | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/arch/mips/boot/start.S b/arch/mips/boot/start.S index e937e89af1..39ac9414d8 100644 --- a/arch/mips/boot/start.S +++ b/arch/mips/boot/start.S @@ -27,6 +27,10 @@ EXPORT(_start) mips_barebox_10h + /* save dtb pointer */ + move s0, a0 + move s1, a1 + /* disable watchpoints */ mtc0 zero, CP0_WATCHLO mtc0 zero, CP0_WATCHHI @@ -37,6 +41,9 @@ EXPORT(_start) stack_setup + /* restore dtb pointer */ + move a0, s0 + move a1, s1 la v0, main_entry jal v0 nop -- 2.19.1 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox