staging: comedi: comedi_buf: cleanup comedi_buf_munge()
Refactor this function so there is a single return point and only
one BUG_ON check. The BUG_ON needs to be looked at to see if it
can be safely removed.
Clarify the test in the munge loop that checks for a block copy
that would extend pass the end of the prealloc_buf.
Reword the comment about the need for the smp_wmb().
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>