From: H Hartley Sweeten Date: Fri, 20 Jun 2014 17:58:28 +0000 (-0700) Subject: staging: comedi: introduce comedi_buf_n_bytes_ready() X-Git-Tag: omap-for-v3.17/fixes-against-rc2~166^2~1552 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f4f3f7cf27e7ae015672b59ec40c7deabeaf5d2e;p=pandora-kernel.git staging: comedi: introduce comedi_buf_n_bytes_ready() Introduce an inline helper to return the number of bytes that are ready to read from the comedi_async buffer. Use the helper in the comedi drivers that currently do the calculation as part of the (*poll) operation. Also, use the helper in comedi_fops where the calculation is used as part of the subdevice going nonbusy. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed