Reputation: 21
I have a multi-threaded application in which one thread polls on a FD of my pseudo character driver. Can other threads use same FD for ioctl calls?
I am using epoll on the FD.
My guess is yes. I would like to know if anyone tried this. If so , what is the result?
Upvotes: 2
Views: 2645
Reputation: 3055
Sure, they can. If your driver is written correctly (i.e. with multithreading in mind) and all shared data is properly protected, then you can do with fd everything you want (until you close it).
Upvotes: 1