* [Xenomai-help] how to release file descriptor after application crash
@ 2007-04-12 7:24 Jochen Behnke
2007-04-12 7:32 ` Sebastian Smolorz
0 siblings, 1 reply; 4+ messages in thread
From: Jochen Behnke @ 2007-04-12 7:24 UTC (permalink / raw)
To: xenomai
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.
Regards
Jochen
_______________________________________________________________
SMS schreiben mit WEB.DE FreeMail - einfach, schnell und
kostenguenstig. Jetzt gleich testen! http://f.web.de/?mc=021192
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai-help] how to release file descriptor after application crash
2007-04-12 7:24 [Xenomai-help] how to release file descriptor after application crash Jochen Behnke
@ 2007-04-12 7:32 ` Sebastian Smolorz
2007-04-12 7:46 ` Jan Kiszka
0 siblings, 1 reply; 4+ messages in thread
From: Sebastian Smolorz @ 2007-04-12 7:32 UTC (permalink / raw)
To: Jochen Behnke; +Cc: xenomai
Jochen Behnke wrote:
> 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.
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)
--
Sebastian
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai-help] how to release file descriptor after application crash
2007-04-12 7:32 ` Sebastian Smolorz
@ 2007-04-12 7:46 ` Jan Kiszka
0 siblings, 0 replies; 4+ messages in thread
From: Jan Kiszka @ 2007-04-12 7:46 UTC (permalink / raw)
To: Sebastian Smolorz; +Cc: xenomai
[-- Attachment #1: Type: text/plain, Size: 924 bytes --]
Sebastian Smolorz wrote:
> Jochen Behnke wrote:
>> 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.
>
> 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)
>
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
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 250 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai-help] how to release file descriptor after application crash
@ 2007-04-12 9:25 Jochen Behnke
0 siblings, 0 replies; 4+ messages in thread
From: Jochen Behnke @ 2007-04-12 9:25 UTC (permalink / raw)
To: Jan Kiszka, Sebastian Smolorz; +Cc: xenomai
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
> Sebastian Smolorz wrote:
> > Jochen Behnke wrote:
> >> 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.
> >
> > 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)
> >
>
> 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
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2007-04-12 9:25 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-04-12 7:24 [Xenomai-help] how to release file descriptor after application crash Jochen Behnke
2007-04-12 7:32 ` Sebastian Smolorz
2007-04-12 7:46 ` Jan Kiszka
-- strict thread matches above, loose matches on Subject: below --
2007-04-12 9:25 Jochen Behnke
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.