Skip to contentSkip to conversation

how to release file descriptor after application crash

Xenomai-help Jochen Behnke 1 participant 1 message Apr 12, 2007

lore
Share & tools
lore
#0 lore raw

Hello Sebastian and Jan,

the following command line solved the problem :-)

# echo <fildescr_to_cleanup>   > /proc/xenomai/rtdm/open_fildes

Thanks for your help.

Regards

Jochen

Quoted 15 lines
Quoted 10 lines · Sebastian Smolorz
Quoted 8 lines · Jochen Behnke

Hello,

is there any way to release a file descriptor associated with a rtdm device after an application crash ? The reason I'm asking this is the following:
My application uses a rtdm device that can only be used in exclusive mode. When the application crashes while the device was opened, I have to reboot the system in order be able to use the device again. Is there a way to release the file descriptor or to close the device without rebooting.

Quoted 3 lines

See the note to the description of rt_dev_close in the RTDM API documentation.
(http://www.xenomai.org/documentation/trunk/html/api/group__userapi.html#ga34c1ddf4e2deb727a1ab3cd648ce5d9)

Quoted 8 lines

For trunk, the paragraph about stalled descriptors need to be removed (good that you referred to it). RTDM of upcoming Xenomai 2.4 performs automatic file descriptor cleanup now.

Jan

_______________________________________________________________
SMS schreiben mit WEB.DE FreeMail - einfach, schnell und kostenguenstig. Jetzt gleich testen! http://f.web.de/?mc=021192