ASoC: codecs: sgtl5000: Use dev_err_probe() helper

Use the dev_err_probe() helper, instead of open-coding the same
operation.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/20211214020843.2225831-7-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Kuninori Morimoto 2021-12-14 11:08:27 +09:00 committed by Mark Brown
parent 526f6ca95a
commit ec1e0e72a8
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0

View File

@ -1612,9 +1612,8 @@ static int sgtl5000_i2c_probe(struct i2c_client *client,
if (ret == -ENOENT)
ret = -EPROBE_DEFER;
if (ret != -EPROBE_DEFER)
dev_err(&client->dev, "Failed to get mclock: %d\n",
ret);
dev_err_probe(&client->dev, ret, "Failed to get mclock\n");
goto disable_regs;
}