From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <5069BF3F.1010900@xenomai.org> Date: Mon, 01 Oct 2012 18:05:19 +0200 From: Gilles Chanteperdrix MIME-Version: 1.0 References: <5069BD62.5030706@xenomai.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Xenomai] Qeustion about rtdm_event_timedwait List-Id: Discussions about the Xenomai project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Andrey Nechypurenko Cc: xenomai@xenomai.org On 10/01/2012 06:01 PM, Andrey Nechypurenko wrote: >> On 10/01/2012 05:51 PM, Andrey Nechypurenko wrote: >>> driver's read() function is registered as *read_nrt* >> >> That is the problem. > > Thank you Gilles! > If you want to wake up a regular thread, you should signal an rtdm_nrtsig in the interrupt handler, and the nrtsig handler wakes up the linux thread using regular linux services such as wake_up(). But in that case, of course, do not expect low latencies for this thread. Also note that rtdm_event_wait works like a semaphore, not like a condition variable: it has a counter, rtdm_event_wait will return immediately as many times as rtdm_event_signal was called. -- Gilles.