[PATCH 06/10] staging: comedi: allow buffer wraparound in comedi_read()

2015-10-12 Thread Ian Abbott
`comedi_read()` copies data from the acquisition data buffer, which is cyclic, to the user buffer using a single call to `copy_to_user()`. It currently avoids having to deal with wraparound of the cyclic buffer by limiting the amount it copies (and the amount returned to the user). Change it to

[PATCH 06/10] staging: comedi: allow buffer wraparound in comedi_read()

2015-10-12 Thread Ian Abbott
`comedi_read()` copies data from the acquisition data buffer, which is cyclic, to the user buffer using a single call to `copy_to_user()`. It currently avoids having to deal with wraparound of the cyclic buffer by limiting the amount it copies (and the amount returned to the user). Change it to