⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 trampoline.s

📁 UBOOT源码,希望能给大家一点帮助,费了好大心思弄来的.
💻 S
字号:
/* * trampoline.S: start of second stage boot loader, jump from assembly to C * * Copyright (C) 2001 Erik Mouw (J.A.K.Mouw@its.tudelft.nl) * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA * */.ident "$Id: trampoline.S,v 1.3 2001/10/28 20:34:41 erikm Exp $"#ifdef HAVE_CONFIG_H# include <blob/config.h>#endif.text.globl _trampoline_trampoline:	/* clear the BSS section */	ldr	r1, bss_start	ldr	r0, bss_end	sub	r0, r0, r1	/* r1 = start address */	/* r0 = #number of bytes */	mov	r2, #0clear_bss:	stmia	r1!, {r2}	subs	r0, r0, #4	bne	clear_bss	/* setup the stack pointer */	ldr	r0, stack_end	sub	sp, r0, #4	/* jump to C code */	bl	main	/* if main ever returns we just call it again */	b	_trampolinebss_start:	.word	__bss_startbss_end:	.word	__bss_endstack_end:	.word	__stack_end

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -