From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jonathan Larmour To: Gary Thomas Cc: Dave Airlie , ecos-discuss@sources.redhat.com, Grant Edwards Subject: Re: [ECOS] PID ROM and eCos Date: Wed, 24 Jan 2001 11:39:00 -0000 Message-id: <3A6F2F81.9DDB2A5E@redhat.com> References: X-SW-Source: 2001-01/msg00413.html Gary Thomas wrote: > > On 24-Jan-2001 Jonathan Larmour wrote: > > Gary Thomas wrote: > >> > >> Look at the startup code for the Cirrus Logic EDB7xxx boards. They > >> support this configuration where the image in ROM (FLASH or whatever) > >> is linked at an address different from where they are stored. If > >> this case is detected, the ROM code simply gets copied to RAM at > >> startup time. Look in the file: > >> hal/arm/edb7xxx/current/include/hal_platform_setup.h > > > > Why was it done this way, and not with a more explicit ROMRAM startup type? > > If you have a separate startup type it is more under user control. > > > > It has been this way for more than 18 months - long before the new CDL and > the tools to make adding new/different startup types simple. Also, I only > did it in a moment since running some code on that platform did not perform > adequately from FLASH, but would from RAM. Good answer :-). > > Anyway, you can also refer to the way the mips vrc4373 or sh edk7708 do it, > > which use an explicit ROMRAM startup. > > And all the trappings [read details and troubles] that go with it. Firstly, it should be down to the user on whether they want to copy to RAM. But also I've done other work (Gary can probably guess what) this way and it was no real trouble. The only problem is determining real addresses before relocation, but that's easy too. With the ARM you could even use MMU tricks, but I wouldn't recommend it :). Jifl -- Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062 Un cheval, pas du glue. Pas du cheval, beaucoup du glue. || Opinions==mine