public inbox for ecos-devel@sourceware.org
 help / color / mirror / Atom feed
* Redboot - Cirrus EP9315 and Spansion S29GL512N problem
@ 2007-12-06  3:34 Hasjim Williams
  2007-12-06  4:29 ` Manfred Gruber
  0 siblings, 1 reply; 5+ messages in thread
From: Hasjim Williams @ 2007-12-06  3:34 UTC (permalink / raw)
  To: ecos-devel

Hello everyone,

I'm having problems getting my ARM920T based EP9315 board to work with
64MB flash.  We have 64MB of RAM onboard.  We previously had S29GL128N
and S29GL256N parts on the board, and haven't been able to get Redboot
to boot up correctly with the S29GL512N.  It works fine with the
S29GL256N or S29GL128N still.

As soon as it boots up, it spits out this error message, constantly:

#dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
#dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;

Can anyone suggest anything that I'm missing:

packages/devs/flash/arm/edb9312/current/cdl/flash_edb9312_a_amd.cdl:

    requires      CYGHWR_DEVS_FLASH_AMD_S29GL128N
    requires      CYGHWR_DEVS_FLASH_AMD_S29GL256N
    requires      CYGHWR_DEVS_FLASH_AMD_S29GL512N

packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.ldi:

MEMORY
{
    ram : ORIGIN = 0, LENGTH = 0x10000000
    rom : ORIGIN = 0x60000000, LENGTH = 0x8000000
}

packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.h:

#define CYGMEM_REGION_rom (0x60000000)
#define CYGMEM_REGION_rom_SIZE (0x8000000)
#define CYGMEM_REGION_rom_ATTR (CYGMEM_REGION_ATTR_R)

Thanks for any suggestions,


Hasjim Williams

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Redboot - Cirrus EP9315 and Spansion S29GL512N problem
  2007-12-06  3:34 Redboot - Cirrus EP9315 and Spansion S29GL512N problem Hasjim Williams
@ 2007-12-06  4:29 ` Manfred Gruber
  2007-12-06  5:29   ` Hasjim Williams
  0 siblings, 1 reply; 5+ messages in thread
From: Manfred Gruber @ 2007-12-06  4:29 UTC (permalink / raw)
  To: ecos-devel

hi !

i have worked for a company where ep93xx and spansion flashes are used, please 
look at http://dev.contec.at, there i have made a redboot bootloader which 
can handle such flashes, but i have used flash_v2 branche, so it will not 
help u.

> #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;

this things i have only seen if the mmu is set up wrong, so maybe it helps 
check your mmu settings in redboot. maybe the 512 chip adresses obverlap 
somewhere...

regards manfred
 mfg
	Manfred Gruber
	Software Engineering
	m.gruber@tirol.com
	http://www.manfred-gruber.at.tt
	http://www.myspace.com/fredl_grma  

Am Thursday 06 December 2007 schrieb Hasjim Williams:
> Hello everyone,
>
> I'm having problems getting my ARM920T based EP9315 board to work with
> 64MB flash.  We have 64MB of RAM onboard.  We previously had S29GL128N
> and S29GL256N parts on the board, and haven't been able to get Redboot
> to boot up correctly with the S29GL512N.  It works fine with the
> S29GL256N or S29GL128N still.
>
> As soon as it boots up, it spits out this error message, constantly:
>
> #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
>
> Can anyone suggest anything that I'm missing:
>
> packages/devs/flash/arm/edb9312/current/cdl/flash_edb9312_a_amd.cdl:
>
>     requires      CYGHWR_DEVS_FLASH_AMD_S29GL128N
>     requires      CYGHWR_DEVS_FLASH_AMD_S29GL256N
>     requires      CYGHWR_DEVS_FLASH_AMD_S29GL512N
>
> packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.
>ldi:
>
> MEMORY
> {
>     ram : ORIGIN = 0, LENGTH = 0x10000000
>     rom : ORIGIN = 0x60000000, LENGTH = 0x8000000
> }
>
> packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.
>h:
>
> #define CYGMEM_REGION_rom (0x60000000)
> #define CYGMEM_REGION_rom_SIZE (0x8000000)
> #define CYGMEM_REGION_rom_ATTR (CYGMEM_REGION_ATTR_R)
>
> Thanks for any suggestions,
>
>
> Hasjim Williams

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Redboot - Cirrus EP9315 and Spansion S29GL512N problem
  2007-12-06  4:29 ` Manfred Gruber
