Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1554982

[RESEND RFC 1/3] mmc: sdhci: Add platform_dumpregs callback support to sdhci_ops.

From Ritesh Harjani <riteshh@codeaurora.org>
Newsgroups linux.kernel
Subject [RESEND RFC 1/3] mmc: sdhci: Add platform_dumpregs callback support to sdhci_ops.
Date 2017-01-10 07:50 +0100
Message-ID <sXYpP-6om-3@gated-at.bofh.it> (permalink)
References <sXYpP-6om-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Sahitya Tummala <stummala@codeaurora.org>

Add new host operation ->platform_dumpregs to provide a
mechanism through which host drivers can dump platform
specific registers in addition to SDHC registers
during error conditions.

Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
Signed-off-by: Ritesh Harjani <riteshh@codeaurora.org>
---
 drivers/mmc/host/sdhci.c | 3 +++
 drivers/mmc/host/sdhci.h | 1 +
 2 files changed, 4 insertions(+)

diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 2390980..73a8918 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -101,6 +101,9 @@ static void sdhci_dumpregs(struct sdhci_host *host)
 			       readl(host->ioaddr + SDHCI_ADMA_ADDRESS));
 	}
 
+	if (host->ops->platform_dumpregs)
+		host->ops->platform_dumpregs(host);
+
 	pr_err(DRIVER_NAME ": ===========================================\n");
 }
 
diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h
index 0b66f21..400f3a1 100644
--- a/drivers/mmc/host/sdhci.h
+++ b/drivers/mmc/host/sdhci.h
@@ -564,6 +564,7 @@ struct sdhci_ops {
 					 struct mmc_card *card,
 					 unsigned int max_dtr, int host_drv,
 					 int card_drv, int *drv_type);
+	void	(*platform_dumpregs)(struct sdhci_host *host);
 };
 
 #ifdef CONFIG_MMC_SDHCI_IO_ACCESSORS
-- 
The Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, 
a Linux Foundation Collaborative Project.

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[RESEND RFC 1/3] mmc: sdhci: Add platform_dumpregs callback support to sdhci_ops. Ritesh Harjani <riteshh@codeaurora.org> - 2017-01-10 07:50 +0100
  Re: [RESEND RFC 1/3] mmc: sdhci: Add platform_dumpregs callback  support to sdhci_ops. Shawn Lin <shawn.lin@rock-chips.com> - 2017-01-10 10:20 +0100

csiph-web