mirror of https://gitee.com/openkylin/linux.git
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:
parent
24303ee721
commit
46c8aa8e3f
|
@ -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))
|
||||
|
|
Loading…
Reference in New Issue