Re: [RFC 4/4] mmc: sdhci-msm: Handle unexpected interrupt case on enabling legacy IRQs on CQE halt

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 1:05 PM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: There is a case when enabling the legacy IRQs and halting CQE is resuling into a command response interrupt without any command in progress. This patch handles such case here. Error signature without

Re: [RFC 4/4] mmc: sdhci-msm: Handle unexpected interrupt case on enabling legacy IRQs on CQE halt

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 1:05 PM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: There is a case when enabling the legacy IRQs and halting CQE is resuling into a command response interrupt without any command in progress. This patch handles such case here. Error signature without

Re: [RFC 3/4] mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 12:12 PM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: When CMDQ is halted the HW expects descriptor size to be same which is using in CMDQ mode. Thus adjust the desc_sz of sdhci accordingly. Without this patch below command gives ADMA error when CQE is enabled

Re: [RFC 3/4] mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 12:12 PM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: When CMDQ is halted the HW expects descriptor size to be same which is using in CMDQ mode. Thus adjust the desc_sz of sdhci accordingly. Without this patch below command gives ADMA error when CQE is enabled

Re: [RFC 2/4] mmc: sdhci-msm: Add CQHCI support for sdhci-msm

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 12:55 PM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: This adds CQHCI support for sdhci-msm platforms. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- .../devicetree/bindings/mmc/sdhci-msm.txt | 1 + drivers/mmc/host/K

Re: [RFC 2/4] mmc: sdhci-msm: Add CQHCI support for sdhci-msm

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 12:55 PM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: This adds CQHCI support for sdhci-msm platforms. Signed-off-by: Ritesh Harjani --- .../devicetree/bindings/mmc/sdhci-msm.txt | 1 + drivers/mmc/host/Kconfig | 1

Re: [RFC 1/4] mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 11:31 AM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: Without this patch the CQHCI registers are getting reset again. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/cqhci.c | 7 +++ 1 file changed, 3 insertions

Re: [RFC 1/4] mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU

2017-09-01 Thread Ritesh Harjani
On 8/31/2017 11:31 AM, Adrian Hunter wrote: On 30/08/17 16:04, Ritesh Harjani wrote: Without this patch the CQHCI registers are getting reset again. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/cqhci.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git

[RFC 3/4] mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

2017-08-30 Thread Ritesh Harjani
When CMDQ is halted the HW expects descriptor size to be same which is using in CMDQ mode. Thus adjust the desc_sz of sdhci accordingly. Without this patch below command gives ADMA error when CQE is enabled. cat /sys/kernel/debug/mmc0/mmc0:0001/ext_csd Signed-off-by: Ritesh Harjani <r

[RFC 3/4] mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

2017-08-30 Thread Ritesh Harjani
When CMDQ is halted the HW expects descriptor size to be same which is using in CMDQ mode. Thus adjust the desc_sz of sdhci accordingly. Without this patch below command gives ADMA error when CQE is enabled. cat /sys/kernel/debug/mmc0/mmc0:0001/ext_csd Signed-off-by: Ritesh Harjani --- drivers

[RFC 4/4] mmc: sdhci-msm: Handle unexpected interrupt case on enabling legacy IRQs on CQE halt

2017-08-30 Thread Ritesh Harjani
was in progress. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci-msm.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c index baa3409..8fdc2c0 100644 --- a/drivers/mmc/host/sdhci-msm.c +++ b/d

[RFC 4/4] mmc: sdhci-msm: Handle unexpected interrupt case on enabling legacy IRQs on CQE halt

2017-08-30 Thread Ritesh Harjani
was in progress. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c index baa3409..8fdc2c0 100644 --- a/drivers/mmc/host/sdhci-msm.c +++ b/drivers/mmc/host/sdhci-msm.c

[RFC 2/4] mmc: sdhci-msm: Add CQHCI support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
This adds CQHCI support for sdhci-msm platforms. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- .../devicetree/bindings/mmc/sdhci-msm.txt | 1 + drivers/mmc/host/Kconfig | 1 + drivers/mmc/host/sdhci-msm.c

[RFC 2/4] mmc: sdhci-msm: Add CQHCI support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
This adds CQHCI support for sdhci-msm platforms. Signed-off-by: Ritesh Harjani --- .../devicetree/bindings/mmc/sdhci-msm.txt | 1 + drivers/mmc/host/Kconfig | 1 + drivers/mmc/host/sdhci-msm.c | 90 +- 3 files

[RFC 1/4] mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU

2017-08-30 Thread Ritesh Harjani
Without this patch the CQHCI registers are getting reset again. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/cqhci.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/mmc/host/cqhci.c b/drivers/mmc/host/cqhci.c index 8

[RFC 1/4] mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU

2017-08-30 Thread Ritesh Harjani
Without this patch the CQHCI registers are getting reset again. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/cqhci.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/mmc/host/cqhci.c b/drivers/mmc/host/cqhci.c index 8650a13..2a7351c 100644 --- a/drivers

[RFC 0/4] mmc: sdhci-msm: Add CQE support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
name=singlefile1 @Adrian, Thanks a lot for pursuing and bringing CMDQ patch series to it's final stages :) Ritesh Harjani (4): mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU mmc: sdhci-msm: Add CQHCI support for sdhci-msm mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

[RFC 0/4] mmc: sdhci-msm: Add CQE support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
name=singlefile1 @Adrian, Thanks a lot for pursuing and bringing CMDQ patch series to it's final stages :) Ritesh Harjani (4): mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU mmc: sdhci-msm: Add CQHCI support for sdhci-msm mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

[RFC 0/4] mmc: sdhci-msm: Add CQE support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani <rite...@codeaurora.org> Hi All, This is RFC patch series based on top of ulfh_mmc/cmdq branch which is based upon Adrian's CMDQ patch series. Below patch series enables CQE for sdhci-msm platform. This has been tested on internal 8996 MTP which has CMDQ support.

[RFC 0/4] mmc: sdhci-msm: Add CQE support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani Hi All, This is RFC patch series based on top of ulfh_mmc/cmdq branch which is based upon Adrian's CMDQ patch series. Below patch series enables CQE for sdhci-msm platform. This has been tested on internal 8996 MTP which has CMDQ support. Fixes w.r.t. CMDQ

[RFC 4/4] mmc: sdhci-msm: Handle unexpected interrupt case on enabling legacy IRQs on CQE halt

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani <rite...@codeaurora.org> There is a case when enabling the legacy IRQs and halting CQE is resuling into a command response interrupt without any command in progress. This patch handles such case here. Error signature without this patch:- mmc0: Got command int

[RFC 4/4] mmc: sdhci-msm: Handle unexpected interrupt case on enabling legacy IRQs on CQE halt

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani There is a case when enabling the legacy IRQs and halting CQE is resuling into a command response interrupt without any command in progress. This patch handles such case here. Error signature without this patch:- mmc0: Got command interrupt 0x0001 even though no command

[RFC 3/4] mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani <rite...@codeaurora.org> When CMDQ is halted the HW expects descriptor size to be same which is using in CMDQ mode. Thus adjust the desc_sz of sdhci accordingly. Without this patch below command gives ADMA error when CQE is enabled. cat /sys/kernel/debug/mmc0/mmc

[RFC 3/4] mmc: sdhci-msm: Change the desc_sz on cqe_enable/disable.

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani When CMDQ is halted the HW expects descriptor size to be same which is using in CMDQ mode. Thus adjust the desc_sz of sdhci accordingly. Without this patch below command gives ADMA error when CQE is enabled. cat /sys/kernel/debug/mmc0/mmc0:0001/ext_csd Signed-off

[RFC 2/4] mmc: sdhci-msm: Add CQHCI support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani <rite...@codeaurora.org> This adds CQHCI support for sdhci-msm platforms. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- .../devicetree/bindings/mmc/sdhci-msm.txt | 1 + drivers/mmc/host/Kconfig | 1 + drivers/mm

[RFC 1/4] mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani <rite...@codeaurora.org> Without this patch the CQHCI registers are getting reset again. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/cqhci.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/mmc/ho

[RFC 2/4] mmc: sdhci-msm: Add CQHCI support for sdhci-msm

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani This adds CQHCI support for sdhci-msm platforms. Signed-off-by: Ritesh Harjani --- .../devicetree/bindings/mmc/sdhci-msm.txt | 1 + drivers/mmc/host/Kconfig | 1 + drivers/mmc/host/sdhci-msm.c | 90

[RFC 1/4] mmc: cqhci: Move CQHCI_ENABLE before setting TDLBA/TDLBAU

2017-08-30 Thread Ritesh Harjani
From: Ritesh Harjani Without this patch the CQHCI registers are getting reset again. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/cqhci.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/mmc/host/cqhci.c b/drivers/mmc/host/cqhci.c index 8650a13..2a7351c

Re: [RFC PATCH] cfq: Give a chance for arming slice idle timer in case of group_idle

2017-08-11 Thread Ritesh Harjani
On 8/11/2017 8:30 PM, Jens Axboe wrote: On 08/10/2017 11:15 PM, Ritesh Harjani wrote: Hi Jens, Could you please take a look at below patch and the issue it is trying to solve. Please let us know your thoughts on the below problem and the patch. It looks reasonable to me. I'll queue it up

Re: [RFC PATCH] cfq: Give a chance for arming slice idle timer in case of group_idle

2017-08-11 Thread Ritesh Harjani
On 8/11/2017 8:30 PM, Jens Axboe wrote: On 08/10/2017 11:15 PM, Ritesh Harjani wrote: Hi Jens, Could you please take a look at below patch and the issue it is trying to solve. Please let us know your thoughts on the below problem and the patch. It looks reasonable to me. I'll queue it up

