diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2013-10-24 19:57:26 +0200 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2013-10-24 21:38:17 +0200 |
commit | b713be73fb5b22cedb7df136af871f17b6941672 (patch) | |
tree | 687d70577641e5342f52b05939872a2451430828 /backport/backport-include/linux | |
parent | 66af89a4a44179db5e7e7729bcf12ad474352ba0 (diff) |
backports: add devm_regulator_register()
This backports the following commit from mainline:
commit b33e46bcdc4e598d738ed12a5a7906be4e11d786
Author: Mark Brown <broonie@linaro.org>
Date: Sat Aug 31 11:58:26 2013 +0100
regulator: core: Provide managed regulator registration
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Diffstat (limited to 'backport/backport-include/linux')
-rw-r--r-- | backport/backport-include/linux/regulator/driver.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/backport/backport-include/linux/regulator/driver.h b/backport/backport-include/linux/regulator/driver.h index fbd98459..f56990bf 100644 --- a/backport/backport-include/linux/regulator/driver.h +++ b/backport/backport-include/linux/regulator/driver.h @@ -23,4 +23,14 @@ int regulator_map_voltage_ascend(struct regulator_dev *rdev, int min_uV, int max_uV); #endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(3,6,0)) */ +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3,13,0)) && \ + (LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0)) +struct regulator_dev * +devm_regulator_register(struct device *dev, + const struct regulator_desc *regulator_desc, + const struct regulator_config *config); +void devm_regulator_unregister(struct device *dev, struct regulator_dev *rdev); +#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(3,13,0)) && + (LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0)) */ + #endif /* __BACKPORT_LINUX_REGULATOR_DRIVER_H_ */ |