summaryrefslogtreecommitdiff
path: root/drivers/mmc
diff options
context:
space:
mode:
authorSamuel Holland <samuel@sholland.org>2021-10-21 07:52:57 +0300
committerAndre Przywara <andre.przywara@arm.com>2022-01-30 04:25:00 +0300
commitfb6f67013e3a6d74988615a4bea5f5926ec328d5 (patch)
tree3cea7b5dcab0682caecacfad8be6c1c1217e122b /drivers/mmc
parent35ae126c16a6a9149edc6638faaa247f67b8a400 (diff)
downloadu-boot-fb6f67013e3a6d74988615a4bea5f5926ec328d5.tar.xz
mmc: sunxi: Use DM_GPIO flags to set pull-up
Now that the sunxi_gpio driver handles pull-up/down via the driver model, pin configuration does not need a platform-specific function. Signed-off-by: Samuel Holland <samuel@sholland.org> Tested-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/sunxi_mmc.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/mmc/sunxi_mmc.c b/drivers/mmc/sunxi_mmc.c
index 4bf8a9b92c..1bb7b6d0e9 100644
--- a/drivers/mmc/sunxi_mmc.c
+++ b/drivers/mmc/sunxi_mmc.c
@@ -702,12 +702,8 @@ static int sunxi_mmc_probe(struct udevice *dev)
return ret;
/* This GPIO is optional */
- if (!gpio_request_by_name(dev, "cd-gpios", 0, &priv->cd_gpio,
- GPIOD_IS_IN)) {
- int cd_pin = gpio_get_number(&priv->cd_gpio);
-
- sunxi_gpio_set_pull(cd_pin, SUNXI_GPIO_PULL_UP);
- }
+ gpio_request_by_name(dev, "cd-gpios", 0, &priv->cd_gpio,
+ GPIOD_IS_IN | GPIOD_PULL_UP);
upriv->mmc = &plat->mmc;