usleep implementation using poll() or select()