This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
Re: CyaSSL library port (WIP): Space for struct corrupts other eCos-data in RAM
- From: Daniel Zebralla <daniel dot zebralla at zebralla-it dot de>
- To: ecos-discuss at ecos dot sourceware dot org
- Date: Fri, 11 Oct 2013 01:18:44 -0700 (PDT)
- Subject: Re: CyaSSL library port (WIP): Space for struct corrupts other eCos-data in RAM
- Authentication-results: sourceware.org; auth=none
- References: <1380531306664-245720 dot post at n7 dot nabble dot com>
I now solved the problem by putting all CyaSSL-related stuff and tests into
an individual thread:
void create_TLS_thread(void)
{
cyg_mutex_init(&cliblock_TLS);
cyg_thread_create(
TLS_THREAD_PRIOTITY,
TLS_communication,
(cyg_addrword_t) 1,
"TLS Communication",
(void *) tls_stack,
sizeof(tls_stack),
&TLS_Thread,
&thread_tls
);
cyg_thread_resume(TLS_Thread);
printf("TLS-Thread created!\n");
}
Suddenly, all tests complete successfully and no memory is corrupted.
Is there some general rule of thumb, that one should not do memory-intensive
work in the 'main'-thread?
Regards
- Daniel
--
View this message in context: http://sourceware-org.1504.n7.nabble.com/CyaSSL-library-port-WIP-Space-for-struct-corrupts-other-eCos-data-in-RAM-tp245720p247044.html
Sent from the Sourceware - ecos-discuss mailing list archive at Nabble.com.
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss