This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: .previous -- directive


Hi Billy,


Thanks a lot for the links, now I am clear on those 2.


Excuse me for the lengthy email.
I am tying to understand the .ecos.table.devtab.

My understanding:
-----------------------
1. The ?DEVTAB_ENTRY(some_lable_name,...)? should append data structures in the .ecos.table.devtab.data SUB-SECTION
2. I guess the ?CYG_HAL_TABLE_BEGIN( __DEVTAB__, devtab )? & ?CYG_HAL_TABLE_END( __DEVTAB_END__, devtab )?, should place these objects ?__DEVTAB__ <.ecos.table.devtab.begin >? & ?__DEVTAB_END__ <.ecos.table.devtab.finish >? above & below .ecos.table.devtab.data SUB-SECTION (for simpicity sake: forget the .extra may be other sub-sections). Am I right? If so, How does this get arranged in this manner?
a. why should .ecos.table.devtab.begin get placed before .ecos.table.devtab.data
b. And why should .ecos.table.devtab.finish get placed after .ecos.table.devtab.data



I tied a simple experiment (outside the ecos frame-work):


Linker scipt:
------------
Has 2 SECTIONS

.text
{
with subsection, but did not explicitly specify any subsection for .ecos.table.devtab.*
}


.data
{
}


When I looked at the output map file: -------------------------------------

.ecos.table.devtab.begin
               0x0000000080102c04        0x0

.ecos.table.devtab.finish
               0x0000000080102c04        0x0

.ecos.table.devtab.data
               0x0000000080102c04       0x24
.ecos.table.devtab.data
               0x0000000080102c04       0x24 dds.o
               0x0000000080102c1c                atlas_struct2
               0x0000000080102c04                atlas_struct0
               0x0000000080102c10                atlas_struct1


This was the reason both __DEVTAB__ & __DEVTAB_END__ read the same address (0x80102c04) in my test program.


Well, I could explicitly define subsection ?.ecos.table.devtab.data? in my linker script & added name_objects about & below this to get the ABSOULE(.) address of start & end. But I really want to understand how it works in ecos.

The only difference I found was in the ecos?s .ld files (mips_mips32.ld) ?KEEP(*( SORT (.ecos.table.*))) ;?. Is the line responsible for this magic (placing the .ecos.table.devtab.begin about .ecos.table.devtab.data & .ecos.table.devtab.finish below .ecos.table.devtab.data)? Or some else?

Thanks a lot,
-Mike.

_________________________________________________________________
Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail



-- Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]