mfd: si476x-i2c: Delete an error message for a failed memory allocation in si476x_core_probe()

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-03-08 13:45:31 +01:00 committed by Lee Jones
parent 6271299d27
commit a9241b0921
1 changed files with 2 additions and 4 deletions

View File

@ -697,11 +697,9 @@ static int si476x_core_probe(struct i2c_client *client,
int cell_num;
core = devm_kzalloc(&client->dev, sizeof(*core), GFP_KERNEL);
if (!core) {
dev_err(&client->dev,
"failed to allocate 'struct si476x_core'\n");
if (!core)
return -ENOMEM;
}
core->client = client;
core->regmap = devm_regmap_init_si476x(core);