Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 312500
b: refs/heads/master
c: 0713e6a
h: refs/heads/master
v: v3
  • Loading branch information
Axel Lin authored and Mark Brown committed Jun 3, 2012
1 parent 04eef4a commit 211b621
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 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: 8029a00686e396919b9adb2a6df07d68ef96cf3d
refs/heads/master: 0713e6abf398327b6813398d3583e0907953e457
15 changes: 3 additions & 12 deletions trunk/drivers/regulator/anatop-regulator.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,21 +94,10 @@ static int anatop_get_voltage_sel(struct regulator_dev *reg)
return val - anatop_reg->min_bit_val;
}

static int anatop_list_voltage(struct regulator_dev *reg, unsigned selector)
{
struct anatop_regulator *anatop_reg = rdev_get_drvdata(reg);
int uv;

uv = anatop_reg->min_voltage + selector * 25000;
dev_dbg(&reg->dev, "vddio = %d, selector = %u\n", uv, selector);

return uv;
}

static struct regulator_ops anatop_rops = {
.set_voltage = anatop_set_voltage,
.get_voltage_sel = anatop_get_voltage_sel,
.list_voltage = anatop_list_voltage,
.list_voltage = regulator_list_voltage_linear,
};

static int __devinit anatop_regulator_probe(struct platform_device *pdev)
Expand Down Expand Up @@ -176,6 +165,8 @@ static int __devinit anatop_regulator_probe(struct platform_device *pdev)

rdesc->n_voltages = (sreg->max_voltage - sreg->min_voltage)
/ 25000 + 1;
rdesc->min_uV = sreg->min_voltage;
rdesc->uV_step = 25000;

config.dev = &pdev->dev;
config.init_data = initdata;
Expand Down

0 comments on commit 211b621

Please sign in to comment.