Skip to content

Commit

Permalink
mmc: sdhci: print SD Command and CAPABILITY_1 when dumping registers
Browse files Browse the repository at this point in the history
More information should be shown when sdhci_dumpregs is called.
Knowing the command is useful for debugging, and Capability 1
is useful for SD v3.

Signed-off-by: Philip Rakity <prakity@marvell.com>
Reviewed-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Chris Ball <cjb@laptop.org>
  • Loading branch information
Philip Rakity authored and Chris Ball committed Jan 9, 2011
1 parent 0456683 commit e8120ad
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion drivers/mmc/host/sdhci.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,11 @@ static void sdhci_dumpregs(struct sdhci_host *host)
printk(KERN_DEBUG DRIVER_NAME ": AC12 err: 0x%08x | Slot int: 0x%08x\n",
sdhci_readw(host, SDHCI_ACMD12_ERR),
sdhci_readw(host, SDHCI_SLOT_INT_STATUS));
printk(KERN_DEBUG DRIVER_NAME ": Caps: 0x%08x | Max curr: 0x%08x\n",
printk(KERN_DEBUG DRIVER_NAME ": Caps: 0x%08x | Caps_1: 0x%08x\n",
sdhci_readl(host, SDHCI_CAPABILITIES),
sdhci_readl(host, SDHCI_CAPABILITIES_1));
printk(KERN_DEBUG DRIVER_NAME ": Cmd: 0x%08x | Max curr: 0x%08x\n",
sdhci_readw(host, SDHCI_COMMAND),
sdhci_readl(host, SDHCI_MAX_CURRENT));

if (host->flags & SDHCI_USE_ADMA)
Expand Down
2 changes: 1 addition & 1 deletion drivers/mmc/host/sdhci.h
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@
#define SDHCI_CAN_VDD_180 0x04000000
#define SDHCI_CAN_64BIT 0x10000000

/* 44-47 reserved for more caps */
#define SDHCI_CAPABILITIES_1 0x44

#define SDHCI_MAX_CURRENT 0x48

Expand Down

0 comments on commit e8120ad

Please sign in to comment.