regmap: Remove unnecessary printk for failed allocation
authorCharles Keepax <ckeepax@opensource.cirrus.com>
Thu, 22 Feb 2018 12:59:11 +0000 (12:59 +0000)
committerMark Brown <broonie@kernel.org>
Mon, 26 Feb 2018 11:00:31 +0000 (11:00 +0000)
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regmap.c

index 8fe6e08fa41ee426c5317727784a21450e1e6d12..707b0450ad720d914d8f6617db1f94602f7db4c1 100644 (file)
@@ -2050,10 +2050,9 @@ out:
                        return -EINVAL;
 
                wval = kmemdup(val, val_count * val_bytes, map->alloc_flags);
-               if (!wval) {
-                       dev_err(map->dev, "Error in memory allocation\n");
+               if (!wval)
                        return -ENOMEM;
-               }
+
                for (i = 0; i < val_count * val_bytes; i += val_bytes)
                        map->format.parse_inplace(wval + i);