aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/tmio_mmc.h
diff options
context:
space:
mode:
authorGuennadi Liakhovetski <g.liakhovetski@gmx.de>2011-07-14 12:39:10 -0400
committerChris Ball <cjb@laptop.org>2011-07-21 10:35:07 -0400
commit162f43e31c5a376ec16336e5d0ac973373d54c89 (patch)
tree366ce758f78683291ca7db913276611ffaca00fb /drivers/mmc/host/tmio_mmc.h
parent332bdb506f800d177f6657247347a253dd5b5be8 (diff)
mmc: tmio: fix a deadlock
Currently the tmio-mmc driver contains a recursive runtime PM method invocation, which leads to a deadlock on a mutex. Avoid it by taking care not to request DMA too early. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc/host/tmio_mmc.h')
-rw-r--r--drivers/mmc/host/tmio_mmc.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/mmc/host/tmio_mmc.h b/drivers/mmc/host/tmio_mmc.h
index ba0d8e66001d..087d88023ba1 100644
--- a/drivers/mmc/host/tmio_mmc.h
+++ b/drivers/mmc/host/tmio_mmc.h
@@ -109,6 +109,7 @@ static inline void tmio_mmc_kunmap_atomic(struct scatterlist *sg,
109 109
110#if defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE) 110#if defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
111void tmio_mmc_start_dma(struct tmio_mmc_host *host, struct mmc_data *data); 111void tmio_mmc_start_dma(struct tmio_mmc_host *host, struct mmc_data *data);
112void tmio_mmc_enable_dma(struct tmio_mmc_host *host, bool enable);
112void tmio_mmc_request_dma(struct tmio_mmc_host *host, struct tmio_mmc_data *pdata); 113void tmio_mmc_request_dma(struct tmio_mmc_host *host, struct tmio_mmc_data *pdata);
113void tmio_mmc_release_dma(struct tmio_mmc_host *host); 114void tmio_mmc_release_dma(struct tmio_mmc_host *host);
114#else 115#else
@@ -117,6 +118,10 @@ static inline void tmio_mmc_start_dma(struct tmio_mmc_host *host,
117{ 118{
118} 119}
119 120
121static inline void tmio_mmc_enable_dma(struct tmio_mmc_host *host, bool enable)
122{
123}
124
120static inline void tmio_mmc_request_dma(struct tmio_mmc_host *host, 125static inline void tmio_mmc_request_dma(struct tmio_mmc_host *host,
121 struct tmio_mmc_data *pdata) 126 struct tmio_mmc_data *pdata)
122{ 127{