diff options
author | Manish Badarkhe <badarkhe.manish@gmail.com> | 2014-01-29 18:57:27 +0400 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-02-11 20:34:32 +0400 |
commit | e31108cad3deabb1a63111d7aa699ca67753c01f (patch) | |
tree | 064b0ddbd24537c667b4d308286d980770f83ac5 /include/linux/device.h | |
parent | 38dbfb59d1175ef458d006556061adeaa8751b72 (diff) | |
download | linux-e31108cad3deabb1a63111d7aa699ca67753c01f.tar.xz |
devres: introduce API "devm_kstrdup"
This patch introduces "devm_kstrdup" API so that the
device's driver can allocate memory and copy string.
Signed-off-by: Manish Badarkhe <badarkhe.manish@gmail.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'include/linux/device.h')
-rw-r--r-- | include/linux/device.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/device.h b/include/linux/device.h index 952b01033c32..ec1b6e21f0ef 100644 --- a/include/linux/device.h +++ b/include/linux/device.h @@ -626,6 +626,7 @@ static inline void *devm_kcalloc(struct device *dev, return devm_kmalloc_array(dev, n, size, flags | __GFP_ZERO); } extern void devm_kfree(struct device *dev, void *p); +extern char *devm_kstrdup(struct device *dev, const char *s, gfp_t gfp); void __iomem *devm_ioremap_resource(struct device *dev, struct resource *res); void __iomem *devm_request_and_ioremap(struct device *dev, |