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

ASoC: tlv320aic3x: Remove redundant OOM message

Let memory subsystem handle the error logging.
Signed-off-by: default avatarSachin Kamat <sachin.kamat@samsung.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 5c1573a3
...@@ -1477,10 +1477,8 @@ static int aic3x_i2c_probe(struct i2c_client *i2c, ...@@ -1477,10 +1477,8 @@ static int aic3x_i2c_probe(struct i2c_client *i2c,
u32 value; u32 value;
aic3x = devm_kzalloc(&i2c->dev, sizeof(struct aic3x_priv), GFP_KERNEL); aic3x = devm_kzalloc(&i2c->dev, sizeof(struct aic3x_priv), GFP_KERNEL);
if (aic3x == NULL) { if (!aic3x)
dev_err(&i2c->dev, "failed to create private data\n");
return -ENOMEM; return -ENOMEM;
}
aic3x->regmap = devm_regmap_init_i2c(i2c, &aic3x_regmap); aic3x->regmap = devm_regmap_init_i2c(i2c, &aic3x_regmap);
if (IS_ERR(aic3x->regmap)) { if (IS_ERR(aic3x->regmap)) {
...@@ -1498,10 +1496,8 @@ static int aic3x_i2c_probe(struct i2c_client *i2c, ...@@ -1498,10 +1496,8 @@ static int aic3x_i2c_probe(struct i2c_client *i2c,
} else if (np) { } else if (np) {
ai3x_setup = devm_kzalloc(&i2c->dev, sizeof(*ai3x_setup), ai3x_setup = devm_kzalloc(&i2c->dev, sizeof(*ai3x_setup),
GFP_KERNEL); GFP_KERNEL);
if (ai3x_setup == NULL) { if (!ai3x_setup)
dev_err(&i2c->dev, "failed to create private data\n");
return -ENOMEM; return -ENOMEM;
}
ret = of_get_named_gpio(np, "gpio-reset", 0); ret = of_get_named_gpio(np, "gpio-reset", 0);
if (ret >= 0) if (ret >= 0)
......
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