diff options
author | Axel Lin <axel.lin@gmail.com> | 2012-04-17 18:06:50 +0800 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-04-17 14:44:32 +0100 |
commit | 575f690dc4973027ce7e93360678681d09f65fac (patch) | |
tree | 0b1552f07183a255d6ea434804f860e823bebefe /drivers/regulator | |
parent | 98d8618af37728f6e18e84110ddb99987b47dd12 (diff) | |
download | blackbird-op-linux-575f690dc4973027ce7e93360678681d09f65fac.tar.gz blackbird-op-linux-575f690dc4973027ce7e93360678681d09f65fac.zip |
regulator: max8660: Fix a memory leak due to missing devm_kzalloc conversion
commit 4d26f7 "regulator: max8660: Use devm_kzalloc()" missed to
replace kzalloc by devm_kzalloc. Fix it.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/regulator')
-rw-r--r-- | drivers/regulator/max8660.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/max8660.c b/drivers/regulator/max8660.c index 9997cfbc3471..5d568175cc27 100644 --- a/drivers/regulator/max8660.c +++ b/drivers/regulator/max8660.c @@ -370,7 +370,7 @@ static int __devinit max8660_probe(struct i2c_client *client, return -EINVAL; } - max8660 = kzalloc(sizeof(struct max8660) + + max8660 = devm_kzalloc(&client->dev, sizeof(struct max8660) + sizeof(struct regulator_dev *) * MAX8660_V_END, GFP_KERNEL); if (!max8660) |