diff mbox

[U-Boot] esdhc/usdhc: Fix warning when CONFIG_SYS_FSL_ESDHC_USE_PIO is not set

Message ID 1400851253-26159-1-git-send-email-trini@ti.com
State Accepted
Delegated to: Tom Rini
Headers show

Commit Message

Tom Rini May 23, 2014, 1:20 p.m. UTC
In 7168977 we made calls to check_and_invalidate_dcache_range()
conditional on !CONFIG_SYS_FSL_ESDHC_USE_PIO.  Only define this function
in this case as well.

Signed-off-by: Tom Rini <trini@ti.com>
---
 drivers/mmc/fsl_esdhc.c |    3 +++
 1 file changed, 3 insertions(+)

Comments

Tom Rini May 23, 2014, 2:11 p.m. UTC | #1
On Fri, May 23, 2014 at 09:20:53AM -0400, Tom Rini wrote:

> In 7168977 we made calls to check_and_invalidate_dcache_range()
> conditional on !CONFIG_SYS_FSL_ESDHC_USE_PIO.  Only define this function
> in this case as well.
> 
> Signed-off-by: Tom Rini <trini@ti.com>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/drivers/mmc/fsl_esdhc.c b/drivers/mmc/fsl_esdhc.c
index dca28f4..5541613 100644
--- a/drivers/mmc/fsl_esdhc.c
+++ b/drivers/mmc/fsl_esdhc.c
@@ -246,6 +246,7 @@  static int esdhc_setup_data(struct mmc *mmc, struct mmc_data *data)
 	return 0;
 }
 
+#ifndef CONFIG_SYS_FSL_ESDHC_USE_PIO
 static void check_and_invalidate_dcache_range
 	(struct mmc_cmd *cmd,
 	 struct mmc_data *data) {
@@ -255,6 +256,8 @@  static void check_and_invalidate_dcache_range
 	unsigned end = start+size ;
 	invalidate_dcache_range(start, end);
 }
+#endif
+
 /*
  * Sends a command out on the bus.  Takes the mmc pointer,
  * a command pointer, and an optional data pointer.