[PATCH] sdhci: vmmc regulator should be explicitly enabled/disabled

2012-07-23 Thread philipspatches
From: Philip Rakity The vmmc regulator should not rely on it being enabled in the platform code. Expliciitly enable and disable the regulator. Signed-off-by: Philip Rakity --- drivers/mmc/host/sdhci.c |7 +-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/h

[PATCH] sdhci: Add regulator support for vccq (voltage regualor)

2012-07-23 Thread philipspatches
From: Philip Rakity On some systems the host controller does not support vccq signaling. This is supplied by a dedicated regulator (vqmmc). Add support for this regulator. Signed-off-by: Philip Rakity --- drivers/mmc/host/sdhci.c | 179 + include

[PATCH] regulator: add missing defintion regulator_is_supported_voltage

2012-06-30 Thread philipspatches
From: Philip Rakity This definition is missing when CONFIG_REGULATOR is not defined. This causes compiler errors when compiling sdhci.c. This can be worked around by adding #ifdef CONFIG_REGULATOR .. #endif but since other definitions are there we have defined the missing definition Signed-off-

[PATCH] sdhci: V3: Allow CAPS[1] to be set via QUIRK

2012-06-27 Thread philipspatches
From: Philip Rakity currently only the capability_0 register can be set if SDHCI_QUIRK_MISSING_CAPS is defined. This is a problem when the capability_1 register also needs changing. Use the SDHCI_QUIRK_MISSING_CAPS to allow both registers to be set. Redefining caps[1] is useful when the board

[PATCH] sdhci: V2: Allow CAPS[1] to be set via QUIRK

2012-06-27 Thread philipspatches
From: Philip Rakity currently only the capability_0 register can be set if SDHCI_QUIRK_MISSING_CAPS is defined. This is a problem when the capability_1 register also needs changing. Use the SDHCI_QUIRK_MISSING_CAPS to allow both registers to be set. Redefining caps[1] is useful when the board

[PATCH] mmc: host: sdhci. UHS Switch failure - cycle power if regulator is used

2012-06-27 Thread philipspatches
From: Philip Rakity Power needs to be removed from the card when switching to 1.8v fails. If a regulator is used to control vmmc we need to turn the regulator off and then back on otherwise power will not be removed from the card. Signed-off-by: Philip Rakity --- drivers/mmc/host/sdhci.c |

[PATCH 1/2] mmc: Add support for Signal (vccq) Voltage Switching using Regulators

2012-06-08 Thread philipspatches
From: Philip Rakity The SD Host Controller may require a regulator to support signal and voltage switching. Curently we support voltage (vmmc) but not signal changing via a regulator. Add this support. If a regulator is supported and voltage switching to 1.8V is supported then use the vmmc reg

[PATCH 2/2] mmc: only support voltage (vdd) that regulator agree's with

2012-06-08 Thread philipspatches
From: Philip Rakity If we are using a regulator the SD Host Controller and the regulator should agree about the voltages supported. Use the common subset that is supported. Signed-off-by: Philip Rakity --- drivers/mmc/host/sdhci.c | 15 +++ 1 files changed, 15 insertions(+), 0 d

[PATCH] mmc: sdhci: Allow CAPABILITY_1 Register to be overridden

2012-06-05 Thread philipspatches
From: Philip Rakity V2 -- initialize caps[2] to 0. remove else if V1 -- host capability register caps[0] can be changed by the platform code using a quirk host capability_1 register caps[1] should also be allowed to be redefined. This is useful if UHS or other modes are not supported that are

[PATCH] mmc: sdhci: Allow CAPABILITY_1 Register to be overridden

2012-06-02 Thread philipspatches
From: Philip Rakity CAPABILITY_1 can be changed by the platform code using a quirk CAPALBILTY_2 should also be allowed to be redefined. This is useful if UHS or other modes are not supported that are defined in the the register but the platform code has specific information that these value shou

[PATCH 1/3] mmc: sdhci - if MAX_CURRENT returns 0 try to use regulator to get current

2012-05-27 Thread philipspatches
From: Philip Rakity The sd host controller spec indicates the the MAX_CURRENT value may be returned as 0. In this case other methods need to be used to return the current. If 0 is returned and there is a regulator, ask the regulator for how much current is available. Signed-off-by: Mark F. Bro

[PATCH 2/3] mmc: sdhci only set 200ma support for 1.8v if 200ma is available

2012-05-27 Thread philipspatches
From: Philip Rakity max_current_caps can return 0 if not available from the sd controller. if no regulator is present or the regulator specifies a current less then 200ma we will set the 200ma caps bit by default. do not do this. Signed-off-by: Philip Rakity Reviewed-by: Aaron Lu --- drivers

[PATCH 3/3] mmc: do not attempt UHS 1.8v support if board does not support it

2012-05-27 Thread philipspatches
From: Philip Rakity We have h/w that does not support 1.8v signaling even though the controller does support this. If we enable 1.8v support UHS cards are recognised but recovery to 3.3v is not possible depending on the SD card. Ensure that when we do not support 1.8v UHS mode cards can work (i

[PATCH] mmc: core: UHS sdio card that fails should not exceed 50MHz

2012-01-26 Thread philipspatches
From: Philip Rakity A UHS sdio card that fails initialization at 1.8v signaling is not in UHS mode. We cannot use the speed in the the cis to reflect the bus speed as this is the maxiumum value and will not reflect the fact that the host is operating at a lower (non uhs) bus speed. Signed-off-b