Re: [RFC PATCH] cfq: Give a chance for arming slice idle timer in case of group_idle

2017-08-10 Thread Ritesh Harjani
Hi Jens, Could you please take a look at below patch and the issue it is trying to solve. Please let us know your thoughts on the below problem and the patch. Regards Ritesh On 8/9/2017 6:28 PM, Ritesh Harjani wrote: In below scenario blkio cgroup does not work as per their assigned

Re: [RFC PATCH] cfq: Give a chance for arming slice idle timer in case of group_idle

2017-08-10 Thread Ritesh Harjani
Hi Jens, Could you please take a look at below patch and the issue it is trying to solve. Please let us know your thoughts on the below problem and the patch. Regards Ritesh On 8/9/2017 6:28 PM, Ritesh Harjani wrote: In below scenario blkio cgroup does not work as per their assigned

[RFC PATCH] cfq: Give a chance for arming slice idle timer in case of group_idle

2017-08-09 Thread Ritesh Harjani
pid=691: Thu Jan 1 00:06:08 1970 write: IOPS=1043, BW=32.6MiB/s (34.2MB/s)(1024MiB/31401msec) <..> // In this processes BW is as per their respective cgroups weight. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- block/cfq-iosched.c | 3 ++- 1 file changed, 2 insertions(

[RFC PATCH] cfq: Give a chance for arming slice idle timer in case of group_idle

2017-08-09 Thread Ritesh Harjani
pid=691: Thu Jan 1 00:06:08 1970 write: IOPS=1043, BW=32.6MiB/s (34.2MB/s)(1024MiB/31401msec) <..> // In this processes BW is as per their respective cgroups weight. Signed-off-by: Ritesh Harjani --- block/cfq-iosched.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --gi

Re: [RFC PATCH 0/2] mmc: sdhci: Add SDHCI_QUIRK2_BROKEN_SDMA_BOUNDARY_BUFFER

2017-06-28 Thread Ritesh Harjani
Hi Srinivas, On 6/28/2017 7:05 PM, srinivas.kandaga...@linaro.org wrote: From: Srinivas Kandagatla This patchset adds quirk to support cards which have issues when sdma boundary buffer bits are programmed in Block Size Register (0x04) when using ADMA. Thanks

Re: [RFC PATCH 0/2] mmc: sdhci: Add SDHCI_QUIRK2_BROKEN_SDMA_BOUNDARY_BUFFER

2017-06-28 Thread Ritesh Harjani
Hi Srinivas, On 6/28/2017 7:05 PM, srinivas.kandaga...@linaro.org wrote: From: Srinivas Kandagatla This patchset adds quirk to support cards which have issues when sdma boundary buffer bits are programmed in Block Size Register (0x04) when using ADMA. Thanks for pointing out the reason of

Re: [RFC PATCH 0/4] mmc: core: Provide CMD5 awake and partial_init support

2017-02-20 Thread Ritesh Harjani
Hi Ulf, On 2/20/2017 5:09 PM, Ulf Hansson wrote: On 20 February 2017 at 09:03, Ritesh Harjani <rite...@codeaurora.org> wrote: As per JEDEC spec - CMD5 can be used to awake from sleep mode for emmc. This patch series provide CMD5(awake) + mmc_partial_init support to resume mmc card

Re: [RFC PATCH 0/4] mmc: core: Provide CMD5 awake and partial_init support

2017-02-20 Thread Ritesh Harjani
Hi Ulf, On 2/20/2017 5:09 PM, Ulf Hansson wrote: On 20 February 2017 at 09:03, Ritesh Harjani wrote: As per JEDEC spec - CMD5 can be used to awake from sleep mode for emmc. This patch series provide CMD5(awake) + mmc_partial_init support to resume mmc card device. This is mainly to reduce

[RFC PATCH 4/4] mmc: core: Implement mmc_partial_init during resume

2017-02-20 Thread Ritesh Harjani
ez <me...@codeaurora.org> Signed-off-by: Asutosh Das <asuto...@codeaurora.org> Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/core/core.c | 13 + drivers/mmc/core/core.h | 1 + drivers/mmc/core/mmc.c | 134 ++

[RFC PATCH 4/4] mmc: core: Implement mmc_partial_init during resume

2017-02-20 Thread Ritesh Harjani
Signed-off-by: Ritesh Harjani --- drivers/mmc/core/core.c | 13 + drivers/mmc/core/core.h | 1 + drivers/mmc/core/mmc.c | 134 ++- include/linux/mmc/card.h | 3 ++ include/linux/mmc/host.h | 1 + 5 files changed, 150 insertions(+), 2

[RFC PATCH 2/4] mmc: core: add mmc-sleep-awake caps

2017-02-20 Thread Ritesh Harjani
This patch introduce mmc-sleep-awake for platforms which want to enable CMD5 awake & partial_init. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/core/host.c | 2 ++ include/linux/mmc/host.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/mmc/cor

[RFC PATCH 2/4] mmc: core: add mmc-sleep-awake caps

2017-02-20 Thread Ritesh Harjani
This patch introduce mmc-sleep-awake for platforms which want to enable CMD5 awake & partial_init. Signed-off-by: Ritesh Harjani --- drivers/mmc/core/host.c | 2 ++ include/linux/mmc/host.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/mmc/core/host.c b/drivers/mmc/core/ho

[RFC PATCH 0/4] mmc: core: Provide CMD5 awake and partial_init support

2017-02-20 Thread Ritesh Harjani
internal board. This patch reduced the resume time by ~50% on msm8996 and ~11% on db410c. As of now this patch series provides a caps (MMC_CAP2_SLEEP_AWAKE) to enable this feature. Since there is no dependency on host platform for this, we can enable this feature by default as well. Thoughts? Ritesh

[RFC PATCH 0/4] mmc: core: Provide CMD5 awake and partial_init support

2017-02-20 Thread Ritesh Harjani
internal board. This patch reduced the resume time by ~50% on msm8996 and ~11% on db410c. As of now this patch series provides a caps (MMC_CAP2_SLEEP_AWAKE) to enable this feature. Since there is no dependency on host platform for this, we can enable this feature by default as well. Thoughts? Ritesh

[RFC PATCH 3/4] mmc: mmc: add support for CMD5 awake

2017-02-20 Thread Ritesh Harjani
This patch adds CMD5 awake support for emmc. This will be used to awake emmc from suspend together with partial_init support to reduce resume latencies. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/core/mmc.c | 26 +- 1 file chang

[RFC PATCH 1/4] Documentation: mmc: add mmc-sleep-awake

2017-02-20 Thread Ritesh Harjani
mmc-sleep-awake enables CMD5 awake feature & partial_init which can help reduce resume latency on emmc. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- Documentation/devicetree/bindings/mmc/mmc.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetre

[RFC PATCH 3/4] mmc: mmc: add support for CMD5 awake

2017-02-20 Thread Ritesh Harjani
This patch adds CMD5 awake support for emmc. This will be used to awake emmc from suspend together with partial_init support to reduce resume latencies. Signed-off-by: Ritesh Harjani --- drivers/mmc/core/mmc.c | 26 +- 1 file changed, 21 insertions(+), 5 deletions

[RFC PATCH 1/4] Documentation: mmc: add mmc-sleep-awake

2017-02-20 Thread Ritesh Harjani
mmc-sleep-awake enables CMD5 awake feature & partial_init which can help reduce resume latency on emmc. Signed-off-by: Ritesh Harjani --- Documentation/devicetree/bindings/mmc/mmc.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/mmc/mmc.tx

Re: [RESEND PATCHv1 5/8] mmc: sdhci-msm: configure CORE_CSR_CDC_DELAY_CFG to recommended value

2017-01-24 Thread Ritesh Harjani
Hi Stephen, On 1/20/2017 11:12 PM, Stephen Boyd wrote: On 01/09/2017 11:00 PM, Ritesh Harjani wrote: From: Subhash Jadavani <subha...@codeaurora.org> Program CORE_CSR_CDC_DELAY_CFG for hardware recommended 1.25ns delay. We may see data CRC errors if it's programmed for any other delay

Re: [RESEND PATCHv1 5/8] mmc: sdhci-msm: configure CORE_CSR_CDC_DELAY_CFG to recommended value

2017-01-24 Thread Ritesh Harjani
Hi Stephen, On 1/20/2017 11:12 PM, Stephen Boyd wrote: On 01/09/2017 11:00 PM, Ritesh Harjani wrote: From: Subhash Jadavani Program CORE_CSR_CDC_DELAY_CFG for hardware recommended 1.25ns delay. We may see data CRC errors if it's programmed for any other delay value. Signed-off-by: Subhash

[PATCHv1 2/2] mmc: sdhci-msm: Remove unnecessary comments of CDC init sequence

2017-01-24 Thread Ritesh Harjani
This removes CDC init sequence comments which are not useful anyway. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci-msm.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host

[PATCHv1 1/2] mmc: sdhci-msm: Remove platform_execute_tuning from sdhci_msm_ops

2017-01-24 Thread Ritesh Harjani
platform_execute_tuning should not really exist as it does not do anything useful. So remove this ops and directly plug sdhci_msm_execute_tuning with mmc_host_ops. Also in case of HS400 tuning clear SDHCI_HS400_TUNING flag once HS400 related mode selection is done. Signed-off-by: Ritesh Harjani

[PATCHv1 2/2] mmc: sdhci-msm: Remove unnecessary comments of CDC init sequence

2017-01-24 Thread Ritesh Harjani
This removes CDC init sequence comments which are not useful anyway. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c index b3e8f44

[PATCHv1 1/2] mmc: sdhci-msm: Remove platform_execute_tuning from sdhci_msm_ops

