From 3606c089ae6fd36d56482c0956abee6836c3a4b9 Mon Sep 17 00:00:00 2001 From: Mark Brown Date: Sun, 15 Apr 2012 11:16:05 +0100 Subject: [PATCH] --- yaml --- r: 302209 b: refs/heads/master c: 65b19ce6c223287ac95bbc22b12ef5a2738472d1 h: refs/heads/master i: 302207: 66c22af1921ad0cac19e29971de528fb3a4c6e96 v: v3 --- [refs] | 2 +- trunk/drivers/regulator/core.c | 2 ++ trunk/include/linux/regulator/driver.h | 4 ++++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 0fccdb82ca7b..69e63810e5b2 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 9f29c9e30b98832d98e8f528252fe193123a7d80 +refs/heads/master: 65b19ce6c223287ac95bbc22b12ef5a2738472d1 diff --git a/trunk/drivers/regulator/core.c b/trunk/drivers/regulator/core.c index 7943fd64988d..bca1e5989243 100644 --- a/trunk/drivers/regulator/core.c +++ b/trunk/drivers/regulator/core.c @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -2877,6 +2878,7 @@ regulator_register(const struct regulator_desc *regulator_desc, rdev->reg_data = config->driver_data; rdev->owner = regulator_desc->owner; rdev->desc = regulator_desc; + rdev->regmap = config->regmap; INIT_LIST_HEAD(&rdev->consumer_list); INIT_LIST_HEAD(&rdev->list); BLOCKING_INIT_NOTIFIER_HEAD(&rdev->notifier); diff --git a/trunk/include/linux/regulator/driver.h b/trunk/include/linux/regulator/driver.h index 4f529ed48d4c..2e753731217b 100644 --- a/trunk/include/linux/regulator/driver.h +++ b/trunk/include/linux/regulator/driver.h @@ -19,6 +19,7 @@ #include #include +struct regmap; struct regulator_dev; struct regulator_init_data; @@ -187,12 +188,14 @@ struct regulator_desc { * @driver_data: private regulator data * @of_node: OpenFirmware node to parse for device tree bindings (may be * NULL). + * @regmap: regmap to use for core regmap helpers */ struct regulator_config { struct device *dev; const struct regulator_init_data *init_data; void *driver_data; struct device_node *of_node; + struct regmap *regmap; }; /* @@ -223,6 +226,7 @@ struct regulator_dev { struct device dev; struct regulation_constraints *constraints; struct regulator *supply; /* for tree */ + struct regmap *regmap; struct delayed_work disable_work; int deferred_disables;