Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mmc: tmio_mmc: use dmaengine helpers, drop submit check

Use the new dmaengine helper functions, and drop the error check
on the returned cookier from the dmaengine - we recently
established that this is really not allowed to fail.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Chris Ball <cjb@laptop.org>

authored by

Linus Walleij and committed by
Chris Ball
449bdc2d 3383433c

+4 -13
+4 -13
drivers/mmc/host/tmio_mmc.c
··· 836 836 if (desc) { 837 837 desc->callback = tmio_dma_complete; 838 838 desc->callback_param = host; 839 - cookie = desc->tx_submit(desc); 840 - if (cookie < 0) { 841 - desc = NULL; 842 - ret = cookie; 843 - } else { 844 - chan->device->device_issue_pending(chan); 845 - } 839 + cookie = dmaengine_submit(desc); 840 + dma_async_issue_pending(chan); 846 841 } 847 842 dev_dbg(&host->pdev->dev, "%s(): mapped %d -> %d, cookie %d, rq %p\n", 848 843 __func__, host->sg_len, ret, cookie, host->mrq); ··· 910 915 if (desc) { 911 916 desc->callback = tmio_dma_complete; 912 917 desc->callback_param = host; 913 - cookie = desc->tx_submit(desc); 914 - if (cookie < 0) { 915 - desc = NULL; 916 - ret = cookie; 917 - } 918 + cookie = dmaengine_submit(desc); 918 919 } 919 920 dev_dbg(&host->pdev->dev, "%s(): mapped %d -> %d, cookie %d, rq %p\n", 920 921 __func__, host->sg_len, ret, cookie, host->mrq); ··· 954 963 struct tmio_mmc_host *host = (struct tmio_mmc_host *)priv; 955 964 struct dma_chan *chan = host->chan_tx; 956 965 957 - chan->device->device_issue_pending(chan); 966 + dma_async_issue_pending(chan); 958 967 } 959 968 960 969 static void tmio_tasklet_fn(unsigned long arg)