This is the mail archive of the
mailing list for the eCos project.
Re: ramfs problems
- From: Peter Graf <p dot graf at itknet dot de>
- To: ecos-discuss at sources dot redhat dot com
- Date: Thu, 14 Feb 2002 12:27:07 +0100
- Subject: Re: [ECOS] ramfs problems
>Don't know if it's related but did you apply this fix to fread.cxx?
This has immediately fixed this ramfs problem!
Thanks a lot for your kind help!!!
What remains is the other problem, that a thread blocked by fgetc() on
serial line causes lockup of fread() access on ramfs by another thread.
I remember an earlier problem that came from the conjunction of
Cyg_StdioStream::refill_read_buffer() and cyg_libc_stdio_flush_all_but().
The former routine locks the stream and calls cyg_stdio_read() which blocks
on a condition variable, waiting for characters coming from the underlying
device. Then, the other thread calls something that implies
cyg_libc_stdio_flush_all_but() which spins trying to flush the other
(locked) stream. IIRC fread() implies cyg_libc_stdio_flush_all_but(), so
that would explain it.
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss