[U-Boot] [PATCH 9/9] mmc: sunxi: Mark end of DM_MMC #ifdefs

Andre Przywara andre.przywara at arm.com
Sat Jan 19 01:30:55 UTC 2019


The Allwinner MMC supports both the legacy approach and the driver model,
at the cost of quite some #ifdefs.

Mark the closing #endifs with their respective config symbol, to make it
more obvious where each part ends and begins.

Signed-off-by: Andre Przywara <andre.przywara at arm.com>
---
 drivers/mmc/sunxi_mmc.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/sunxi_mmc.c b/drivers/mmc/sunxi_mmc.c
index 374775194d..ee0bc9da89 100644
--- a/drivers/mmc/sunxi_mmc.c
+++ b/drivers/mmc/sunxi_mmc.c
@@ -104,7 +104,7 @@ static int mmc_resource_init(int sdc_no)
 
 	return ret;
 }
-#endif
+#endif	/* !DM_MMC */
 
 static int mmc_set_mod_clk(struct sunxi_mmc_priv *priv, unsigned int hz)
 {
@@ -566,7 +566,7 @@ struct mmc *sunxi_mmc_init(int sdc_no)
 
 	return mmc_create(cfg, priv);
 }
-#else
+#else	/* DM_MMC */
 
 static int sunxi_mmc_set_ios(struct udevice *dev)
 {
@@ -747,4 +747,4 @@ U_BOOT_DRIVER(sunxi_mmc_drv) = {
 	.platdata_auto_alloc_size = sizeof(struct sunxi_mmc_plat),
 	.priv_auto_alloc_size = sizeof(struct sunxi_mmc_priv),
 };
-#endif
+#endif	/* DM_MMC */
-- 
2.14.5



More information about the U-Boot mailing list