* [ECOS] Can I assign the offset of code start in redboot.bin when using startup from ROM
@ 2005-07-07 9:34 Steven_cheng
2005-07-07 10:40 ` Gary Thomas
0 siblings, 1 reply; 4+ messages in thread
From: Steven_cheng @ 2005-07-07 9:34 UTC (permalink / raw)
To: ecos-discuss
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="big5", Size: 1256 bytes --]
Hi All,
Environment:
arch: MPC8245
package: RedBoot
startup type: ROM
After building the code, I burn the the redboot.bin into my rom flash, but
it
seems not to be executed. Then I found that the code offset starts in 0x0,
not
in 0x100, in the redboot.bin. The MPC8245 can not start from offset 0x100
to execute the rom code. So the rom code is failed.
Questions:
1) The MPC8245 rom code should start from 0x100 in redboot.bin for
burning.(???)
2) Does anybody know how I can move the code offset start from 0x0 to
0x100 ??
3) Does the code start from the _start in the vector.S for startup type
"ROM" ??
It was as following:
0x00000000 rom_code _start # map to _start in vectors.S
0x00000010 rom_code
0x00000020 rom_code ......¡
...
0x00000100 rom_code ......¡
......
But I think it should be as following:
0x00000000 Vector
0x00000010 empty
0x00000020 empty
...
0x00000100 rom_code _start ......¡# map to _start in vectors.S
......
4) Is it correct ??
Thank you in advence!!
/Steven Cheng
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [ECOS] Can I assign the offset of code start in redboot.bin when using startup from ROM
2005-07-07 9:34 [ECOS] Can I assign the offset of code start in redboot.bin when using startup from ROM Steven_cheng
@ 2005-07-07 10:40 ` Gary Thomas
2005-07-07 12:00 ` [ECOS] Can I assign the offset of code start in redboot.binwhen " Steven_cheng
0 siblings, 1 reply; 4+ messages in thread
From: Gary Thomas @ 2005-07-07 10:40 UTC (permalink / raw)
To: Steven_cheng; +Cc: eCos Discussion
On Thu, 2005-07-07 at 17:35 +0800, Steven_cheng wrote:
> Hi All,
>
> Environment:
> arch: MPC8245
> package: RedBoot
> startup type: ROM
>
> After building the code, I burn the the redboot.bin into my rom flash, but
> it
> seems not to be executed. Then I found that the code offset starts in 0x0,
> not
> in 0x100, in the redboot.bin. The MPC8245 can not start from offset 0x100
> to execute the rom code. So the rom code is failed.
>
> Questions:
> 1) The MPC8245 rom code should start from 0x100 in redboot.bin for
> burning.(???)
> 2) Does anybody know how I can move the code offset start from 0x0 to
> 0x100 ??
> 3) Does the code start from the _start in the vector.S for startup type
> "ROM" ??
>
> It was as following:
>
> 0x00000000 rom_code _start # map to _start in vectors.S
> 0x00000010 rom_code
> 0x00000020 rom_code ......
> ...
> 0x00000100 rom_code ......
> ......
>
>
> But I think it should be as following:
>
> 0x00000000 Vector
> 0x00000010 empty
> 0x00000020 empty
> ...
> 0x00000100 rom_code _start ......# map to _start in vectors.S
> ......
>
> 4) Is it correct ??
>
How did you configure eCos? (i.e. what commands/steps did you use?)
You can see how the image is laid out in memory using this command:
powerpc-eabi-objdump -h install/bin/redboot.elf
What do you see from it?
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [ECOS] Can I assign the offset of code start in redboot.binwhen using startup from ROM
2005-07-07 10:40 ` Gary Thomas
@ 2005-07-07 12:00 ` Steven_cheng
2005-07-07 12:40 ` Gary Thomas
0 siblings, 1 reply; 4+ messages in thread
From: Steven_cheng @ 2005-07-07 12:00 UTC (permalink / raw)
To: Gary Thomas; +Cc: eCos Discussion
Hi Gray,
I configure eCos with configtool.
Step:
1) Select Template "Cogent PowerPC 8245" and Package "RedBoot"
2) Configure Startup type "ROM"
3) Import packages/hal/powerpc/csb281/current/misc/redboot_ROM.ecm
4) Build code
5) burn install/bin/redboot.bin (and check the content of redboot.bin)
Question:
1) Does the rom image be burned with redboot.bin
2) Does the code start from the _start in the vector.S for startup type
"ROM" ??
Thank you for your help ~~~
/Steven
After executing the command "powerpc-eabi-objdump -h
install/bin/redboot.elf",
The result is as following table:
file format elf32-powerpc
Sections:
Idx Name Size VMA LMA File off Algn
0 .vectors 00001500 fff00000 fff00000 00010000 2**8
CONTENTS, ALLOC, LOAD, READONLY, CODE
1 .text 0001489c fff01500 fff01500 00011500 2**2
CONTENTS, ALLOC, LOAD, READONLY, CODE
2 .fini 00000000 fff15d9c fff15d9c 00033f48 2**0
CONTENTS
3 .rodata1 00000000 fff15da0 fff15da0 00033f48 2**0
CONTENTS
4 .rodata 00003880 fff15da0 fff15da0 00025da0 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
5 .fixup 00000000 fff19620 fff19620 00033f48 2**0
CONTENTS
6 .gcc_except_table 00000000 fff19620 fff19620 00033f48 2**0
CONTENTS
7 .data 00000c48 00003300 fff19620 00033300 2**3
CONTENTS, ALLOC, LOAD, CODE
8 .sbss 00000100 00003f48 00003f48 00003f48 2**3
ALLOC
9 .bss 00005420 00004050 00004050 00003f50 2**4
ALLOC
10 .debug_line 0000d084 00000000 00000000 00033f48 2**0
CONTENTS, READONLY, DEBUGGING
11 .debug_info 0002ff4e 00000000 00000000 00040fcc 2**0
CONTENTS, READONLY, DEBUGGING
12 .debug_abbrev 00006886 00000000 00000000 00070f1a 2**0
CONTENTS, READONLY, DEBUGGING
13 .debug_aranges 000015f0 00000000 00000000 000777a0 2**3
CONTENTS, READONLY, DEBUGGING
14 .debug_frame 000032c0 00000000 00000000 00078d90 2**2
CONTENTS, READONLY, DEBUGGING
15 .debug_pubnames 00002800 00000000 00000000 0007c050 2**0
CONTENTS, READONLY, DEBUGGING
16 .debug_str 00005d6c 00000000 00000000 0007e850 2**0
CONTENTS, READONLY, DEBUGGING
17 .debug_ranges 00000710 00000000 00000000 000845bc 2**0
CONTENTS, READONLY, DEBUGGING
> >
> > Environment:
> > arch: MPC8245
> > package: RedBoot
> > startup type: ROM
> >
> > After building the code, I burn the the redboot.bin into my rom flash,
but
> > it
> > seems not to be executed. Then I found that the code offset starts in
0x0,
> > not
> > in 0x100, in the redboot.bin. The MPC8245 can not start from offset
0x100
> > to execute the rom code. So the rom code is failed.
> >
> > Questions:
> > 1) The MPC8245 rom code should start from 0x100 in redboot.bin for
> > burning.(???)
> > 2) Does anybody know how I can move the code offset start from 0x0
to
> > 0x100 ??
> > 3) Does the code start from the _start in the vector.S for startup
type
> > "ROM" ??
> >
> > It was as following:
> >
> > 0x00000000 rom_code _start # map to _start in vectors.S
> > 0x00000010 rom_code
> > 0x00000020 rom_code ......
> > ...
> > 0x00000100 rom_code ......
> > ......
> >
> >
> > But I think it should be as following:
> >
> > 0x00000000 Vector
> > 0x00000010 empty
> > 0x00000020 empty
> > ...
> > 0x00000100 rom_code _start ......# map to _start in vectors.S
> > ......
> >
> > 4) Is it correct ??
> >
>
> How did you configure eCos? (i.e. what commands/steps did you use?)
> You can see how the image is laid out in memory using this command:
> powerpc-eabi-objdump -h install/bin/redboot.elf
> What do you see from it?
>
> --
> ------------------------------------------------------------
> Gary Thomas | Consulting for the
> MLB Associates | Embedded world
> ------------------------------------------------------------
>
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [ECOS] Can I assign the offset of code start in redboot.binwhen using startup from ROM
2005-07-07 12:00 ` [ECOS] Can I assign the offset of code start in redboot.binwhen " Steven_cheng
@ 2005-07-07 12:40 ` Gary Thomas
0 siblings, 0 replies; 4+ messages in thread
From: Gary Thomas @ 2005-07-07 12:40 UTC (permalink / raw)
To: Steven_cheng; +Cc: eCos Discussion
On Thu, 2005-07-07 at 20:01 +0800, Steven_cheng wrote:
> Hi Gray,
>
> I configure eCos with configtool.
> Step:
> 1) Select Template "Cogent PowerPC 8245" and Package "RedBoot"
> 2) Configure Startup type "ROM"
> 3) Import packages/hal/powerpc/csb281/current/misc/redboot_ROM.ecm
> 4) Build code
> 5) burn install/bin/redboot.bin (and check the content of redboot.bin)
>
> Question:
> 1) Does the rom image be burned with redboot.bin
> 2) Does the code start from the _start in the vector.S for startup type
> "ROM" ??
>
No. The first 0x1500 bytes of code are the exception vectors,
which includes the reset vector where execution actually begins.
The code starting at 0xFFF00000 in the listing below is what will
be put into the ROM.
Note: I know that this platform works; I did the port myself.
> Thank you for your help ~~~
>
> /Steven
>
> After executing the command "powerpc-eabi-objdump -h
> install/bin/redboot.elf",
> The result is as following table:
>
> file format elf32-powerpc
> Sections:
> Idx Name Size VMA LMA File off Algn
> 0 .vectors 00001500 fff00000 fff00000 00010000 2**8
> CONTENTS, ALLOC, LOAD, READONLY, CODE
> 1 .text 0001489c fff01500 fff01500 00011500 2**2
> CONTENTS, ALLOC, LOAD, READONLY, CODE
> 2 .fini 00000000 fff15d9c fff15d9c 00033f48 2**0
> CONTENTS
> 3 .rodata1 00000000 fff15da0 fff15da0 00033f48 2**0
> CONTENTS
> 4 .rodata 00003880 fff15da0 fff15da0 00025da0 2**2
> CONTENTS, ALLOC, LOAD, READONLY, DATA
> 5 .fixup 00000000 fff19620 fff19620 00033f48 2**0
> CONTENTS
> 6 .gcc_except_table 00000000 fff19620 fff19620 00033f48 2**0
> CONTENTS
> 7 .data 00000c48 00003300 fff19620 00033300 2**3
> CONTENTS, ALLOC, LOAD, CODE
> 8 .sbss 00000100 00003f48 00003f48 00003f48 2**3
> ALLOC
> 9 .bss 00005420 00004050 00004050 00003f50 2**4
> ALLOC
> 10 .debug_line 0000d084 00000000 00000000 00033f48 2**0
> CONTENTS, READONLY, DEBUGGING
> 11 .debug_info 0002ff4e 00000000 00000000 00040fcc 2**0
> CONTENTS, READONLY, DEBUGGING
> 12 .debug_abbrev 00006886 00000000 00000000 00070f1a 2**0
> CONTENTS, READONLY, DEBUGGING
> 13 .debug_aranges 000015f0 00000000 00000000 000777a0 2**3
> CONTENTS, READONLY, DEBUGGING
> 14 .debug_frame 000032c0 00000000 00000000 00078d90 2**2
> CONTENTS, READONLY, DEBUGGING
> 15 .debug_pubnames 00002800 00000000 00000000 0007c050 2**0
> CONTENTS, READONLY, DEBUGGING
> 16 .debug_str 00005d6c 00000000 00000000 0007e850 2**0
> CONTENTS, READONLY, DEBUGGING
> 17 .debug_ranges 00000710 00000000 00000000 000845bc 2**0
> CONTENTS, READONLY, DEBUGGING
>
> > >
> > > Environment:
> > > arch: MPC8245
> > > package: RedBoot
> > > startup type: ROM
> > >
> > > After building the code, I burn the the redboot.bin into my rom flash,
> but
> > > it
> > > seems not to be executed. Then I found that the code offset starts in
> 0x0,
> > > not
> > > in 0x100, in the redboot.bin. The MPC8245 can not start from offset
> 0x100
> > > to execute the rom code. So the rom code is failed.
> > >
> > > Questions:
> > > 1) The MPC8245 rom code should start from 0x100 in redboot.bin for
> > > burning.(???)
> > > 2) Does anybody know how I can move the code offset start from 0x0
> to
> > > 0x100 ??
> > > 3) Does the code start from the _start in the vector.S for startup
> type
> > > "ROM" ??
> > >
> > > It was as following:
> > >
> > > 0x00000000 rom_code _start # map to _start in vectors.S
> > > 0x00000010 rom_code
> > > 0x00000020 rom_code ......
> > > ...
> > > 0x00000100 rom_code ......
> > > ......
> > >
> > >
> > > But I think it should be as following:
> > >
> > > 0x00000000 Vector
> > > 0x00000010 empty
> > > 0x00000020 empty
> > > ...
> > > 0x00000100 rom_code _start ......# map to _start in vectors.S
> > > ......
> > >
> > > 4) Is it correct ??
> > >
> >
> > How did you configure eCos? (i.e. what commands/steps did you use?)
> > You can see how the image is laid out in memory using this command:
> > powerpc-eabi-objdump -h install/bin/redboot.elf
> > What do you see from it?
> >
> > --
> > ------------------------------------------------------------
> > Gary Thomas | Consulting for the
> > MLB Associates | Embedded world
> > ------------------------------------------------------------
> >
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2005-07-07 12:40 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-07-07 9:34 [ECOS] Can I assign the offset of code start in redboot.bin when using startup from ROM Steven_cheng
2005-07-07 10:40 ` Gary Thomas
2005-07-07 12:00 ` [ECOS] Can I assign the offset of code start in redboot.binwhen " Steven_cheng
2005-07-07 12:40 ` Gary Thomas
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).