From: Rodolfo Giometti <giometti@linux.it>
To: linux-mips@linux-mips.org
Subject: [PATCH] 3/7 AU1100 MMC support
Date: Wed, 9 Aug 2006 23:09:27 +0200 [thread overview]
Message-ID: <20060809210927.GD13145@enneenne.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 340 bytes --]
Kernel messages fixup.
Signed-off-by: Rodolfo Giometti <giometti@linux.it>
--
GNU/Linux Solutions e-mail: giometti@enneenne.com
Linux Device Driver giometti@gnudd.com
Embedded Systems giometti@linux.it
UNIX programming phone: +39 349 2432127
[-- Attachment #2: patch-mmc-kmsg-fix --]
[-- Type: text/plain, Size: 2873 bytes --]
diff --git a/drivers/mmc/au1xmmc.c b/drivers/mmc/au1xmmc.c
index 6084bb8..560d6e3 100644
--- a/drivers/mmc/au1xmmc.c
+++ b/drivers/mmc/au1xmmc.c
@@ -54,13 +54,16 @@ #include "au1xmmc.h"
#define DRIVER_NAME "au1xxx-mmc"
-/* Set this to enable special debugging macros */
-
-#ifdef DEBUG
-#define DBG(fmt, idx, args...) printk("au1xx(%d): DEBUG: " fmt, idx, ##args)
+#ifdef CONFIG_MMC_DEBUG
+#define dbg(fmt, idx, args...) printk(KERN_DEBUG "%s(%d): DEBUG: " \
+ fmt, DRIVER_NAME, idx, ##args)
#else
-#define DBG(fmt, idx, args...)
+#define dbg(fmt, idx, args...)
#endif
+#define err(fmt, idx, args...) printk(KERN_DEBUG "%s(%d): ERROR: " \
+ fmt, DRIVER_NAME, idx, ##args)
+#define info(fmt, idx, args...) printk(KERN_INFO "%s(%d): " \
+ fmt, DRIVER_NAME, idx, ##args)
const struct {
u32 iobase;
@@ -445,18 +448,18 @@ static void au1xmmc_receive_pio(struct a
break;
if (status & SD_STATUS_RC) {
- DBG("RX CRC Error [%d + %d].\n", host->id,
+ dbg("RX CRC Error [%d + %d].\n", host->id,
host->pio.len, count);
break;
}
if (status & SD_STATUS_RO) {
- DBG("RX Overrun [%d + %d]\n", host->id,
+ dbg("RX Overrun [%d + %d]\n", host->id,
host->pio.len, count);
break;
}
else if (status & SD_STATUS_RU) {
- DBG("RX Underrun [%d + %d]\n", host->id,
+ dbg("RX Underrun [%d + %d]\n", host->id,
host->pio.len, count);
break;
}
@@ -829,7 +832,7 @@ #endif
au1xmmc_receive_pio(host);
}
else if (status & 0x203FBC70) {
- DBG("Unhandled status %8.8x\n", host->id, status);
+ dbg("Unhandled status %8.8x\n", host->id, status);
handled = 0;
}
@@ -856,10 +859,8 @@ static void au1xmmc_poll_event(unsigned
mmc_detect_change(host->mmc, 0);
}
- if (host->mrq != NULL) {
- u32 status = au_readl(HOST_STATUS(host));
- DBG("PENDING - %8.8x\n", host->id, status);
- }
+ if (host->mrq != NULL)
+ dbg("PENDING - %8.8x\n", host->id, au_readl(HOST_STATUS(host)));
mod_timer(&host->timer, jiffies + AU1XMMC_DETECT_TIMEOUT);
}
@@ -914,7 +915,7 @@ static int __devinit au1xmmc_probe(struc
ret = request_irq(AU1100_SD_IRQ, au1xmmc_irq, IRQF_DISABLED, "MMC", 0);
if (ret) {
- printk(DRIVER_NAME "ERROR: Couldn't get int %d: %d\n",
+ err("ERROR: Couldn't get int %d: %d\n",
AU1100_SD_IRQ, ret);
return -ENXIO;
}
@@ -926,7 +927,7 @@ static int __devinit au1xmmc_probe(struc
struct au1xmmc_host *host = 0;
if (!mmc) {
- printk(DRIVER_NAME "ERROR: no mem for host %d\n", i);
+ err("ERROR: no mem for host %d\n", i);
au1xmmc_hosts[i] = 0;
continue;
}
@@ -976,7 +977,7 @@ static int __devinit au1xmmc_probe(struc
add_timer(&host->timer);
- printk(KERN_INFO DRIVER_NAME ": MMC Controller %d set up at %8.8X (mode=%s)\n",
+ info("MMC Controller %d set up at %x (mode=%s)\n",
host->id, host->iobase, dma ? "dma" : "pio");
}
next reply other threads:[~2006-08-09 21:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-09 21:09 Rodolfo Giometti [this message]
2006-08-10 13:17 ` [PATCH] 3/7 AU1100 MMC support Sergei Shtylyov
2006-08-10 13:31 ` Rodolfo Giometti
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=20060809210927.GD13145@enneenne.com \
--to=giometti@linux.it \
--cc=linux-mips@linux-mips.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.