[PATCH v4] mmc: dw_mmc: force setup bus if active slots exist

2017-01-04 Thread Ziyuan Xu
ock during communication. fixes: e9ed8835e990 ("mmc: dw_mmc: add runtime PM callback") Reported-by: Randy Li Signed-off-by: Ziyuan Xu --- Hi guys, I found a similar issue on rk3399 platform, which has a genpd node for SD card host. Power off-on pd will reset the registers to a default value (

[PATCH v3] mmc: dw_mmc: revise the reset path in runtime resume

2017-01-04 Thread Ziyuan Xu
("mmc: dw_mmc: add runtime PM callback"). MMC_PM_KEEP_POWEP is disabled for SD card and eMMC slots, so that they have no chance to invoke dw_mci_setup_bus for update clock behaviour. Let's consummate it. Reported-by: Randy Li Signed-off-by: Ziyuan Xu --- Changes in v3: - only reset h

[RESEND PATCH v3] mmc: dw_mmc: revise the reset path in runtime resume

2017-01-04 Thread Ziyuan Xu
("mmc: dw_mmc: add runtime PM callback"). MMC_PM_KEEP_POWEP is disabled for SD card and eMMC slots, so that they have no chance to invoke dw_mci_setup_bus for update clock behaviour. Let's consummate it. Reported-by: Randy Li Signed-off-by: Ziyuan Xu Signed-off-by: Shawn Lin --- C

[PATCH v2] mmc: dw_mmc: revise the reset path in runtime resume

2017-01-04 Thread Ziyuan Xu
s disabled for SD card and eMMC slots, so that they have no chance to invoke dw_mci_setup_bus for update clock behaviour. Let's consummate it. Reported-by: Randy Li Signed-off-by: Ziyuan Xu --- Changes in v2: - update the commit message - use dw_mci_reset instead of dw_mci_ctrl_reset d

[PATCH] mmc: dw_mmc: Fix some coding style

2017-01-04 Thread Ziyuan Xu
Let's fix the warnings from checkpatch.pl: - line over 80 characters; - block comments should align the * on each Lines; - statements not starting on a tabstop. Signed-off-by: Ziyuan Xu --- drivers/mmc/host/dw_mmc.c | 33 + 1 file changed, 17 insertions(+

Re: [PATCH 2/6] arm64: dts: rockchip: add pd_emmc power node for rk3399

2016-09-09 Thread Ziyuan Xu
hi Elaine, On 2016年09月09日 15:40, Elaine Zhang wrote: 1.add pd node for RK3399 Soc 2.create power domain tree 3.add qos node for domain 4.add the pd_emmc consumers node Signed-off-by: Elaine Zhang I had push this patch, see [0] [0] https://patchwork.kernel.org/patch/9320423/ --- arch/ar

Re: [PATCH 2/2] arm64: dts: rockchip: add eMMC's power domain support for rk3399

2016-09-02 Thread Ziyuan Xu
Hi Ulf, On 2016年09月02日 18:24, Ulf Hansson wrote: On 1 September 2016 at 23:50, Doug Anderson wrote: >Hi, > >On Thu, Sep 1, 2016 at 6:45 AM, Ulf Hansson wrote: >>I was reading the discussion regarding this change and browsing the DT >>documentation around this... Can you guys explain what re

Re: [PATCH 2/2] arm64: dts: rockchip: add eMMC's power domain support for rk3399

2016-09-01 Thread Ziyuan Xu
On 2016年09月02日 05:29, Doug Anderson wrote: Hi, On Wed, Aug 31, 2016 at 11:56 PM, Ziyuan Xu wrote: Hi On 2016年09月01日 12:20, Doug Anderson wrote: Hi, On Wed, Aug 31, 2016 at 7:29 PM, Ziyuan Xu wrote: This is fine to pick up _only_ if you don't care about suspend/resume. If you

Re: [PATCH 2/2] arm64: dts: rockchip: add eMMC's power domain support for rk3399

2016-08-31 Thread Ziyuan Xu
Hi On 2016年09月01日 12:20, Doug Anderson wrote: Hi, On Wed, Aug 31, 2016 at 7:29 PM, Ziyuan Xu wrote: This is fine to pick up _only_ if you don't care about suspend/resume. If you care about suspend/resume then someone needs to first write a patch that will re-init all "corecfg&quo

Re: [PATCH 2/2] arm64: dts: rockchip: add eMMC's power domain support for rk3399

2016-08-31 Thread Ziyuan Xu
Hi, On 2016年09月01日 01:42, Doug Anderson wrote: Hi, On Sun, Aug 28, 2016 at 8:25 PM, Shawn Lin wrote: On 2016/8/29 10:50, Elaine Zhang wrote: On 08/27/2016 11:05 PM, Shawn Lin wrote: On 2016/8/27 21:41, Ziyuan Xu wrote: Control power domain for eMMC via genpd to reduce power consumption

Re: [PATCH v2 2/4] mmc: sdhci-of-arasan: Control clock for accessing syscon

2016-08-30 Thread Ziyuan Xu
Without this series of patches, we can't gate aclk_emmcgrf even though driver enter suspend/remove. It meaningful to save power consumption. It looks nice to me, and also I have tested on rk3399 board, so Tested-by: Ziyuan Xu Changes in v2: - assign NULL to clk_syscon if it's not

Re: [PATCH v2 3/4] arm64: dts: rockchip: add clk_syscon for sdhci on rk3399

2016-08-30 Thread Ziyuan Xu
Hi Shawn, On 2016年08月31日 09:37, Shawn Lin wrote: We are intent on letting the sdhci variant driver handle this optional clock on rk3399 platform now. Signed-off-by: Shawn Lin --- Thanks for your patch, we can gate aclk_emmcgrf now as soon as sdhci driver suspend. Reviewed-by: Ziyuan Xu

Re: [PATCH v2 4/4] clk: rockchip: remove CLK_IGNORE_UNUSED flag for aclk_emmc_grf on rk3399

2016-08-30 Thread Ziyuan Xu
e, so Tested-by: Ziyuan Xu --- Changes in v2: None drivers/clk/rockchip/clk-rk3399.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/rockchip/clk-rk3399.c b/drivers/clk/rockchip/clk-rk3399.c index ede6c47..908f684 100644 --- a/drivers/clk/rockchip/clk-rk3

Re: [PATCH 1/2] Documentation: mmc: sdhci-of-arasan: add description of power domain

2016-08-28 Thread Ziyuan Xu
On 2016年08月27日 22:50, Shawn Lin wrote: On 2016/8/27 21:41, Ziyuan Xu wrote: Add power domain as a optional property for sdhci-of-arasan, which can be truned off in the so-called unused condition, such as suspend and remove. Aim to lower power requirements. Signed-off-by: Ziyuan Xu

[PATCH 1/2] Documentation: mmc: sdhci-of-arasan: add description of power domain

2016-08-27 Thread Ziyuan Xu
Add power domain as a optional property for sdhci-of-arasan, which can be truned off in the so-called unused condition, such as suspend and remove. Aim to lower power requirements. Signed-off-by: Ziyuan Xu --- Documentation/devicetree/bindings/mmc/arasan,sdhci.txt | 6 +- 1 file changed

[PATCH 2/2] arm64: dts: rockchip: add eMMC's power domain support for rk3399

2016-08-27 Thread Ziyuan Xu
Control power domain for eMMC via genpd to reduce power consumption. Signed-off-by: Elaine Zhang Signed-off-by: Ziyuan Xu --- arch/arm64/boot/dts/rockchip/rk3399.dtsi | 11 +++ 1 file changed, 11 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot

[PATCH 0/2] Add power domain support for eMMC node on rk3399

2016-08-27 Thread Ziyuan Xu
This series add power domain for eMMC node which will be controlled by genpd to make sure it's available in probing state, and will be off once suspend/remove. Ziyuan Xu (2): Documentation: mmc: sdhci-of-arasan: add description of power domain arm64: dts: rockchip: add eMMC's po