2017-01-24 Thread Ritesh Harjani
platform_execute_tuning should not really exist as it does not do anything useful. So remove this ops and directly plug sdhci_msm_execute_tuning with mmc_host_ops. Also in case of HS400 tuning clear SDHCI_HS400_TUNING flag once HS400 related mode selection is done. Signed-off-by: Ritesh Harjani

[PATCHv1 0/2] mmc: sdhci-msm: Addresses minor cleanups

2017-01-24 Thread Ritesh Harjani
://lkml.org/lkml/2017/1/10/70 [2]:- https://lkml.org/lkml/2017/1/19/153 [3]:- https://lkml.org/lkml/2017/1/20/542 Ritesh Harjani (2): mmc: sdhci-msm: Remove platform_execute_tuning from sdhci_msm_ops mmc: sdhci-msm: Remove unnecessary comments of CDC init sequence drivers/mmc/host/sdhci-msm.c | 21

[PATCHv1 0/2] mmc: sdhci-msm: Addresses minor cleanups

2017-01-24 Thread Ritesh Harjani
://lkml.org/lkml/2017/1/10/70 [2]:- https://lkml.org/lkml/2017/1/19/153 [3]:- https://lkml.org/lkml/2017/1/20/542 Ritesh Harjani (2): mmc: sdhci-msm: Remove platform_execute_tuning from sdhci_msm_ops mmc: sdhci-msm: Remove unnecessary comments of CDC init sequence drivers/mmc/host/sdhci-msm.c | 21

Re: [RESEND RFC 3/3] mmc: sdhci: Add more debug info in case of data error

2017-01-19 Thread Ritesh Harjani
Hi Adrian, Thanks for reviewing. On 1/19/2017 5:24 PM, Adrian Hunter wrote: On 10/01/17 08:41, Ritesh Harjani wrote: print error log message and dump sdhc registers for debugging purpose in case of data errors (except when tuning commands generate CRC/timeout/end bit errors). It is a bit

Re: [RESEND RFC 3/3] mmc: sdhci: Add more debug info in case of data error

2017-01-19 Thread Ritesh Harjani
Hi Adrian, Thanks for reviewing. On 1/19/2017 5:24 PM, Adrian Hunter wrote: On 10/01/17 08:41, Ritesh Harjani wrote: print error log message and dump sdhc registers for debugging purpose in case of data errors (except when tuning commands generate CRC/timeout/end bit errors). It is a bit

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

2017-01-19 Thread Ritesh Harjani
On 1/19/2017 4:13 PM, Adrian Hunter wrote: On 18/01/17 09:57, Ritesh Harjani wrote: Hi Shawn, On 1/10/2017 2:45 PM, Shawn Lin wrote: On 2017/1/10 14:41, Ritesh Harjani wrote: From: Sahitya Tummala <stumm...@codeaurora.org> Add new host operation ->platform_dumpregs to provide a

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

2017-01-19 Thread Ritesh Harjani
On 1/19/2017 4:13 PM, Adrian Hunter wrote: On 18/01/17 09:57, Ritesh Harjani wrote: Hi Shawn, On 1/10/2017 2:45 PM, Shawn Lin wrote: On 2017/1/10 14:41, Ritesh Harjani wrote: From: Sahitya Tummala Add new host operation ->platform_dumpregs to provide a mechanism through which host driv

Re: [RESEND RFC 2/3] mmc: sdhci-msm: Implement platform_dumpregs callback in sdhci-msm

2017-01-19 Thread Ritesh Harjani
Hi Adrian, On 1/19/2017 4:25 PM, Adrian Hunter wrote: On 10/01/17 08:41, Ritesh Harjani wrote: From: Sahitya Tummala <stumm...@codeaurora.org> Implement ->platform_dumpregs host operation to print the platform specific registers in addition to standard SDHC register during error c

Re: [RESEND RFC 2/3] mmc: sdhci-msm: Implement platform_dumpregs callback in sdhci-msm

2017-01-19 Thread Ritesh Harjani
Hi Adrian, On 1/19/2017 4:25 PM, Adrian Hunter wrote: On 10/01/17 08:41, Ritesh Harjani wrote: From: Sahitya Tummala Implement ->platform_dumpregs host operation to print the platform specific registers in addition to standard SDHC register during error conditions. You could add an exam

Re: [RESEND PATCHv1 0/8] mmc: sdhci-msm: Provide support for enhanced strobe

2017-01-19 Thread Ritesh Harjani
On 1/20/2017 2:23 AM, Ulf Hansson wrote: On 10 January 2017 at 08:00, Ritesh Harjani <rite...@codeaurora.org> wrote: Hi, Resending this patch series, as no one could review it -possibly due to holidays during that time. This patch series mainly provides enhanced strobe support to sdh

Re: [RESEND PATCHv1 0/8] mmc: sdhci-msm: Provide support for enhanced strobe

