ASoC: wm9090: Remove redundant OOM message
authorSachin Kamat <sachin.kamat@samsung.com>
Fri, 20 Jun 2014 09:59:11 +0000 (15:29 +0530)
committerMark Brown <broonie@linaro.org>
Fri, 27 Jun 2014 11:48:23 +0000 (12:48 +0100)
Let memory subsystem handle the error logging.

Signed-off-by: Sachin Kamat <sachin.kamat@samsung.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
sound/soc/codecs/wm9090.c

index 87934171f0637da2c2a307893a641a43b0193e0b..a13f0725611a9be6284678069ca9bafe9a98e66f 100644 (file)
@@ -613,10 +613,8 @@ static int wm9090_i2c_probe(struct i2c_client *i2c,
        int ret;
 
        wm9090 = devm_kzalloc(&i2c->dev, sizeof(*wm9090), GFP_KERNEL);
-       if (wm9090 == NULL) {
-               dev_err(&i2c->dev, "Can not allocate memory\n");
+       if (!wm9090)
                return -ENOMEM;
-       }
 
        wm9090->regmap = devm_regmap_init_i2c(i2c, &wm9090_regmap);
        if (IS_ERR(wm9090->regmap)) {