projects
/
comedi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cff300f
)
Fix problem detecting DMA overflows at buffer wraparound
author
David Schleef
<ds@schleef.org>
Thu, 10 Oct 2002 01:17:39 +0000
(
01:17
+0000)
committer
David Schleef
<ds@schleef.org>
Thu, 10 Oct 2002 01:17:39 +0000
(
01:17
+0000)
comedi/drivers/ni_mio_common.c
patch
|
blob
|
history
diff --git
a/comedi/drivers/ni_mio_common.c
b/comedi/drivers/ni_mio_common.c
index a97c63cd60402c25825738d0f141a7144f90dafd..daf501b9abf7ea87a8ec74850240fc15d0d9390d 100644
(file)
--- a/
comedi/drivers/ni_mio_common.c
+++ b/
comedi/drivers/ni_mio_common.c
@@
-355,7
+355,7
@@
static void mite_handle_a_linkc(struct mite_struct *mite, comedi_device *dev)
writel(CHOR_CLRLC, mite->mite_io_addr+MITE_CHOR+CHAN_OFFSET(mite->chan));
nbytes = mite_bytes_transferred(mite, 0);
- if(
nbytes >= async->buf_free_count
){
+ if(
(int)(nbytes - async->buf_free_count) >= 0
){
printk("ni_mio_common: BUG: DMA overwrite of free area\n");
ni_ai_reset(dev,s);
async->events |= COMEDI_CB_OVERFLOW;