[PATCH] Powerpc/dts: Correct sdhci quirk for bsc9131

2013-09-02 Thread Haijun Zhang
We use property "sdhci,auto-cmd12" instead of "fsl,sdhci-auto-cmd12" to distinguish if the sdhc host has quirk SDHCI_QUIRK_MULTIBLOCK_READ_ACMD12. Signed-off-by: Haijun Zhang --- arch/powerpc/boot/dts/fsl/bsc9131si-post.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 delet

[PATCH] Powerpc/eSDCH: Specify voltage for T4240QDS

2013-08-28 Thread Haijun Zhang
Freescale T4240QDS reference board has extra voltage shifters added to allow 3.3V operation, so add 3.3v voltage support for T4240QDS. 1.8v and 3.3v is recommand for eMMC and SDHC card. Signed-off-by: Haijun Zhang --- arch/powerpc/boot/dts/t4240qds.dts | 4 1 file changed, 4 insertions

[PATCH 1/3 V5] mmc:core: parse voltage from device-tree

2013-08-13 Thread Haijun Zhang
Add function to support get voltage from device-tree. If there are voltage-range specified in device-tree node, this function will parse it and return the available voltage mask. Signed-off-by: Haijun Zhang --- changes for v5: - add binding spec for this device node changes for v4

[PATCH 3/3 V3] mmc:esdhc: add support to get voltage from device-tree

2013-08-11 Thread Haijun Zhang
Add suppport to get voltage from device-tree node for esdhc host, if voltage-ranges was specified in device-tree node we can get ocr_mask instead of read from host capacity register. If not voltages still can be get from host capacity register. Signed-off-by: Haijun Zhang --- changes for V3

[PATCH 2/3 V3] mmc:sdhc: get voltage from sdhc host

2013-08-11 Thread Haijun Zhang
We use host->ocr_mask to hold the voltage get from device-tree node, In case host->ocr_mask was available, we use host->ocr_mask as the final available voltage can be used by MMC/SD/SDIO card. Signed-off-by: Haijun Zhang --- changes for V3: - changed the type of mask drivers

[PATCH V3] mmc:of_spi: Update the code of getting voltage-ranges

2013-08-11 Thread Haijun Zhang
Using function mmc_of_parse_voltage() to get voltage-ranges. Signed-off-by: Haijun Zhang --- changes for V3: - changes the type of ocr_mask and function mmc_of_parse_voltage drivers/mmc/host/of_mmc_spi.c | 23 +++ 1 file changed, 3 insertions(+), 20 deletions

[PATCH 1/3 V4] mmc:core: parse voltage from device-tree

2013-08-11 Thread Haijun Zhang
Add function to support get voltage from device-tree. If there are voltage-range specified in device-tree node, this function will parse it and return the available voltage mask. Signed-off-by: Haijun Zhang --- changes for V4: - Add new parameter mask to return voltages. changes for V3

[PATCH] mmc:of_spi: Update the code of getting voltage-ranges

2013-07-31 Thread Haijun Zhang
Using function mmc_of_parse_voltage() to get voltage-ranges. Signed-off-by: Haijun Zhang --- drivers/mmc/host/of_mmc_spi.c | 22 -- 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/drivers/mmc/host/of_mmc_spi.c b/drivers/mmc/host/of_mmc_spi.c index d720b5e

[PATCH 1/3 V2] mmc:core: parse voltage from device-tree

2013-07-31 Thread Haijun Zhang
Add function to support get voltage from device-tree. If there are voltage-range specified in device-tree node, this function will parse it and return the avail voltage mask. Signed-off-by: Haijun Zhang --- changes for v2: - Update the parameters of function drivers/mmc/core/core.c

[PATCH 3/3 V2] mmc:esdhc: add support to get voltage from device-tree

2013-07-31 Thread Haijun Zhang
Add suppport to get voltage from device-tree node for esdhc host, if voltage-ranges was specified in device-tree node we can get ocr_mask instead of read from host capacity register. If not voltages still can be get from host capacity register. Signed-off-by: Haijun Zhang --- changes for v2

[PATCH 3/3] mmc:esdhc: add support to get voltage from device-tree

