[PATCH 08/14] mmc: bcm2835: Use __func__ macro

Stefan Wahren stefan.wahren at i2se.com
Sat Jan 7 04:51:08 PST 2017


Instead of hardcoding the function name we better use the __func__
macro.

Signed-off-by: Stefan Wahren <stefan.wahren at i2se.com>
---
 drivers/mmc/host/bcm2835.c |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/mmc/host/bcm2835.c b/drivers/mmc/host/bcm2835.c
index 142f929..af957a8 100644
--- a/drivers/mmc/host/bcm2835.c
+++ b/drivers/mmc/host/bcm2835.c
@@ -1425,7 +1425,7 @@ static int bcm2835_probe(struct platform_device *pdev)
 	struct mmc_host *mmc;
 	int ret;
 
-	dev_dbg(dev, "bcm2835_probe\n");
+	dev_dbg(dev, "%s\n", __func__);
 	mmc = mmc_alloc_host(sizeof(*host), dev);
 	if (!mmc)
 		return -ENOMEM;
@@ -1493,12 +1493,12 @@ static int bcm2835_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, host);
 
-	dev_dbg(dev, "bcm2835_probe -> OK\n");
+	dev_dbg(dev, "%s -> OK\n", __func__);
 
 	return 0;
 
 err:
-	dev_dbg(dev, "bcm2835_probe -> err %d\n", ret);
+	dev_dbg(dev, "%s -> err %d\n", __func__, ret);
 	mmc_free_host(mmc);
 
 	return ret;
@@ -1508,7 +1508,7 @@ static int bcm2835_remove(struct platform_device *pdev)
 {
 	struct bcm2835_host *host = platform_get_drvdata(pdev);
 
-	dev_dbg(&pdev->dev, "bcm2835_remove\n");
+	dev_dbg(&pdev->dev, "%s\n", __func__);
 
 	mmc_remove_host(host->mmc);
 
@@ -1523,7 +1523,7 @@ static int bcm2835_remove(struct platform_device *pdev)
 	mmc_free_host(host->mmc);
 	platform_set_drvdata(pdev, NULL);
 
-	dev_dbg(&pdev->dev, "bcm2835_remove - OK\n");
+	dev_dbg(&pdev->dev, "%s - OK\n", __func__);
 	return 0;
 }
 
-- 
1.7.9.5




More information about the linux-rpi-kernel mailing list