summaryrefslogtreecommitdiff
path: root/drivers/mmc/uniphier-sd.c
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2016-07-19 21:56:13 +0900
committerMasahiro Yamada <yamada.masahiro@socionext.com>2016-07-24 00:13:10 +0900
commit4e3d84066e09c9ab6cee2102db7a2c51090962a4 (patch)
treea563f3c3f0f0ef2426ef96157fbb628f41c47851 /drivers/mmc/uniphier-sd.c
parent72a64348ef937daaca0553e9d8d75b5774555e57 (diff)
ARM: uniphier: use (devm_)ioremap() instead of map_sysmem()
This does not have much impact on behavior, but makes code look more more like Linux. The use of devm_ioremap() often helps to delete .remove callbacks entirely. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'drivers/mmc/uniphier-sd.c')
-rw-r--r--drivers/mmc/uniphier-sd.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/mmc/uniphier-sd.c b/drivers/mmc/uniphier-sd.c
index 152e987397..02df809bcf 100644
--- a/drivers/mmc/uniphier-sd.c
+++ b/drivers/mmc/uniphier-sd.c
@@ -1,5 +1,6 @@
/*
- * Copyright (C) 2016 Masahiro Yamada <yamada.masahiro@socionext.com>
+ * Copyright (C) 2016 Socionext Inc.
+ * Author: Masahiro Yamada <yamada.masahiro@socionext.com>
*
* SPDX-License-Identifier: GPL-2.0+
*/
@@ -7,7 +8,6 @@
#include <common.h>
#include <clk.h>
#include <fdtdec.h>
-#include <mapmem.h>
#include <mmc.h>
#include <dm/device.h>
#include <linux/compat.h>
@@ -660,7 +660,7 @@ int uniphier_sd_probe(struct udevice *dev)
if (base == FDT_ADDR_T_NONE)
return -EINVAL;
- priv->regbase = map_sysmem(base, SZ_2K);
+ priv->regbase = devm_ioremap(dev, base, SZ_2K);
if (!priv->regbase)
return -ENOMEM;
@@ -735,7 +735,6 @@ int uniphier_sd_remove(struct udevice *dev)
{
struct uniphier_sd_priv *priv = dev_get_priv(dev);
- unmap_sysmem(priv->regbase);
mmc_destroy(priv->mmc);
return 0;