2017-01-19 Thread Ritesh Harjani
On 1/20/2017 2:23 AM, Ulf Hansson wrote: On 10 January 2017 at 08:00, Ritesh Harjani wrote: Hi, Resending this patch series, as no one could review it -possibly due to holidays during that time. This patch series mainly provides enhanced strobe support to sdhci-msm driver along with some

Re: [RESEND PATCHv1 6/8] mmc: sdhci: Clear SDHCI_HS400_TUNING flag after platform_execute_tuning

2017-01-19 Thread Ritesh Harjani
Hi Adrian, Thanks for reviewing. On 1/19/2017 3:40 PM, Adrian Hunter wrote: On 10/01/17 09:00, Ritesh Harjani wrote: Clear SDHCI_HS400_TUNING flag after platform_execute_tuning so that platform_execute_tuning may use it if needed. Sorry for the slow reply. platform_execute_tuning() should

Re: [RESEND PATCHv1 6/8] mmc: sdhci: Clear SDHCI_HS400_TUNING flag after platform_execute_tuning

2017-01-19 Thread Ritesh Harjani
Hi Adrian, Thanks for reviewing. On 1/19/2017 3:40 PM, Adrian Hunter wrote: On 10/01/17 09:00, Ritesh Harjani wrote: Clear SDHCI_HS400_TUNING flag after platform_execute_tuning so that platform_execute_tuning may use it if needed. Sorry for the slow reply. platform_execute_tuning() should

Re: [PATCH v2] mmc: sdhci-msm: Add sdhci_reset() implementation

2017-01-18 Thread Ritesh Harjani
this issue. # [5.854979] mmc0: mmc_runtime_suspend [5.854982] mmc1: mmc_runtime_suspend [5.957925] mmc1: Reset 0x1 never completed. [6.071244] mmc0: Reset 0x1 never completed. Regards Ritesh On 1/18/2017 2:46 PM, Ritesh Harjani wrote: Hi Georgi, Sorry for delaying this. I did

Re: [PATCH v2] mmc: sdhci-msm: Add sdhci_reset() implementation

2017-01-18 Thread Ritesh Harjani
this issue. # [5.854979] mmc0: mmc_runtime_suspend [5.854982] mmc1: mmc_runtime_suspend [5.957925] mmc1: Reset 0x1 never completed. [6.071244] mmc0: Reset 0x1 never completed. Regards Ritesh On 1/18/2017 2:46 PM, Ritesh Harjani wrote: Hi Georgi, Sorry for delaying this. I did

Re: [PATCH v2] mmc: sdhci-msm: Add sdhci_reset() implementation

2017-01-18 Thread Ritesh Harjani
this patch should be fine to avoid the error message on reboot. On 12/3/2016 2:24 PM, Ritesh Harjani wrote: On 12/1/2016 11:38 PM, Georgi Djakov wrote: On 11/29/2016 05:40 AM, Ritesh Harjani wrote: Hi Georgi, On 11/28/2016 11:09 PM, Georgi Djakov wrote: On apq8016, apq8084 and apq8074

Re: [PATCH v2] mmc: sdhci-msm: Add sdhci_reset() implementation

2017-01-18 Thread Ritesh Harjani
this patch should be fine to avoid the error message on reboot. On 12/3/2016 2:24 PM, Ritesh Harjani wrote: On 12/1/2016 11:38 PM, Georgi Djakov wrote: On 11/29/2016 05:40 AM, Ritesh Harjani wrote: Hi Georgi, On 11/28/2016 11:09 PM, Georgi Djakov wrote: On apq8016, apq8084 and apq8074

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

2017-01-17 Thread Ritesh Harjani
Hi Shawn, On 1/10/2017 2:45 PM, Shawn Lin wrote: On 2017/1/10 14:41, Ritesh Harjani wrote: From: Sahitya Tummala <stumm...@codeaurora.org> Add new host operation ->platform_dumpregs to provide a mechanism through which host drivers can dump platform specific registers in additio

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

2017-01-17 Thread Ritesh Harjani
Hi Shawn, On 1/10/2017 2:45 PM, Shawn Lin wrote: On 2017/1/10 14:41, Ritesh Harjani wrote: From: Sahitya Tummala 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 er

Re: [RESEND PATCHv1 0/8] mmc: sdhci-msm: Provide support for enhanced strobe

2017-01-17 Thread Ritesh Harjani
On 1/17/2017 6:37 AM, Jeremy McNicoll wrote: On Tue, Jan 10, 2017 at 12:30:44PM +0530, Ritesh Harjani wrote: Hi, Resending this patch series, as no one could review it -possibly due to holidays during that time. This patch series mainly provides enhanced strobe support to sdhci-msm driver

Re: [RESEND PATCHv1 0/8] mmc: sdhci-msm: Provide support for enhanced strobe

2017-01-17 Thread Ritesh Harjani
On 1/17/2017 6:37 AM, Jeremy McNicoll wrote: On Tue, Jan 10, 2017 at 12:30:44PM +0530, Ritesh Harjani wrote: Hi, Resending this patch series, as no one could review it -possibly due to holidays during that time. This patch series mainly provides enhanced strobe support to sdhci-msm driver

Re: [RFC PATCH 2/3] mmc: sdhci-msm: Implement platform_dumpregs callback in sdhci-msm

2017-01-15 Thread Ritesh Harjani
Hi Jeremy, On 1/14/2017 4:01 AM, Jeremy McNicoll wrote: On Fri, Dec 30, 2016 at 05:02:10PM +0530, Ritesh Harjani wrote: From: Sahitya Tummala <stumm...@codeaurora.org> Implement ->platform_dumpregs host operation to print the platform specific registers in addition to standard SDHC

Re: [RFC PATCH 2/3] mmc: sdhci-msm: Implement platform_dumpregs callback in sdhci-msm

2017-01-15 Thread Ritesh Harjani
Hi Jeremy, On 1/14/2017 4:01 AM, Jeremy McNicoll wrote: On Fri, Dec 30, 2016 at 05:02:10PM +0530, Ritesh Harjani wrote: From: Sahitya Tummala Implement ->platform_dumpregs host operation to print the platform specific registers in addition to standard SDHC register during error conditi

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

2017-01-15 Thread Ritesh Harjani
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 <stumm...@codeaurora.org> Add new host operation ->platform_dumpregs to provide a mechanism through which host drivers

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

2017-01-15 Thread Ritesh Harjani
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 Add new host operation ->platform_dumpregs to provide a mechanism through which host drivers can dump platform speci

[RESEND PATCHv1 7/8] mmc: sdhci-msm: Make HS400 tuning follow as per recommeneded HW sequence

2017-01-09 Thread Ritesh Harjani
During tuning execution for HS400 mode, HW sequence recommends to select MCLK_SEL/2(0x3) in VENDOR_SPEC & sdhc msm clock at GCC to be 400MHZ (nearest supported clk). Add this change in tuning sequence during HS400 tuning. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- d

[RESEND PATCHv1 6/8] mmc: sdhci: Clear SDHCI_HS400_TUNING flag after platform_execute_tuning

2017-01-09 Thread Ritesh Harjani
Clear SDHCI_HS400_TUNING flag after platform_execute_tuning so that platform_execute_tuning may use it if needed. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/host/s

[RESEND PATCHv1 8/8] mmc: sdhci-msm: Provide enhanced_strobe mode feature support

2017-01-09 Thread Ritesh Harjani
This provides enhanced_strobe mode feature support in sdhci-msm driver. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci-msm.c | 34 +- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/drivers/mmc/host/sdhci-m

[RESEND PATCHv1 7/8] mmc: sdhci-msm: Make HS400 tuning follow as per recommeneded HW sequence

2017-01-09 Thread Ritesh Harjani
During tuning execution for HS400 mode, HW sequence recommends to select MCLK_SEL/2(0x3) in VENDOR_SPEC & sdhc msm clock at GCC to be 400MHZ (nearest supported clk). Add this change in tuning sequence during HS400 tuning. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c

[RESEND PATCHv1 6/8] mmc: sdhci: Clear SDHCI_HS400_TUNING flag after platform_execute_tuning

2017-01-09 Thread Ritesh Harjani
Clear SDHCI_HS400_TUNING flag after platform_execute_tuning so that platform_execute_tuning may use it if needed. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host

[RESEND PATCHv1 8/8] mmc: sdhci-msm: Provide enhanced_strobe mode feature support

2017-01-09 Thread Ritesh Harjani
This provides enhanced_strobe mode feature support in sdhci-msm driver. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 34 +- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci

[RESEND PATCHv1 5/8] mmc: sdhci-msm: configure CORE_CSR_CDC_DELAY_CFG to recommended value

2017-01-09 Thread Ritesh Harjani
From: Subhash Jadavani <subha...@codeaurora.org> Program CORE_CSR_CDC_DELAY_CFG for hardware recommended 1.25ns delay. We may see data CRC errors if it's programmed for any other delay value. Signed-off-by: Subhash Jadavani <subha...@codeaurora.org> Signed-off-by: Ritesh H

[RESEND PATCHv1 5/8] mmc: sdhci-msm: configure CORE_CSR_CDC_DELAY_CFG to recommended value

2017-01-09 Thread Ritesh Harjani
From: Subhash Jadavani Program CORE_CSR_CDC_DELAY_CFG for hardware recommended 1.25ns delay. We may see data CRC errors if it's programmed for any other delay value. Signed-off-by: Subhash Jadavani Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 2 +- 1 file changed, 1

[RESEND PATCHv1 3/8] mmc: sdhci-msm: Factor out sdhci_msm_hs400

