Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 332850
b: refs/heads/master
c: 9cde5b7
h: refs/heads/master
v: v3
  • Loading branch information
Chris Ball committed Oct 7, 2012
1 parent ce527b7 commit af3930d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 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: f4f24ade1b24ec09981b5506e3a9a19a96055435
refs/heads/master: 9cde5b7a49a88939d648c361ec938fa8a633a045
10 changes: 6 additions & 4 deletions trunk/drivers/mmc/core/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,8 @@ int mmc_regulator_set_ocr(struct mmc_host *mmc,
int tmp;
int voltage;

/* REVISIT mmc_vddrange_to_ocrmask() may have set some
/*
* REVISIT mmc_vddrange_to_ocrmask() may have set some
* bits this regulator doesn't quite support ... don't
* be too picky, most cards and regulators are OK with
* a 0.1V range goof (it's a small error percentage).
Expand All @@ -1127,12 +1128,13 @@ int mmc_regulator_set_ocr(struct mmc_host *mmc,
max_uV = min_uV + 100 * 1000;
}

/* avoid needless changes to this voltage; the regulator
* might not allow this operation
/*
* If we're using a fixed/static regulator, don't call
* regulator_set_voltage; it would fail.
*/
voltage = regulator_get_voltage(supply);

if (mmc->caps2 & MMC_CAP2_BROKEN_VOLTAGE)
if (regulator_count_voltages(supply) == 1)
min_uV = max_uV = voltage;

if (voltage < 0)
Expand Down

0 comments on commit af3930d

Please sign in to comment.