mfd: smsc-ece1099: Delete an error message for a failed memory allocation

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
This commit is contained in:
Markus Elfring 2018-01-16 08:52:27 +01:00 committed by Lee Jones
parent 24303ee721
commit 46c8aa8e3f

View File

@ -39,10 +39,8 @@ static int smsc_i2c_probe(struct i2c_client *i2c,
smsc = devm_kzalloc(&i2c->dev, sizeof(struct smsc),
GFP_KERNEL);
if (!smsc) {
dev_err(&i2c->dev, "smsc mfd driver memory allocation failed\n");
if (!smsc)
return -ENOMEM;
}
smsc->regmap = devm_regmap_init_i2c(i2c, &smsc_regmap_config);
if (IS_ERR(smsc->regmap))