[PATCH] sh: Fix args for __uClibc_main() in crt1.S
Paul Mundt
lethal at linux-sh.org
Thu Aug 7 16:42:27 UTC 2008
On Thu, Aug 07, 2008 at 08:30:37AM +0200, Carmelo AMOROSO wrote:
> please find attached another patch to completely fix the sh4 startup
> sequence (in addition to the patch of Yoshii).
>
> As you can see from the log below, DSO's destructor now is called.
>
> Paul, does it sound good for you ?
>
[snip]
> Fix ldso startup sequence by passing via r4 the rtls finalizer
> _dl_fini to the user application. This will be the 6^ arg of
> __uClibc_main and will be registered with 'atexit'.
> In this way the dynamic linker will be able to call destructors
> defined within the loaded DSO.
>
> Signed-off-by: Carmelo Amoroso <carmelo.amoroso at st.com>
>
Looks good to me, yes. Thanks for debugging this down!
Acked-by: Paul Mundt <lethal at linux-sh.org>
On Thu, Aug 07, 2008 at 06:00:22PM +0900, Takashi Yoshii wrote:
> Hi,
> >please find attached another patch to completely fix the sh4 startup
> >sequence (in addition to the patch of Yoshii).
> Tested. It works fine here. Great.
> # Sorry for my slow writing(code/mail) made useless traffic.
> /yoshii
This still requires the kernel zeroing the r4 value before handing
control over as per your FLAT_PLAT_INIT() patch, correct?
More information about the uClibc
mailing list