diff options
| author | Linus Walleij <linus.walleij@linaro.org> | 2011-02-10 10:11:07 -0500 |
|---|---|---|
| committer | Chris Ball <cjb@laptop.org> | 2011-03-15 13:49:25 -0400 |
| commit | 449bdc2d9d62794246351d10dd4534a239bf06b6 (patch) | |
| tree | 896077799b14e4ddafeeb54b508f9702d0dff7e2 /drivers/mmc/host | |
| parent | 3383433ce70613514593c940a2ae4e6ab19f2b28 (diff) | |
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>
Diffstat (limited to 'drivers/mmc/host')
| -rw-r--r-- | drivers/mmc/host/tmio_mmc.c | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/drivers/mmc/host/tmio_mmc.c b/drivers/mmc/host/tmio_mmc.c index 699b6ab209b2..0e4998fa6fc5 100644 --- a/drivers/mmc/host/tmio_mmc.c +++ b/drivers/mmc/host/tmio_mmc.c | |||
| @@ -836,13 +836,8 @@ static void tmio_mmc_start_dma_rx(struct tmio_mmc_host *host) | |||
| 836 | if (desc) { | 836 | if (desc) { |
| 837 | desc->callback = tmio_dma_complete; | 837 | desc->callback = tmio_dma_complete; |
| 838 | desc->callback_param = host; | 838 | desc->callback_param = host; |
| 839 | cookie = desc->tx_submit(desc); | 839 | cookie = dmaengine_submit(desc); |
| 840 | if (cookie < 0) { | 840 | dma_async_issue_pending(chan); |
| 841 | desc = NULL; | ||
| 842 | ret = cookie; | ||
| 843 | } else { | ||
| 844 | chan->device->device_issue_pending(chan); | ||
| 845 | } | ||
| 846 | } | 841 | } |
| 847 | dev_dbg(&host->pdev->dev, "%s(): mapped %d -> %d, cookie %d, rq %p\n", | 842 | dev_dbg(&host->pdev->dev, "%s(): mapped %d -> %d, cookie %d, rq %p\n", |
| 848 | __func__, host->sg_len, ret, cookie, host->mrq); | 843 | __func__, host->sg_len, ret, cookie, host->mrq); |
| @@ -915,11 +910,7 @@ static void tmio_mmc_start_dma_tx(struct tmio_mmc_host *host) | |||
| 915 | if (desc) { | 910 | if (desc) { |
| 916 | desc->callback = tmio_dma_complete; | 911 | desc->callback = tmio_dma_complete; |
| 917 | desc->callback_param = host; | 912 | desc->callback_param = host; |
| 918 | cookie = desc->tx_submit(desc); | 913 | cookie = dmaengine_submit(desc); |
| 919 | if (cookie < 0) { | ||
| 920 | desc = NULL; | ||
| 921 | ret = cookie; | ||
| 922 | } | ||
| 923 | } | 914 | } |
| 924 | dev_dbg(&host->pdev->dev, "%s(): mapped %d -> %d, cookie %d, rq %p\n", | 915 | dev_dbg(&host->pdev->dev, "%s(): mapped %d -> %d, cookie %d, rq %p\n", |
| 925 | __func__, host->sg_len, ret, cookie, host->mrq); | 916 | __func__, host->sg_len, ret, cookie, host->mrq); |
| @@ -963,7 +954,7 @@ static void tmio_issue_tasklet_fn(unsigned long priv) | |||
| 963 | struct tmio_mmc_host *host = (struct tmio_mmc_host *)priv; | 954 | struct tmio_mmc_host *host = (struct tmio_mmc_host *)priv; |
| 964 | struct dma_chan *chan = host->chan_tx; | 955 | struct dma_chan *chan = host->chan_tx; |
| 965 | 956 | ||
| 966 | chan->device->device_issue_pending(chan); | 957 | dma_async_issue_pending(chan); |
| 967 | } | 958 | } |
| 968 | 959 | ||
| 969 | static void tmio_tasklet_fn(unsigned long arg) | 960 | static void tmio_tasklet_fn(unsigned long arg) |
