wait_event_interruptible_timeout() not sleeping accurately

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In a user thread I block on wait_event_interruptible_timeout() for about 3300 usecs or
until my threaded interrupt handler calls wake_up_interruptible() when the hardware event
happens.

This seems to work fine for the case when the event actually happens.  But for the timeout
case, the function wait_event_interruptible_timeout() is sleeping 9000 usecs or so rather
than 3300 usecs as requested.  I confirmed this by toggling a GPIO pin before and after
the call and feeding that signal to a logic analyzer.

The user thread is RT round robin at about a priority 5.

Am I doing something disallowed under PREEMPT_RT?
What could be the reason for the inaccurate wait_event_interruptible_timeout() timeout?


			ret = wait_event_interruptible_timeout(bh->rx_waitq,
				bh->rx_intr_flag,
				usecs_to_jiffies(aTimeoutUSecs) );




[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux