Jan Kiszka wrote:
> Wolfgang Grandegger wrote:
>> Roland Tollenaar wrote:
>>> Hi Wolfgang,
>>>
>>>>> See below. This does not look good. Does it mean that I am only 
>>>>> always reading out the last socket and the rest are having their 
>>>>> buffers pumped full? Should I be unbinding somehow?
>>>> Don't know, check your code ;-).
>>> Thanks that is exactly what I did because I thought I was unbinding. 
>>> rt_dev_close () should do that for me correct? Its not. At least not 
>>> reliably. :(
>> That's wired. You mean you called rt_dev_close() and the socket still 
>> does show up in /proc/rtcan_sockets? Is it possible that there is 
>> another task still using that socket? Could you show the code fragment 
>> doing that.
> 
> Recall that up to Xenomai 2.4 RTDM device/socket closing may fail (with
> -EAGAIN) when some other thread is currently using it and doesn't
> release it immediately when being "asked". That means for now you should
> loop over [rt_dev_]close as long as EAGAIN is returned.

Roland, could you please check the return code of [rt_dev_]close. 
Nevertheless, I'm still puzzled why the socket shows up in 
/proc/rtcan/sockets because rtcan_raw_close() is called before returning 
-EAGAIN and the error mask shown there is weired as well.
Roland, do you perform the open and close in a serialized way (same 
task) and in nrt context?

Wolfgang.



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

Reply via email to