From: H Hartley Sweeten Date: Tue, 4 Nov 2014 17:54:33 +0000 (-0700) Subject: staging: comedi: addi_apci_3120: fix apci3120_ai_insn_read() X-Git-Tag: omap-for-v3.19/fixes-rc1~73^2~306 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=89e9057b50369474c1e701faccdeedf08566ec57;p=pandora-kernel.git staging: comedi: addi_apci_3120: fix apci3120_ai_insn_read() Now that the scanning and interrupt support have been removed from this function it can be refactored to work correctly. The comedi core expects (*insn_read) functions to read insn->n values from the hardware and return the number of samples read. This function currently just reads one sample but it returns insn->n. Fix this function to work like the core expects. Use comedi_timeout() to prevent a possible deadlock in the loop that waits for the end-of-conversion. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed