Skip to content

Commit

Permalink
staging: comedi: rti800: change return of rti800_ai_insn_read()
Browse files Browse the repository at this point in the history
The comedi core expects the (*insn_read) functions to return the
number of data values actually read. Change the return from 'i'
to 'insn->n' to make this clearer.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Apr 9, 2013
1 parent aac49c3 commit 0181ae7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/staging/comedi/drivers/rti800.c
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ static int rti800_ai_insn_read(struct comedi_device *dev,
data[i] ^= 0x800;
}

return i;
return insn->n;
}

static int rti800_ao_insn_read(struct comedi_device *dev,
Expand Down

0 comments on commit 0181ae7

Please sign in to comment.