@ 2007-12-06  5:29   ` Hasjim Williams
  2007-12-06 23:29     ` Hasjim Williams
  0 siblings, 1 reply; 5+ messages in thread
From: Hasjim Williams @ 2007-12-06  5:29 UTC (permalink / raw)
  To: Manfred Gruber; +Cc: ecos-devel

I think I found the problem (which was MMU related):

--- packages/hal/arm/arm9/ep93xx/current/include/hal_platform_setup.h
+++ packages/hal/arm/arm9/ep93xx/current/include/hal_platform_setup.h
@@ -494,20 +494,20 @@
     //
     // Create a read-write mapping of FLASH at virtual address
     0x6000_0000.
     //
     add     r1, r0, #0x00001800
 #if defined(HAL_PLATFORM_EP9301) || defined(HAL_PLATFORM_EP9302)
     mov     r2, #0x00000040
 #else
     // If you are using a Flash size of 64MB you need this value here
-    // mov     r2, #0x00000100 // 64MB
-    mov     r2, #0x00000080 // 32MB
+    mov     r2, #0x00000100 // 64MB
+    // mov     r2, #0x00000080 // 32MB
#endif
     orr     r3, r12, #0x00000012
     orr     r3, r3, #0x00000c00
 map_flash_6:
         str     r3, [r1], #4
         add     r3, r3, #0x00100000
         subs    r2, r2, #4
         bne     map_flash_6

Thanks for your help...  Just didn't know where to look in redboot
source.

On Thu, 6 Dec 2007 05:29:02 +0100, "Manfred Gruber" <m.gruber@tirol.com>
said:
> hi !
> 
> i have worked for a company where ep93xx and spansion flashes are used,
> please 
> look at http://dev.contec.at, there i have made a redboot bootloader
> which 
> can handle such flashes, but i have used flash_v2 branche, so it will not 
> help u.
> 
> > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> 
> this things i have only seen if the mmu is set up wrong, so maybe it
> helps 
> check your mmu settings in redboot. maybe the 512 chip adresses obverlap 
> somewhere...
> 
> regards manfred
>  mfg
> 	Manfred Gruber
> 	Software Engineering
> 	m.gruber@tirol.com
> 	http://www.manfred-gruber.at.tt
> 	http://www.myspace.com/fredl_grma  
> 
> Am Thursday 06 December 2007 schrieb Hasjim Williams:
> > Hello everyone,
> >
> > I'm having problems getting my ARM920T based EP9315 board to work with
> > 64MB flash.  We have 64MB of RAM onboard.  We previously had S29GL128N
> > and S29GL256N parts on the board, and haven't been able to get Redboot
> > to boot up correctly with the S29GL512N.  It works fine with the
> > S29GL256N or S29GL128N still.
> >
> > As soon as it boots up, it spits out this error message, constantly:
> >
> > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> >
> > Can anyone suggest anything that I'm missing:
> >
> > packages/devs/flash/arm/edb9312/current/cdl/flash_edb9312_a_amd.cdl:
> >
> >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL128N
> >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL256N
> >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL512N
> >
> > packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.
> >ldi:
> >
> > MEMORY
> > {
> >     ram : ORIGIN = 0, LENGTH = 0x10000000
> >     rom : ORIGIN = 0x60000000, LENGTH = 0x8000000
> > }
> >
> > packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.
> >h:
> >
> > #define CYGMEM_REGION_rom (0x60000000)
> > #define CYGMEM_REGION_rom_SIZE (0x8000000)
> > #define CYGMEM_REGION_rom_ATTR (CYGMEM_REGION_ATTR_R)
> >
> > Thanks for any suggestions,
> >
> >
> > Hasjim Williams

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Redboot - Cirrus EP9315 and Spansion S29GL512N problem
  2007-12-06  5:29   ` Hasjim Williams
@ 2007-12-06 23:29     ` Hasjim Williams
  2007-12-06 23:52       ` Manfred Gruber
  0 siblings, 1 reply; 5+ messages in thread
From: Hasjim Williams @ 2007-12-06 23:29 UTC (permalink / raw)
  To: ecos-devel; +Cc: Manfred Gruber

We're still having problems...

Is there anywhere else in the code that I need to be looking?

On Thu, 06 Dec 2007 15:29:22 +1000, "Hasjim Williams"
<sourceware.ecos-devel@lists.futaris.org> said:
> I think I found the problem (which was MMU related):
> 
> --- packages/hal/arm/arm9/ep93xx/current/include/hal_platform_setup.h
> +++ packages/hal/arm/arm9/ep93xx/current/include/hal_platform_setup.h
> @@ -494,20 +494,20 @@
>      //
>      // Create a read-write mapping of FLASH at virtual address
>      0x6000_0000.
>      //
>      add     r1, r0, #0x00001800
>  #if defined(HAL_PLATFORM_EP9301) || defined(HAL_PLATFORM_EP9302)
>      mov     r2, #0x00000040
>  #else
>      // If you are using a Flash size of 64MB you need this value here
> -    // mov     r2, #0x00000100 // 64MB
> -    mov     r2, #0x00000080 // 32MB
> +    mov     r2, #0x00000100 // 64MB
> +    // mov     r2, #0x00000080 // 32MB
> #endif
>      orr     r3, r12, #0x00000012
>      orr     r3, r3, #0x00000c00
>  map_flash_6:
>          str     r3, [r1], #4
>          add     r3, r3, #0x00100000
>          subs    r2, r2, #4
>          bne     map_flash_6
> 
> Thanks for your help...  Just didn't know where to look in redboot
> source.
> 
> On Thu, 6 Dec 2007 05:29:02 +0100, "Manfred Gruber" <m.gruber@tirol.com>
> said:
> > hi !
> > 
> > i have worked for a company where ep93xx and spansion flashes are used,
> > please 
> > look at http://dev.contec.at, there i have made a redboot bootloader
> > which 
> > can handle such flashes, but i have used flash_v2 branche, so it will not 
> > help u.
> > 
> > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > 
> > this things i have only seen if the mmu is set up wrong, so maybe it
> > helps 
> > check your mmu settings in redboot. maybe the 512 chip adresses obverlap 
> > somewhere...
> > 
> > regards manfred
> >  mfg
> > 	Manfred Gruber
> > 	Software Engineering
> > 	m.gruber@tirol.com
> > 	http://www.manfred-gruber.at.tt
> > 	http://www.myspace.com/fredl_grma  
> > 
> > Am Thursday 06 December 2007 schrieb Hasjim Williams:
> > > Hello everyone,
> > >
> > > I'm having problems getting my ARM920T based EP9315 board to work with
> > > 64MB flash.  We have 64MB of RAM onboard.  We previously had S29GL128N
> > > and S29GL256N parts on the board, and haven't been able to get Redboot
> > > to boot up correctly with the S29GL512N.  It works fine with the
> > > S29GL256N or S29GL128N still.
> > >
> > > As soon as it boots up, it spits out this error message, constantly:
> > >
> > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > >
> > > Can anyone suggest anything that I'm missing:
> > >
> > > packages/devs/flash/arm/edb9312/current/cdl/flash_edb9312_a_amd.cdl:
> > >
> > >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL128N
> > >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL256N
> > >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL512N
> > >
> > > packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.
> > >ldi:
> > >
> > > MEMORY
> > > {
> > >     ram : ORIGIN = 0, LENGTH = 0x10000000
> > >     rom : ORIGIN = 0x60000000, LENGTH = 0x8000000
> > > }
> > >
> > > packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_romram.
> > >h:
> > >
> > > #define CYGMEM_REGION_rom (0x60000000)
> > > #define CYGMEM_REGION_rom_SIZE (0x8000000)
> > > #define CYGMEM_REGION_rom_ATTR (CYGMEM_REGION_ATTR_R)
> > >
> > > Thanks for any suggestions,
> > >
> > >
> > > Hasjim Williams

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Redboot - Cirrus EP9315 and Spansion S29GL512N problem
  2007-12-06 23:29     ` Hasjim Williams