2013-07-28 Thread Haijun Zhang
Add suppport to get voltage from device-tree node for esdhc host, if voltage-ranges was specified in device-tree node we can get ocr_mask instead of read from host capacity register. If not voltages still can be get from host capacity register. Signed-off-by: Haijun Zhang --- drivers/mmc/host

[PATCH 2/3] mmc:sdhc: get voltage from sdhc host

2013-07-28 Thread Haijun Zhang
We use host->ocr_mask to hold the voltage get from device-tree node, In case host->ocr_mask was available, we use host->ocr_mask as the final available voltage can be used by MMC/SD/SDIO card. Signed-off-by: Haijun Zhang --- drivers/mmc/host/sdhci.c | 3 +++ include/linux/mmc/sdhci.h

[PATCH 1/3] mmc:core: parse voltage from device-tree

2013-07-28 Thread Haijun Zhang
Add function to support get voltage from device-tree. If there are voltage-range specified in device-tree node, this function will parse it and return the avail voltage mask. Signed-off-by: Haijun Zhang --- drivers/mmc/core/core.c | 48 include

[PATCH 2/2 V2] mmc: esdhc: get voltage from dts file

2013-07-24 Thread Haijun Zhang
Add voltage-range support in esdhc of T4, So we can choose to read voltages from dts file as one optional. If we can get a valid voltage-range from device node, we use this voltage as the final voltage support. Else we still read from capacity or from other provider. Signed-off-by: Haijun Zhang

[PATCH 1/2 V2] Powerpc: Add voltage support in dts file

2013-07-23 Thread Haijun Zhang
eSDHC of T4240 had 1.8v voltage support. Add this node to specify eSDHC voltage capacity. If this node not specified eSDHC driver still can read from eSDHC host capacity register. Signed-off-by: Haijun Zhang Signed-off-by: Anton Vorontsov --- changes for v2: - rewrite the voltage-ranges

[PATCH 2/2] Powerpc: Add 3.3v voltage support for T4240QDS

2013-07-22 Thread Haijun Zhang
Freescale T4240QDS reference board has extra voltage shifters added to allow 3.3V operation, so add 3.3v voltage support for T4240QDS. Signed-off-by: Haijun Zhang Signed-off-by: Anton Vorontsov --- changes for this patch set: - split from patch [PATCH 1/2] Powerpc: Add - voltage

[PATCH 1/2] Powerpc: Add voltage support in dts file

2013-07-22 Thread Haijun Zhang
eSDHC of T4240 had 1.8v voltage support. Add this node to specify eSDHC voltage capacity. If this node not specified eSDHC driver still can read from eSDHC host capacity register. Signed-off-by: Haijun Zhang Signed-off-by: Anton Vorontsov --- changes for this patch set: - split from

[PATCH 2/2] mmc: esdhc: get voltage from dts file

2013-07-22 Thread Haijun Zhang
Add voltage-range support in esdhc of T4, So we can choose to read voltages from dts file as one optional. If we can get a valid voltage-range from device node, we use this voltage as the final voltage support. Else we still read from capacity or from other provider. Signed-off-by: Haijun Zhang

[PATCH 1/2] Powerpc: Add voltage ranges support for T4

2013-07-22 Thread Haijun Zhang
Special voltages that can be support by eSDHC of T4 in esdhc node. Signed-off-by: Haijun Zhang Signed-off-by: Anton Vorontsov --- Documentation/devicetree/bindings/mmc/fsl-esdhc.txt | 3 +++ arch/powerpc/boot/dts/fsl/t4240si-post.dtsi | 1 + 2 files changed, 4 insertions(+) diff --git

[PATCH 3/4 V3] mmc: esdhc: Correct host version of T4240-R1.0-R2.0

2013-07-18 Thread Haijun Zhang
Vender version and sdhc spec version of T4240-R1.0-R2.0 is incorrect. The right value should be VVN=0x13, SVN = 0x1. The wrong version number will break down the ADMA data transfer. This defect only exist in T4240-R1.0-R2.0. Also share vvn and svr for public use. Signed-off-by: Haijun Zhang

[PATCH 4/4 V2] mmc: esdhc: Add broken timeout quirk for p4/p5 board

2013-07-17 Thread Haijun Zhang
Sometimes command can't be completed within the time give in eSDHC_SYSCTL[DTOCV]. So just give the max value 0x14 to avoid this issue. Signed-off-by: Haijun Zhang --- changes for v2: - Rebuild patch of eSDHC host need long time to generate command interrupt drivers/mmc

[PATCH 3/4 V2] mmc: esdhc: Correct host version of T4240-R1.0

2013-07-17 Thread Haijun Zhang
: Haijun Zhang --- changes for V2: - Remove broken ADMA quirk. - Rebuild patch of Add quirks to support T4240 board drivers/mmc/host/sdhci-of-esdhc.c | 29 + 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/drivers/mmc/host/sdhci-of

[PATCH 2/4 V2] mmc: esdhc: workaround for dma err in the last system transaction

2013-07-17 Thread Haijun Zhang
last descriptor line. Signed-off-by: Haijun Zhang --- changes for V2: - Update the svr version list drivers/mmc/host/sdhci-of-esdhc.c | 112 ++ 1 file changed, 102 insertions(+), 10 deletions(-) diff --git a/drivers/mmc/host/sdhci-of-esdhc.c b/drivers

[PATCH 1/4 V4] powerpc/85xx: Add support for 85xx cpu type detection

2013-07-16 Thread Haijun Zhang
Add this file to help detect cpu type in runtime. These macros will be more favorable for driver to apply errata and workaround to specified cpu type. Signed-off-by: Haijun Zhang Signed-off-by: Zhao Chenhui --- changes for v4: - Add new set of soc arch/powerpc/include/asm/mpc85xx.h

[PATCH V6] powerpc/85xx: add the P1020RDB-PD DTS support

2013-07-15 Thread Haijun Zhang
Overview of P1020RDB-PD device: - DDR3 2GB - NOR flash 64MB - NAND flash 128MB - SPI flash 16MB - I2C EEPROM 256Kb - eTSEC1 (RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 1 USB ports - TDM ports - PCIe Signed-off-by: Haijun Zhang Signed-off-by

[PATCH V5] powerpc/85xx: add the P1020RDB-PD DTS support

2013-07-11 Thread Haijun Zhang
Overview of P1020RDB-PD device: - DDR3 2GB - NOR flash 64MB - NAND flash 128MB - SPI flash 16MB - I2C EEPROM 256Kb - eTSEC1 (RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 1 USB ports - TDM ports - PCIe Signed-off-by: Haijun Zhang Signed-off-by

[PATCH V3] powerpc/85xx: Add support for 85xx cpu type detection

2013-07-10 Thread Haijun Zhang
Add this file to help detect cpu type in runtime. These macros will be more favorable for driver to apply errata and workaround to specified cpu type. Signed-off-by: Haijun Zhang Signed-off-by: Zhao Chenhui --- changes for v3: - remove get_svr and is_svr_rev arch/powerpc/include/asm

[PATCH 1/4 V2] powerpc/85xx: Add support for 85xx cpu type detection

2013-07-10 Thread Haijun Zhang
Add this file to help detect cpu type in runtime. These macros will be more favorable for driver to apply errata and workaround to specified cpu type. Signed-off-by: Haijun Zhang Signed-off-by: Zhao Chenhui --- changes v2: - Remove inline function - Ignore E bit of SOC

[PATCH 2/2 V4] powerpc/85xx: add the P1020RDB-PD DTS support

2013-07-09 Thread Haijun Zhang
Overview of P1020RDB-PD device: - DDR3 2GB - NOR flash 64MB - NAND flash 128MB - SPI flash 16MB - I2C EEPROM 256Kb - eTSEC1 (RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 1 USB ports - TDM ports - PCIe Signed-off-by: Haijun Zhang Signed-off-by

[PATCH 2/2 V3] powerpc/85xx: add the P1020RDB-PD DTS support

2013-07-09 Thread Haijun Zhang
Overview of P1020RDB-PD device: - DDR3 2GB - NOR flash 64MB - NAND flash 128MB - SPI flash 16MB - I2C EEPROM 256Kb - eTSEC1 (RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 2 USB ports - 4 TDM ports - PCIe Signed-off-by: Haijun Zhang Signed-off-by

[PATCH 3/4 V2] mmc: esdhc: Add quirks to support T4240QDS board

2013-07-08 Thread Haijun Zhang
On T4240QDS board controllers has an unusable ADMA engine, so use SDMA instead. Also 3.0v is support on T4240QDS board even if the capacity detailed only 1.8v support. Without this quirk SD card will declare voltage not support and Signed-off-by: Haijun Zhang --- changes for v2: - Change

[PATCH] Powerpc/t4240: change the compatible flags for t4240qds board

2013-07-08 Thread Haijun Zhang
In order to make a difference between different T4240 board. Specify T4240QDS board the unique compatible flags for t4240qds eSDHC host. Signed-off-by: Haijun Zhang --- arch/powerpc/boot/dts/fsl/t4240si-post.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc

[PATCH 1/4] powerpc/85xx: Add support for 85xx cpu type detection

2013-07-07 Thread Haijun Zhang
Add this file to help detect cpu type in runtime. These macros and inline routines will be more favorable for driver to apply errata and workaround to specified cpu type. Signed-off-by: Haijun Zhang Signed-off-by: Zhao Chenhui --- arch/powerpc/include/asm/mpc85xx.h | 96

[PATCH 4/4] mmc: eSDHC: Some eSDHC host need long time to generate command interrupt

2013-07-07 Thread Haijun Zhang
Command complete interrupt not always generate within 10 * HZ. Sometimes 500 * HZ or more. So enlarge this detecting value to ensure the host had sufficient time to generate command complete interrupt. Signed-off-by: Haijun Zhang --- drivers/mmc/host/sdhci-of-esdhc.c | 3 +++ drivers/mmc/host

[PATCH 3/4] mmc: esdhc: Add quirks to support T4240 board

2013-07-07 Thread Haijun Zhang
On T4240 board controllers has an unusable ADMA engine, so use SDMA instead. Also 3.0v is support on T4240 board even if the capacity detailed only 1.8v support. Without this quirk SD card will declare voltage not support and Signed-off-by: Haijun Zhang --- drivers/mmc/host/sdhci-pltfm.c | 5

[PATCH 2/4] mmc: esdhc: workaround for dma err in the last system transaction

2013-07-07 Thread Haijun Zhang
last descriptor line. Signed-off-by: Haijun Zhang --- drivers/mmc/host/sdhci-of-esdhc.c | 113 +++--- 1 file changed, 104 insertions(+), 9 deletions(-) diff --git a/drivers/mmc/host/sdhci-of-esdhc.c b/drivers/mmc/host/sdhci-of-esdhc.c index 15039e2..b22cab0 100644

[PATCH V2 2/2] powerpc/85xx: add the P1020RDB-PD DTS support

2013-07-04 Thread Haijun Zhang
Overview of P1020RDB-PD device: - DDR3 2GB - NOR flash 64MB - NAND flash 128MB - SPI flash 16MB - I2C EEPROM 256Kb - eTSEC1 (RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 2 USB ports - 4 TDM ports - PCIe Signed-off-by: Haijun Zhang Signed-off-by

[PATCH] DTS: Add compatible list for eSDHC

2013-06-30 Thread Haijun Zhang
Add compatible of esdhc for below board: p2041 p3041 p4080 p5020 p5040 Signed-off-by: Haijun Zhang CC: Scott Wood CC: Fleming Andrew-AFLEMING --- arch/powerpc/boot/dts/fsl/p2041si-post.dtsi | 1 + arch/powerpc/boot/dts/fsl/p3041si-post.dtsi | 1 + arch/powerpc/boot/dts/fsl/p4080si

[PATCH 2/2] powerpc/85xx: add the P1020RDB-PD DTS support

2013-06-30 Thread Haijun Zhang
From: "Haijun.Zhang" Overview of P1020RDB-PD device: - DDR3 2GB - NOR flash 64MB - NAND flash 128MB - SPI flash 16MB - I2C EEPROM 256Kb - eTSEC1 (RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 2 USB ports - 4 TDM ports - PCIe Signed-off-

[PATCH 1/2] [PATCH] powerpc/85xx: add P1020RDB-PD platform support

2013-06-30 Thread Haijun Zhang
(RGMII PHY) connected to VSC7385 L2 switch - eTSEC2 (SGMII PHY) - eTSEC3 (RGMII PHY) - SDHC - 2 USB ports - 4 TDM ports - PCIe Signed-off-by: Haijun Zhang Signed-off-by: Jerry Huang CC: Scott Wood --- arch/powerpc/platforms/85xx/mpc85xx_