2017-01-09 Thread Ritesh Harjani
Factor out sdhci_msm_hs400 used for DLL calibration in HS400 modes. This function will be needed for enhanced_strobe as well. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci-msm.c | 32 ++-- 1 file changed, 26 insertions

[RESEND PATCHv1 0/8] mmc: sdhci-msm: Provide support for enhanced strobe

2017-01-09 Thread Ritesh Harjani
so that ->platform_execute_tuning (underlying platform driver) can know about HS400 tuning. Patch 7 :- Implements an additional step as per HPG for HS400 tuning. Patch 8 :- Implements enhanced strobe functionality in sdhci-msm driver. Ritesh Harjani (6): mmc: sdhci-msm: Fac

[RESEND PATCHv1 3/8] mmc: sdhci-msm: Factor out sdhci_msm_hs400

2017-01-09 Thread Ritesh Harjani
Factor out sdhci_msm_hs400 used for DLL calibration in HS400 modes. This function will be needed for enhanced_strobe as well. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 32 ++-- 1 file changed, 26 insertions(+), 6 deletions(-) diff --git

[RESEND PATCHv1 0/8] mmc: sdhci-msm: Provide support for enhanced strobe

2017-01-09 Thread Ritesh Harjani
so that ->platform_execute_tuning (underlying platform driver) can know about HS400 tuning. Patch 7 :- Implements an additional step as per HPG for HS400 tuning. Patch 8 :- Implements enhanced strobe functionality in sdhci-msm driver. Ritesh Harjani (6): mmc: sdhci-msm: Fac

[RESEND PATCHv1 4/8] mmc: sdhci-msm: Reset vendor specific func register on probe

2017-01-09 Thread Ritesh Harjani
ed-off-by: Venkat Gopalakrishnan <venk...@codeaurora.org> Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci-msm.c | 15 --- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c inde

[RESEND PATCHv1 2/8] mmc: sdhci-msm: Factor out function to set/get msm clock rate

2017-01-09 Thread Ritesh Harjani
Factor out msm_set/get_clock_rate_for_bus_mode for it's later use in changing the tuning sequence for selecting HS400 bus speed mode. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci-msm.c | 64 +++- 1 file chang

[RESEND PATCHv1 1/8] mmc: sdhci-msm: Factor out sdhci_msm_hc_select_mode

2017-01-09 Thread Ritesh Harjani
This factors out sdhci_msm_hc_select_mode to later use it during enhanced_strobe mode select. It also further breaks sdhci_msm_hc_select_mode into separate functions for configuring HS400 mode or other modes. Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> --- drivers/mmc/host/sdhci

[RESEND PATCHv1 4/8] mmc: sdhci-msm: Reset vendor specific func register on probe

2017-01-09 Thread Ritesh Harjani
Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 15 --- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c index 5a37c29..a028568 100644 --- a/drivers/mmc/host/sdhci-msm.c +++ b/drivers/mmc/host/sdhci

[RESEND PATCHv1 2/8] mmc: sdhci-msm: Factor out function to set/get msm clock rate

2017-01-09 Thread Ritesh Harjani
Factor out msm_set/get_clock_rate_for_bus_mode for it's later use in changing the tuning sequence for selecting HS400 bus speed mode. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 64 +++- 1 file changed, 40 insertions(+), 24 deletions

[RESEND PATCHv1 1/8] mmc: sdhci-msm: Factor out sdhci_msm_hc_select_mode

2017-01-09 Thread Ritesh Harjani
This factors out sdhci_msm_hc_select_mode to later use it during enhanced_strobe mode select. It also further breaks sdhci_msm_hc_select_mode into separate functions for configuring HS400 mode or other modes. Signed-off-by: Ritesh Harjani --- drivers/mmc/host/sdhci-msm.c | 201

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

2017-01-09 Thread Ritesh Harjani
.org> Signed-off-by: Ritesh Harjani <rite...@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/sdhc

[RESEND RFC 3/3] mmc: sdhci: Add more debug info in case of data error

2017-01-09 Thread Ritesh Harjani
print error log message and dump sdhc registers for debugging purpose in case of data errors (except when tuning commands generate CRC/timeout/end bit errors). Signed-off-by: Ritesh Harjani <rite...@codeaurora.org> Signed-off-by: Asutosh Das <asuto...@codeaurora.org> --- drivers/mmc/

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

2017-01-09 Thread Ritesh Harjani
From: Sahitya Tummala 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 Signed-off-by: Ritesh Harjani --- drivers/mmc/h

[RESEND RFC 3/3] mmc: sdhci: Add more debug info in case of data error

2017-01-09 Thread Ritesh Harjani
print error log message and dump sdhc registers for debugging purpose in case of data errors (except when tuning commands generate CRC/timeout/end bit errors). Signed-off-by: Ritesh Harjani Signed-off-by: Asutosh Das --- drivers/mmc/host/sdhci.c | 21 +++-- 1 file changed, 19

<    1   2   3   >