@ 2007-12-06 23:52       ` Manfred Gruber
  0 siblings, 0 replies; 5+ messages in thread
From: Manfred Gruber @ 2007-12-06 23:52 UTC (permalink / raw)
  To: ecos-devel; +Cc: Hasjim Williams

hi !

IMHO, there were 2 version from cirrus of the bootloader, one where the mmu 
tables were set up in C code and one version where mmu tables where set up in 
asm code.

i used the asm version, hal_platform_setup.h --> BuildPagetable:
do not use my version on dev.contec.at because i have added some asm code 
which detects which flash is connected.

but in BuildPagetable, IMHO in r2 the size of the flash has to be set:

    //
    // Create a read-write mapping of FLASH at virtual address 0x6000_0000.
    //
    add     r1, r0, #0x00001800
#if defined(HAL_PLATFORM_EP9301) || defined(HAL_PLATFORM_EP9302) 
    mov     r2, #0x00000040
#else 
    mov     r2, #0x00000080
#endif 
    orr     r3, r12, #0x00000012
    orr     r3, r3, #0x00000c00

and

    //
    // Create a read-write mapping of FLASH at virtual address 0xe000_0000.
    //
    add     r1, r0, #0x00003800
#if defined(HAL_PLATFORM_EP9301) || defined(HAL_PLATFORM_EP9302) 
    mov     r2, #0x00000040
#else 
    mov     r2, #0x00000080
#endif 
    orr     r3, r12, #0x00000012

then in the ldi file you have to change the rom things for your flash, IMHO, i 
am not sure if this is necessare to change for every flash:
/ecos/packages/hal/arm/arm9/ep93xx/current/include/pkgconf/ldi_file

    rom : ORIGIN = 0x10000000, LENGTH = 0x4000000

and:

in /ecos/packages/hal/arm/arm9/ep93xx/current/src/ep93xx_misc.c:
there you have change the adresses for your flash...

so, as far as i know that has to be it, sorry for not writing this before, but 
i had also to look in my code which i have written 2 years ago, and sorry i 
have forgoten it, what all has to be changed... 

@Hasjim Williams, send me your icq, skype or come to ecos irc channel, maybe i 
can help you...

so regards, greetings from austria
manfred

-- 
	Manfred Gruber
	Software Engineering
	m.gruber@tirol.com
	http://www.manfred-gruber.at.tt
	http://www.myspace.com/fredl_grma  

Am Friday 07 December 2007 schrieb Hasjim Williams:
> We're still having problems...
>
> Is there anywhere else in the code that I need to be looking?
>
> On Thu, 06 Dec 2007 15:29:22 +1000, "Hasjim Williams"
>
> <sourceware.ecos-devel@lists.futaris.org> said:
> > I think I found the problem (which was MMU related):
> >
> > --- packages/hal/arm/arm9/ep93xx/current/include/hal_platform_setup.h
> > +++ packages/hal/arm/arm9/ep93xx/current/include/hal_platform_setup.h
> > @@ -494,20 +494,20 @@
> >      //
> >      // Create a read-write mapping of FLASH at virtual address
> >      0x6000_0000.
> >      //
> >      add     r1, r0, #0x00001800
> >  #if defined(HAL_PLATFORM_EP9301) || defined(HAL_PLATFORM_EP9302)
> >      mov     r2, #0x00000040
> >  #else
> >      // If you are using a Flash size of 64MB you need this value here
> > -    // mov     r2, #0x00000100 // 64MB
> > -    mov     r2, #0x00000080 // 32MB
> > +    mov     r2, #0x00000100 // 64MB
> > +    // mov     r2, #0x00000080 // 32MB
> > #endif
> >      orr     r3, r12, #0x00000012
> >      orr     r3, r3, #0x00000c00
> >  map_flash_6:
> >          str     r3, [r1], #4
> >          add     r3, r3, #0x00100000
> >          subs    r2, r2, #4
> >          bne     map_flash_6
> >
> > Thanks for your help...  Just didn't know where to look in redboot
> > source.
> >
> > On Thu, 6 Dec 2007 05:29:02 +0100, "Manfred Gruber" <m.gruber@tirol.com>
> >
> > said:
> > > hi !
> > >
> > > i have worked for a company where ep93xx and spansion flashes are used,
> > > please
> > > look at http://dev.contec.at, there i have made a redboot bootloader
> > > which
> > > can handle such flashes, but i have used flash_v2 branche, so it will
> > > not help u.
> > >
> > > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > >
> > > this things i have only seen if the mmu is set up wrong, so maybe it
> > > helps
> > > check your mmu settings in redboot. maybe the 512 chip adresses
> > > obverlap somewhere...
> > >
> > > regards manfred
> > >  mfg
> > > 	Manfred Gruber
> > > 	Software Engineering
> > > 	m.gruber@tirol.com
> > > 	http://www.manfred-gruber.at.tt
> > > 	http://www.myspace.com/fredl_grma
> > >
> > > Am Thursday 06 December 2007 schrieb Hasjim Williams:
> > > > Hello everyone,
> > > >
> > > > I'm having problems getting my ARM920T based EP9315 board to work
> > > > with 64MB flash.  We have 64MB of RAM onboard.  We previously had
> > > > S29GL128N and S29GL256N parts on the board, and haven't been able to
> > > > get Redboot to boot up correctly with the S29GL512N.  It works fine
> > > > with the S29GL256N or S29GL128N still.
> > > >
> > > > As soon as it boots up, it spits out this error message, constantly:
> > > >
> > > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > > > #dd$T0a0f:f06a0100;0d:f07e0400;#dd$T0a0f:f06a0100;0d:f07e0400;
> > > >
> > > > Can anyone suggest anything that I'm missing:
> > > >
> > > > packages/devs/flash/arm/edb9312/current/cdl/flash_edb9312_a_amd.cdl:
> > > >
> > > >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL128N
> > > >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL256N
> > > >     requires      CYGHWR_DEVS_FLASH_AMD_S29GL512N
> > > >
> > > > packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_r
> > > >omram. ldi:
> > > >
> > > > MEMORY
> > > > {
> > > >     ram : ORIGIN = 0, LENGTH = 0x10000000
> > > >     rom : ORIGIN = 0x60000000, LENGTH = 0x8000000
> > > > }
> > > >
> > > > packages/hal/arm/arm9/ep93xx/current/include/conf/mlt_arm9_edb9315a_r
> > > >omram. h:
> > > >
> > > > #define CYGMEM_REGION_rom (0x60000000)
> > > > #define CYGMEM_REGION_rom_SIZE (0x8000000)
> > > > #define CYGMEM_REGION_rom_ATTR (CYGMEM_REGION_ATTR_R)
> > > >
> > > > Thanks for any suggestions,
> > > >
> > > >
> > > > Hasjim Williams

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-12-06 23:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-12-06  3:34 Redboot - Cirrus EP9315 and Spansion S29GL512N problem Hasjim Williams
2007-12-06  4:29 ` Manfred Gruber
2007-12-06  5:29   ` Hasjim Williams
2007-12-06 23:29     ` Hasjim Williams
2007-12-06 23:52       ` Manfred Gruber

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).