This is the mail archive of the
ecos-patches@sources.redhat.com
mailing list for the eCos project.
Re: [ECOS] arguments to main
- From: Gary Thomas <gary at chez-thomas dot org>
- To: Andrew Lunn <andrew dot lunn at ascom dot ch>
- Cc: Wouter Cloetens <wouter at mind dot be>,eCos patches <ecos-patches at sources dot redhat dot com>
- Date: 31 Jul 2002 11:48:26 -0600
- Subject: Re: [ECOS] arguments to main
- References: <02072602521900.01647@c1830598-a><20020730224422.GI1607@roadkill.intern.mind.be><20020731074631.GC3392@biferten.ma.tech.ascom.ch><1028117420.28587.127.camel@hermes.chez-thomas.org> <20020731174152.GJ3392@biferten.ma.tech.ascom.ch>
On Wed, 2002-07-31 at 11:41, Andrew Lunn wrote:
> > Additionally, these variables should be exported via some HAL .h file,
> > possibly <cyg/hal/hal.h> or maybe <cyg/hal/hal_arch.h>.
> >
> > Finally, there should be appropriate ChangeLog entries.
> >
>
> I could not work out how to get access to the environment. I can see
> it on the stack, but i cannot find an obvious pointer to it anywhere.
> Does anyone know of any documentation of how the linux kernel sets up
> the stack before handing it over to the new process?
IIRC, you have to compute it. You could look at the GLIBC code (crt0.s)
to figure it out.