Skip to content
Snippets Groups Projects
Commit acb73d4f authored by Samuel Iglesias Gonsalvez's avatar Samuel Iglesias Gonsalvez
Browse files

pts/gnurabbit: added timeout in case of wait for IRQ.

The timeout was setup to 1 second (HZ constant in jiffies) to fix a problem
in the test/spec/python/test07.py.

This test file was always waiting for the IRQ from the first DMA.

The DMA transfer was properly finished but the IRQ doesn't arrive. It seems
that the problem behind is a wrong initialization (reset?) of the corresponding
DMA core in the Firmware.

This is a workaround of the problem.
parent 06d9a55b
No related branches found
No related tags found
No related merge requests found
......@@ -551,7 +551,8 @@ static long rr_ioctl(struct file *f, unsigned int cmd, unsigned long arg)
ret = -EAGAIN; /* already happened */
break;
}
wait_event_interruptible(dev->q, count != dev->irqcount);
/* IRQ timeout of 1 second */
wait_event_interruptible_timeout(dev->q, count != dev->irqcount, HZ);
if (signal_pending(current))
ret = -ERESTARTSYS;
break;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment