public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Help on Flash support in Redboot for Xscale.
@ 2001-05-15 22:09 Mynampati
  2001-05-16  4:51 ` Mark Salter
  0 siblings, 1 reply; 6+ messages in thread
From: Mynampati @ 2001-05-15 22:09 UTC (permalink / raw)
  To: ecos-discuss

Hi,
I am trying to incorporate Flash support into Redboot for Xscale, but
the binary didn't work. When i looked up in the include file(hal_iq80310.h),
i didn't find the definition of base address of flash. Did i miss something 
here?
Who sets up FEBR0/1 registers in Xscale?
Also, where and how the flash gets setup.

I would appreciate your help.

Best Regards
Venkat N

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

* Re: [ECOS] Help on Flash support in Redboot for Xscale.
  2001-05-15 22:09 [ECOS] Help on Flash support in Redboot for Xscale Mynampati
@ 2001-05-16  4:51 ` Mark Salter
  0 siblings, 0 replies; 6+ messages in thread
From: Mark Salter @ 2001-05-16  4:51 UTC (permalink / raw)
  To: Mynampati; +Cc: ecos-discuss

>>>>> Mynampati  writes:

> Hi,
> I am trying to incorporate Flash support into Redboot for Xscale, but
> the binary didn't work. When i looked up in the include file(hal_iq80310.h),
> i didn't find the definition of base address of flash. Did i miss something 
> here?
> Who sets up FEBR0/1 registers in Xscale?
> Also, where and how the flash gets setup.

> I would appreciate your help.

Flash occupies 0x00000000 - 0x01ffffff on the IQ80310. I forget the
details, but either the flash bank registers are not used or the
default values are used. RedBoot does not touch them.

--Mark


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

* Re: [ECOS] Help on Flash support in Redboot for Xscale.
  2001-05-17  9:57 Narayana, Venkat A.
@ 2001-05-17 10:32 ` Mark Salter
  0 siblings, 0 replies; 6+ messages in thread
From: Mark Salter @ 2001-05-17 10:32 UTC (permalink / raw)
  To: NarayVA; +Cc: ecos-discuss

>>>>> Narayana, Venkat A writes:

> --Mark
> This is not iq80310 board, but a custom board using 80312 chipset and
> having many similarities with iq80310, except that my board has 1 serial
> and no registers@FE800000, which iq80310 board has,imean timers and battery
> status reg's etc.
> What i found, by single stepping is that, in _real_platform_setup,
> my code dies atfer i enable MMU and do "drain the write & fill buffers".
> Anyway, it gives me an oopurtunity to lear more;-).
> I have a question for you(i assume u r the same mslater that's in my code),
> we setup mmu table at 16K boundary, but in the code, we do .p2align13, which
> is 2**13=8K. Am i missing something here? or does my ignorance shows?

Hmm, I think you just found a bug. ;-) 

That should be ".p2align 14", although ".p2align 13" happens to work out
because the next 8K boundary is also a 16K boundary.

If it dies when you enable the MMU, I would look very carefully at the
pagetable. I had to do a lot of tweaking before I finally got it right.

Also, there is read from SDRAM_BATTERY_TEST_BASE just after the drain
operation. That was for some diagnostics on the IQ80310 and may cause
you problems if you don't have memory at that spot. It would be safe
to remove altogether.

--Mark

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

* RE: [ECOS] Help on Flash support in Redboot for Xscale.
@ 2001-05-17  9:57 Narayana, Venkat A.
  2001-05-17 10:32 ` Mark Salter
  0 siblings, 1 reply; 6+ messages in thread
From: Narayana, Venkat A. @ 2001-05-17  9:57 UTC (permalink / raw)
  To: 'Mark Salter'; +Cc: ecos-discuss

> Mark,
> Thanks for explaining. You are correct, in that redboot uses the
> default values for FEBR0 and FBSR0( i.e flash base and size).But,
> this only perplexes me. Cause, when i configure redboot without
> CYGPKG_DEVS_FLASH_IQ80310 and with RAM startup, and load this guy 
> into RAM, the it works, imean i could get Redboot prompt etc.
> But when i build it for ROM, with Flash support and load the guy
> into flash, then it dies somewhere in '_real_platform_setup'.At
> this point all the MCU(mem cntrl Unit) registers becomes zero.
> What could be happening here? I mean, when i looked into this
> macro, it seemed to me pretty straight forward, but still, i am
> unable to figure out the why's/where's/what's.
> Could you guys pls help me out. Point me to some doc/reading material.

I don't really have enough information to help you out. Is this the
IQ80310 board or something else? All of the stuff in hal_platform_setup.h
is very specific to the IQ80310 design. One of the tricky things is
that there is a "hole" in flash at 0x1000 - 0x1fff where the I/O
companion chip internal registers are located. The _real_platform_setup
code setups up the page table to deal with that. There is a pagetable
in flash at 0x4000 (mmu_table) which gets copied out to ram later in
the startup.

--Mark
This is not iq80310 board, but a custom board using 80312 chipset and
having many similarities with iq80310, except that my board has 1 serial
and no registers@FE800000, which iq80310 board has,imean timers and battery
status reg's etc.
What i found, by single stepping is that, in _real_platform_setup,
my code dies atfer i enable MMU and do "drain the write & fill buffers".
Anyway, it gives me an oopurtunity to lear more;-).
I have a question for you(i assume u r the same mslater that's in my code),
we setup mmu table at 16K boundary, but in the code, we do .p2align13, which
is 2**13=8K. Am i missing something here? or does my ignorance shows?

Rgds
Venkat N


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

* Re: [ECOS] Help on Flash support in Redboot for Xscale.
  2001-05-16 15:36 Narayana, Venkat A.
@ 2001-05-17  5:15 ` Mark Salter
  0 siblings, 0 replies; 6+ messages in thread
From: Mark Salter @ 2001-05-17  5:15 UTC (permalink / raw)
  To: NarayVA; +Cc: ecos-discuss

>>>>> Narayana, Venkat A writes:

> Mark,
> Thanks for explaining. You are correct, in that redboot uses the
> default values for FEBR0 and FBSR0( i.e flash base and size).But,
> this only perplexes me. Cause, when i configure redboot without
> CYGPKG_DEVS_FLASH_IQ80310 and with RAM startup, and load this guy 
> into RAM, the it works, imean i could get Redboot prompt etc.
> But when i build it for ROM, with Flash support and load the guy
> into flash, then it dies somewhere in '_real_platform_setup'.At
> this point all the MCU(mem cntrl Unit) registers becomes zero.
> What could be happening here? I mean, when i looked into this
> macro, it seemed to me pretty straight forward, but still, i am
> unable to figure out the why's/where's/what's.
> Could you guys pls help me out. Point me to some doc/reading material.

I don't really have enough information to help you out. Is this the
IQ80310 board or something else? All of the stuff in hal_platform_setup.h
is very specific to the IQ80310 design. One of the tricky things is
that there is a "hole" in flash at 0x1000 - 0x1fff where the I/O
companion chip internal registers are located. The _real_platform_setup
code setups up the page table to deal with that. There is a pagetable
in flash at 0x4000 (mmu_table) which gets copied out to ram later in
the startup.

--Mark




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

* RE: [ECOS] Help on Flash support in Redboot for Xscale.
@ 2001-05-16 15:36 Narayana, Venkat A.
  2001-05-17  5:15 ` Mark Salter
  0 siblings, 1 reply; 6+ messages in thread
From: Narayana, Venkat A. @ 2001-05-16 15:36 UTC (permalink / raw)
  To: 'Mark Salter'; +Cc: ecos-discuss

Mark,
Thanks for explaining. You are correct, in that redboot uses the
default values for FEBR0 and FBSR0( i.e flash base and size).But,
this only perplexes me. Cause, when i configure redboot without
CYGPKG_DEVS_FLASH_IQ80310 and with RAM startup, and load this guy 
into RAM, the it works, imean i could get Redboot prompt etc.
But when i build it for ROM, with Flash support and load the guy
into flash, then it dies somewhere in '_real_platform_setup'.At
this point all the MCU(mem cntrl Unit) registers becomes zero.
What could be happening here? I mean, when i looked into this
macro, it seemed to me pretty straight forward, but still, i am
unable to figure out the why's/where's/what's.
Could you guys pls help me out. Point me to some doc/reading material.

Thanks and Regards
Venkat



>>>>> Mynampati  writes:

> Hi,
> I am trying to incorporate Flash support into Redboot for Xscale, but
> the binary didn't work. When i looked up in the include
file(hal_iq80310.h),
> i didn't find the definition of base address of flash. Did i miss
something 
> here?
> Who sets up FEBR0/1 registers in Xscale?
> Also, where and how the flash gets setup.

> I would appreciate your help.

Flash occupies 0x00000000 - 0x01ffffff on the IQ80310. I forget the
details, but either the flash bank registers are not used or the
default values are used. RedBoot does not touch them.

--Mark

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

end of thread, other threads:[~2001-05-17 10:32 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-05-15 22:09 [ECOS] Help on Flash support in Redboot for Xscale Mynampati
2001-05-16  4:51 ` Mark Salter
2001-05-16 15:36 Narayana, Venkat A.
2001-05-17  5:15 ` Mark Salter
2001-05-17  9:57 Narayana, Venkat A.
2001-05-17 10:32 ` Mark Salter

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).