Stephan asked: > In the ioctl() the result is checked for several possible errors, among > which is B_INTERRUPTED. All this happens in a while loop and in the > B_INTERRUPTED case, the thread will simply go back into the loop. > > Now I have learned that killing the thread that does the ioctl() will make > it busy loop, because B_INTERRUPTED is returned from acquire_sem_etc(). > > How is this done the correct way? By considering B_INTERRUPTED as an error and then simply returns from the ioctl()? Any signal raised by the caller thread, it will never be because user pressed Ctrl+S to suspend it... Philippe.