This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
Re: cyg_selwakeup and performance impact?
- From: Jonathan Larmour <jifl at eCosCentric dot com>
- To: Zhichao Hong <zhichao dot hong at gmail dot com>
- Cc: ecos-discuss at ecos dot sourceware dot org
- Date: Wed, 15 Oct 2008 17:37:33 +0100
- Subject: Re: [ECOS] cyg_selwakeup and performance impact?
- Openpgp: id=A5FB74E6
- References: <3fea10110810150858y28fc2598ibb535bae61a8737d@mail.gmail.com>
Zhichao Hong wrote:
> Hi,
>
> One part of our application, the read thread cannot keep up with the
> write for the serial driver when using pselect. Since in the
> serial.c, the cyg_selwakeup is used to tell the reader that is blocked
> by a pselect when there is something available. Sometimes, we found
> that the thread will not get waken up when there are data to read. A
> workaround that we did is to comment out the condition in the function
> serial_rcv_char() that wake up the thread in serial.c:
> //if( cbuf->nb == 0 )
> cyg_selwakeup( &cbuf->selinfo );
Surely the best thing is to find out why that thread isn't getting woken up
when there's data?
Jifl
--
eCosCentric Limited http://www.eCosCentric.com/ The eCos experts
Barnwell House, Barnwell Drive, Cambridge, UK. Tel: +44 1223 245571
Registered in England and Wales: Reg No 4422071.
------["Si fractum non sit, noli id reficere"]------ Opinions==mine
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss