From: Sachin Kamat Date: Fri, 20 Jun 2014 09:59:00 +0000 (+0530) Subject: ASoC: sta529: Remove redundant OOM message X-Git-Tag: firefly_0821_release~176^2~3158^2~37^2~6^3~12 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=5c1573a342ad6452f2d7af284612baae5d532a0a;p=firefly-linux-kernel-4.4.55.git ASoC: sta529: Remove redundant OOM message Let memory subsystem handle the error logging. Signed-off-by: Sachin Kamat Signed-off-by: Mark Brown --- diff --git a/sound/soc/codecs/sta529.c b/sound/soc/codecs/sta529.c index a40c4b0196a3..fcdf11026aff 100644 --- a/sound/soc/codecs/sta529.c +++ b/sound/soc/codecs/sta529.c @@ -380,10 +380,8 @@ static int sta529_i2c_probe(struct i2c_client *i2c, return -EINVAL; sta529 = devm_kzalloc(&i2c->dev, sizeof(struct sta529), GFP_KERNEL); - if (sta529 == NULL) { - dev_err(&i2c->dev, "Can not allocate memory\n"); + if (!sta529) return -ENOMEM; - } sta529->regmap = devm_regmap_init_i2c(i2c, &sta529_regmap); if (IS_ERR(sta529->regmap)) {