public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Data section in redboot
@ 2002-05-23 11:51 Agarwal, Lomesh
  2002-05-28 14:12 ` Jonathan Larmour
  0 siblings, 1 reply; 3+ messages in thread
From: Agarwal, Lomesh @ 2002-05-23 11:51 UTC (permalink / raw)
  To: ecos-discuss

I have a dual processor board and I need to copy data section from ROM of
first processor to RAM of another processor after I jump to C Code (at this
point I am running out of RAM of first processor and everything is copied to
RAM). So I am using __rom_data_start, __ram_data_start, __ram_data_end
defined in vectors.s
I defined all these 3 as extern in my C code and when I access these values
of these are 0. I tried using .__rom_data_start, .__ram_data_start,
.__ram_data_end but compiler gives me error. I checked the values when I use
them in vectors.s and the values seems to be ok (at this point also I am
running out of RAM of first processor and everything is copied to RAM). But
I don't find the same value later.
So, the question is how can I access these.

Thanks,
Lomesh

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

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

* Re: [ECOS] Data section in redboot
  2002-05-23 11:51 [ECOS] Data section in redboot Agarwal, Lomesh
@ 2002-05-28 14:12 ` Jonathan Larmour
  0 siblings, 0 replies; 3+ messages in thread
From: Jonathan Larmour @ 2002-05-28 14:12 UTC (permalink / raw)
  To: Agarwal, Lomesh; +Cc: ecos-discuss

"Agarwal, Lomesh" wrote:
> 
> I have a dual processor board and I need to copy data section from ROM of
> first processor to RAM of another processor after I jump to C Code (at this
> point I am running out of RAM of first processor and everything is copied to
> RAM). So I am using __rom_data_start, __ram_data_start, __ram_data_end
> defined in vectors.s
> I defined all these 3 as extern in my C code and when I access these values
> of these are 0. I tried using .__rom_data_start, .__ram_data_start,
> .__ram_data_end but compiler gives me error. I checked the values when I use
> them in vectors.s and the values seems to be ok (at this point also I am
> running out of RAM of first processor and everything is copied to RAM). But
> I don't find the same value later.
> So, the question is how can I access these.

they should be declared as:

char __rom_data_start[], __ram_data_start[], __ram_data_end;

And then used by taking their *address*, i.e. &__rom_data_start.

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
--[ "You can complain because roses have thorns, or you ]--
--[  can rejoice because thorns have roses." -Lincoln   ]-- Opinions==mine

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

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

* RE: [ECOS] Data section in redboot
@ 2002-05-29  9:42 Agarwal, Lomesh
  0 siblings, 0 replies; 3+ messages in thread
From: Agarwal, Lomesh @ 2002-05-29  9:42 UTC (permalink / raw)
  To: ecos-discuss

Can you explain why do I need to do that?

Thanks,
Lomesh

-----Original Message-----
From: Jonathan Larmour [mailto:jlarmour@redhat.com] 
Sent: Tuesday, May 28, 2002 2:13 PM
To: Agarwal, Lomesh
Cc: ecos-discuss@sources.redhat.com
Subject: Re: [ECOS] Data section in redboot


"Agarwal, Lomesh" wrote:
> 
> I have a dual processor board and I need to copy data section from ROM of
> first processor to RAM of another processor after I jump to C Code (at
this
> point I am running out of RAM of first processor and everything is copied
to
> RAM). So I am using __rom_data_start, __ram_data_start, __ram_data_end
> defined in vectors.s
> I defined all these 3 as extern in my C code and when I access these
values
> of these are 0. I tried using .__rom_data_start, .__ram_data_start,
> .__ram_data_end but compiler gives me error. I checked the values when I
use
> them in vectors.s and the values seems to be ok (at this point also I am
> running out of RAM of first processor and everything is copied to RAM).
But
> I don't find the same value later.
> So, the question is how can I access these.

they should be declared as:

char __rom_data_start[], __ram_data_start[], __ram_data_end;

And then used by taking their *address*, i.e. &__rom_data_start.

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
--[ "You can complain because roses have thorns, or you ]--
--[  can rejoice because thorns have roses." -Lincoln   ]-- Opinions==mine

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

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

end of thread, other threads:[~2002-05-29 16:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-05-23 11:51 [ECOS] Data section in redboot Agarwal, Lomesh
2002-05-28 14:12 ` Jonathan Larmour
2002-05-29  9:42 Agarwal, Lomesh

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