Petr Cervenka wrote:
> Hello,
> I'm trying to port a  driver of a AD card to RTDM.
> When I use rtdm_event_timedwait in IOCTL handler (called from NRT user app), 
> the system will hang-up immediately.
> Does it have something to do with: 
> https://mail.gna.org/public/xenomai-help/2006-03/msg00035.html
> , ie. it's not possible to call wait /caller blocking functions from 
> non-real-time, is it?

Yep, that's exactly the point, it's an illegal usage.

And the fact that this still causes a crash instead of some more
graceful failure reminds me of one reason why I asked for the new
XENO_ASSERT macro: adding debug checks for such mistakes to RTDM.

> Is there a posibility to do some workaround to solve this or other 
> alternative. I need to wait couple of seconds for IRQ from device.

A) turn the waiter into a xenomai shadow thread, even if it will wait
for several seconds without hard timing constraints (use priority 1 e.g.)

B) signal the event arrival via rtdm_nrtsig to a Linux handler which
could in turn wake up a non-RT waiter blocking on standard Linux
wait_queue or so

The latter options involves more work and code and should only be picked
if A) is really not desired.

> 
> My configuration: kernel-2.6.15.6, adeos-ipipe-2.6.15-i386-1.2-01, 
> xenomai-2.1.0
> Thanks for any help
> 
> Petr Cervenka
> 

Jan

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to