Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 253161
b: refs/heads/master
c: 1fcecf2
h: refs/heads/master
i:
  253159: ea3dd22
v: v3
  • Loading branch information
Balaji T K authored and Tony Lindgren committed Jun 1, 2011
1 parent 47c039f commit ed71cf0
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1704bf15deb6de20f8f4272c8d8232b36bbc7484
refs/heads/master: 1fcecf281b99f9ca262ae7fbc3703c421be5c857
13 changes: 10 additions & 3 deletions trunk/arch/arm/mach-omap2/hsmmc.c
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ static void omap4_hsmmc1_after_set_reg(struct device *dev, int slot,
int power_on, int vdd)
{
u32 reg;
unsigned long timeout;

if (power_on) {
reg = omap4_ctrl_pad_readl(control_pbias_offset);
Expand All @@ -157,9 +158,15 @@ static void omap4_hsmmc1_after_set_reg(struct device *dev, int slot,
OMAP4_MMC1_PWRDNZ_MASK |
OMAP4_USBC1_ICUSB_PWRDNZ_MASK);
omap4_ctrl_pad_writel(reg, control_pbias_offset);
/* 4 microsec delay for comparator to generate an error*/
udelay(4);
reg = omap4_ctrl_pad_readl(control_pbias_offset);

timeout = jiffies + msecs_to_jiffies(5);
do {
reg = omap4_ctrl_pad_readl(control_pbias_offset);
if (!(reg & OMAP4_MMC1_PBIASLITE_VMODE_ERROR_MASK))
break;
usleep_range(100, 200);
} while (!time_after(jiffies, timeout));

if (reg & OMAP4_MMC1_PBIASLITE_VMODE_ERROR_MASK) {
pr_err("Pbias Voltage is not same as LDO\n");
/* Caution : On VMODE_ERROR Power Down MMC IO */
Expand Down

0 comments on commit ed71cf0

Please sign in to comment.