From: H Hartley Sweeten Date: Wed, 14 Jan 2015 17:05:12 +0000 (-0700) Subject: staging: comedi: pcl818: use common function to setup dma X-Git-Tag: fixes-v4.0-rc1~99^2~365 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=421f1b6832efd618c5ce3e639642a49d38ba5a37;p=pandora-kernel.git staging: comedi: pcl818: use common function to setup dma THe pcl818_ai_setup_dma() and pcl818_ai_setup_next_dma() functions are similar other than the buffer switch and the inclusion of the "unread_samples" in pcl818_ai_setup_next_dma() when calculating the dma size. Merge these two functions by initializing the 'dma->cur_dma' in the callers and passing '0' for the "unread_samples" when first starting the DMA. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed