This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: hal_platform_setup memory copying code
- From: Andrew Lunn <andrew at lunn dot ch>
- To: ecosrtos ecosrtos <ecosrtos at gmail dot com>
- Cc: ecos-discuss at ecos dot sourceware dot org
- Date: Mon, 31 Jan 2005 23:29:39 +0100
- Subject: Re: [ECOS] hal_platform_setup memory copying code
- References: <852b699905013114071c803440@mail.gmail.com>
On Mon, Jan 31, 2005 at 02:07:24PM -0800, ecosrtos ecosrtos wrote:
> Hi
> How do r1 and r0 get incremented in the following code. Is it implicit
> in some instruction?
>
> #if defined(CYG_HAL_STARTUP_ROMRAM)
> ldr r0,=0x01000000 // Relocate FLASH/ROM to on-chip RAM
> ldr r1,=0x02000000 // RAM base & length
> ldr r2,=0x02010000
> 20: ldr r3,[r0],#4
> str r3,[r1],#4
> cmp r1,r2
> bne 20b
> ldr r0,=30f
> mov pc,r0
> 30:
> #endif
Might be worth getting hold of:
http://www.amazon.com/exec/obidos/ASIN/0201737191/104-8943311-4719951
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss