All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pramod Gurav <pramod.gurav@smartplayin.com>
To: linux-kernel@vger.kernel.org
Cc: David Brown <davidb@codeaurora.org>,
	Daniel Walker <dwalker@fifo99.com>,
	Bryan Huntsman <bryanh@codeaurora.org>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	linux-mmc@vger.kernel.org, linux-arm-msm@vger.kernel.org
Subject: [PATCH 3/5] mmc: msm_sdcc: Replace pr_ with dev_
Date: Tue, 16 Sep 2014 16:47:46 +0530	[thread overview]
Message-ID: <1410866268-15185-4-git-send-email-pramod.gurav@smartplayin.com> (raw)
In-Reply-To: <1410866268-15185-1-git-send-email-pramod.gurav@smartplayin.com>

This replaces pr_* with dev_ for message logging and also does away
with printing function names in logs.

Cc: David Brown <davidb@codeaurora.org>
Cc: Daniel Walker <dwalker@fifo99.com>
Cc: Bryan Huntsman <bryanh@codeaurora.org>
CC: Ulf Hansson <ulf.hansson@linaro.org>
CC: linux-mmc@vger.kernel.org
CC: linux-arm-msm@vger.kernel.org
Signed-off-by: Pramod Gurav <pramod.gurav@smartplayin.com>
---
 drivers/mmc/host/msm_sdcc.c |   34 ++++++++++++++++++----------------
 1 file changed, 18 insertions(+), 16 deletions(-)

diff --git a/drivers/mmc/host/msm_sdcc.c b/drivers/mmc/host/msm_sdcc.c
index 3e0536d..2111c03 100644
--- a/drivers/mmc/host/msm_sdcc.c
+++ b/drivers/mmc/host/msm_sdcc.c
@@ -1177,7 +1177,7 @@ msmsdcc_probe(struct platform_device *pdev)
 
 	/* must have platform data */
 	if (!plat) {
-		pr_err("%s: Platform data not available\n", __func__);
+		dev_err(&pdev->dev, "Platform data not available\n");
 		ret = -EINVAL;
 		goto out;
 	}
@@ -1186,7 +1186,7 @@ msmsdcc_probe(struct platform_device *pdev)
 		return -EINVAL;
 
 	if (pdev->resource == NULL || pdev->num_resources < 2) {
-		pr_err("%s: Invalid resource\n", __func__);
+		dev_err(&pdev->dev, "Invalid resource\n");
 		return -ENXIO;
 	}
 
@@ -1196,9 +1196,8 @@ msmsdcc_probe(struct platform_device *pdev)
 						  "cmd_irq");
 	stat_irqres = platform_get_resource_byname(pdev, IORESOURCE_IRQ,
 						   "status_irq");
-
 	if (!cmd_irqres || !memres) {
-		pr_err("%s: Invalid resource\n", __func__);
+		dev_err(&pdev->dev, "Invalid resource\n");
 		return -ENXIO;
 	}
 
@@ -1264,7 +1263,7 @@ msmsdcc_probe(struct platform_device *pdev)
 
 	ret = clk_set_rate(host->clk, msmsdcc_fmin);
 	if (ret) {
-		pr_err("%s: Clock rate set failed (%d)\n", __func__, ret);
+		dev_err(&pdev->dev, "Clock rate set failed (%d)\n", ret);
 		goto dma_free;
 	}
 
@@ -1328,14 +1327,14 @@ msmsdcc_probe(struct platform_device *pdev)
 				  DRIVER_NAME " (slot)",
 				  host);
 		if (ret) {
-			pr_err("%s: Unable to get slot IRQ %d (%d)\n",
+			dev_err(&pdev->dev, "%s: Unable to get slot IRQ %d (%d)\n",
 			       mmc_hostname(mmc), host->stat_irq, ret);
 			goto clk_disable;
 		}
 	} else if (plat->register_status_notify) {
 		plat->register_status_notify(msmsdcc_status_notify_cb, host);
 	} else if (!plat->status)
-		pr_err("%s: No card detect facilities available\n",
+		dev_err(&pdev->dev, "%s: No card detect facilities available\n",
 		       mmc_hostname(mmc));
 	else {
 		init_timer(&host->timer);
@@ -1364,28 +1363,31 @@ msmsdcc_probe(struct platform_device *pdev)
 	mmc_set_drvdata(pdev, mmc);
 	mmc_add_host(mmc);
 
-	pr_info("%s: Qualcomm MSM SDCC at 0x%016llx irq %d,%d dma %d\n",
+	dev_info(&pdev->dev, "%s: Qualcomm MSM SDCC at 0x%016llx irq %d,%d dma %d\n",
 		mmc_hostname(mmc), (unsigned long long)memres->start,
 		(unsigned int) cmd_irqres->start,
 		(unsigned int) host->stat_irq, host->dma.channel);
-	pr_info("%s: 4 bit data mode %s\n", mmc_hostname(mmc),
+	dev_info(&pdev->dev, "%s: 4 bit data mode %s\n", mmc_hostname(mmc),
 		(mmc->caps & MMC_CAP_4_BIT_DATA ? "enabled" : "disabled"));
-	pr_info("%s: MMC clock %u -> %u Hz, PCLK %u Hz\n",
+	dev_info(&pdev->dev, "%s: MMC clock %u -> %u Hz, PCLK %u Hz\n",
 		mmc_hostname(mmc), msmsdcc_fmin, msmsdcc_fmax, host->pclk_rate);
-	pr_info("%s: Slot eject status = %d\n", mmc_hostname(mmc), host->eject);
-	pr_info("%s: Power save feature enable = %d\n",
+	dev_info(&pdev->dev, "%s: Slot eject status = %d\n", mmc_hostname(mmc),
+		host->eject);
+	dev_info(&pdev->dev, "%s: Power save feature enable = %d\n",
 		mmc_hostname(mmc), msmsdcc_pwrsave);
 
 	if (host->dma.channel != -1) {
-		pr_info("%s: DM non-cached buffer at %p, dma_addr 0x%.8x\n",
+		dev_info(&pdev->dev, "%s: DM non-cached buffer at %p, dma_addr 0x%.8x\n",
 			mmc_hostname(mmc), host->dma.nc, host->dma.nc_busaddr);
-		pr_info("%s: DM cmd busaddr 0x%.8x, cmdptr busaddr 0x%.8x\n",
+		dev_info(&pdev->dev, "%s: DM cmd busaddr 0x%.8x, cmdptr busaddr 0x%.8x\n",
 			mmc_hostname(mmc), host->dma.cmd_busaddr,
 			host->dma.cmdptr_busaddr);
 	} else
-		pr_info("%s: PIO transfer enabled\n", mmc_hostname(mmc));
+		dev_info(&pdev->dev, "%s: PIO transfer enabled\n",
+			 mmc_hostname(mmc));
 	if (host->timer.function)
-		pr_info("%s: Polling status mode enabled\n", mmc_hostname(mmc));
+		dev_info(&pdev->dev, "%s: Polling status mode enabled\n",
+			 mmc_hostname(mmc));
 
 	return 0;
 
-- 
1.7.9.5

  parent reply	other threads:[~2014-09-16 11:17 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-16 11:17 [PATCH 0/5] mmc: msm_sdcc: Cleanups Pramod Gurav
2014-09-16 11:17 ` [PATCH 1/5] mmc: msm_sdcc: Switch to using managed resources Pramod Gurav
2014-09-16 11:17 ` [PATCH 2/5] mmc: msm_sdcc: Add support for platform_driver remove function Pramod Gurav
2014-09-16 11:17 ` Pramod Gurav [this message]
2014-09-16 11:17 ` [PATCH 4/5] mmc: msm_sdcc: Remove duplicate check around dmares Pramod Gurav
2014-09-16 11:17 ` [PATCH 5/5] mmc: msm_sdcc: Remove unwanted initializations in probe Pramod Gurav

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1410866268-15185-4-git-send-email-pramod.gurav@smartplayin.com \
    --to=pramod.gurav@smartplayin.com \
    --cc=bryanh@codeaurora.org \
    --cc=davidb@codeaurora.org \
    --cc=dwalker@fifo99.com \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=ulf.hansson@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.