Commit ef4bcf88 authored by Sachin Kamat's avatar Sachin Kamat Committed by Mark Brown

regulator: tps51632: Remove redundant error message

kzalloc prints its own OOM message upon failure.
Signed-off-by: default avatarSachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 38dbfb59
...@@ -227,10 +227,8 @@ static struct tps51632_regulator_platform_data * ...@@ -227,10 +227,8 @@ static struct tps51632_regulator_platform_data *
struct device_node *np = dev->of_node; struct device_node *np = dev->of_node;
pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL);
if (!pdata) { if (!pdata)
dev_err(dev, "Memory alloc failed for platform data\n");
return NULL; return NULL;
}
pdata->reg_init_data = of_get_regulator_init_data(dev, dev->of_node); pdata->reg_init_data = of_get_regulator_init_data(dev, dev->of_node);
if (!pdata->reg_init_data) { if (!pdata->reg_init_data) {
...@@ -299,10 +297,8 @@ static int tps51632_probe(struct i2c_client *client, ...@@ -299,10 +297,8 @@ static int tps51632_probe(struct i2c_client *client,
} }
tps = devm_kzalloc(&client->dev, sizeof(*tps), GFP_KERNEL); tps = devm_kzalloc(&client->dev, sizeof(*tps), GFP_KERNEL);
if (!tps) { if (!tps)
dev_err(&client->dev, "Memory allocation failed\n");
return -ENOMEM; return -ENOMEM;
}
tps->dev = &client->dev; tps->dev = &client->dev;
tps->desc.name = client->name; tps->desc.name = client->name;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment