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


Groups > linux.kernel > #1558776 > unrolled thread

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

Started byJeremy McNicoll <jmcnicol@redhat.com>
First post2017-01-13 23:30 +0100
Last post2017-01-16 06:30 +0100
Articles 3 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [RFC PATCH 1/3] mmc: sdhci: Add platform_dumpregs callback  support to sdhci_ops. Jeremy McNicoll <jmcnicol@redhat.com> - 2017-01-13 23:30 +0100
    Re: [RFC PATCH 1/3] mmc: sdhci: Add platform_dumpregs callback  support to sdhci_ops. Ritesh Harjani <riteshh@codeaurora.org> - 2017-01-16 03:20 +0100
      Re: [RFC PATCH 1/3] mmc: sdhci: Add platform_dumpregs callback  support to sdhci_ops. Jeremy McNicoll <jmcnicol@redhat.com> - 2017-01-16 06:30 +0100

#1558776 — Re: [RFC PATCH 1/3] mmc: sdhci: Add platform_dumpregs callback support to sdhci_ops.

FromJeremy McNicoll <jmcnicol@redhat.com>
Date2017-01-13 23:30 +0100
SubjectRe: [RFC PATCH 1/3] mmc: sdhci: Add platform_dumpregs callback support to sdhci_ops.
Message-ID<sZiwa-6rO-11@gated-at.bofh.it>
On Fri, Dec 30, 2016 at 05:02:09PM +0530, Ritesh Harjani wrote:
> 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(+)
>

This change and 2/3 look like they can be squished together into
one patch.  At least that is how I did it, 

https://patchwork.kernel.org/patch/9442449/

-jeremy


> 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.
> 

[toc] | [next] | [standalone]


#1559396

FromRitesh Harjani <riteshh@codeaurora.org>
Date2017-01-16 03:20 +0100
Message-ID<t053Q-26B-7@gated-at.bofh.it>
In reply to#1558776
Hi Jeremy,

Thanks for the review.

On 1/14/2017 3:51 AM, Jeremy McNicoll wrote:
> On Fri, Dec 30, 2016 at 05:02:09PM +0530, Ritesh Harjani wrote:
>> 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(+)
>>
>
> This change and 2/3 look like they can be squished together into
> one patch.  At least that is how I did it,

I felt it is better this way to keep sdhci and sdhci-msm patches 
separate. This patch provides mechanism and patch 3/3 provides
implementation of ->platform_dumpregs in sdhci-msm.

Regards
Ritesh


>
> https://patchwork.kernel.org/patch/9442449/
>
> -jeremy
>
>
>> 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.
>>

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

[toc] | [prev] | [next] | [standalone]


#1559451

FromJeremy McNicoll <jmcnicol@redhat.com>
Date2017-01-16 06:30 +0100
Message-ID<t081H-49t-1@gated-at.bofh.it>
In reply to#1559396
On Mon, Jan 16, 2017 at 07:45:48AM +0530, Ritesh Harjani wrote:
> Hi Jeremy,
> 
> Thanks for the review.
> 
> On 1/14/2017 3:51 AM, Jeremy McNicoll wrote:
> >On Fri, Dec 30, 2016 at 05:02:09PM +0530, Ritesh Harjani wrote:
> >>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(+)
> >>
> >
> >This change and 2/3 look like they can be squished together into
> >one patch.  At least that is how I did it,
> 
> I felt it is better this way to keep sdhci and sdhci-msm patches separate.
> This patch provides mechanism and patch 3/3 provides
> implementation of ->platform_dumpregs in sdhci-msm.
>

Alright, lets go with that approach.  

-jeremy

> Regards
> Ritesh
> 
> 
> >
> >https://patchwork.kernel.org/patch/9442449/
> >
> >-jeremy
> >
> >
> >>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.
> >>
> 
> -- 
> Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
> a Linux Foundation Collaborative Project

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web