projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b407589
)
ASoC: cs42l42: Switch to use dev_err_probe() helper
author
Yang Yingliang
<yangyingliang@huawei.com>
Wed, 14 Sep 2022 13:33:54 +0000
(21:33 +0800)
committer
Mark Brown
<broonie@kernel.org>
Wed, 14 Sep 2022 14:06:01 +0000
(15:06 +0100)
dev_err() can be replace with dev_err_probe() which will check if error
code is -EPROBE_DEFER.
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link:
https://lore.kernel.org/r/20220914133355.3779364-2-yangyingliang@huawei.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/cs42l42.c
patch
|
blob
|
history
diff --git
a/sound/soc/codecs/cs42l42.c
b/sound/soc/codecs/cs42l42.c
index de1e276bdf7da8ab08aff7a08a8fdcb99f3a1023..162540c153f960eb0464e3bcc0020506443f451c 100644
(file)
--- a/
sound/soc/codecs/cs42l42.c
+++ b/
sound/soc/codecs/cs42l42.c
@@
-2262,11
+2262,9
@@
static int cs42l42_i2c_probe(struct i2c_client *i2c_client)
NULL, cs42l42_irq_thread,
IRQF_ONESHOT | IRQF_TRIGGER_LOW,
"cs42l42", cs42l42);
- if (ret == -EPROBE_DEFER) {
- goto err_disable_noirq;
- } else if (ret != 0) {
- dev_err(&i2c_client->dev,
- "Failed to request IRQ: %d\n", ret);
+ if (ret) {
+ dev_err_probe(&i2c_client->dev, ret,
+ "Failed to request IRQ\n");
goto err_disable_noirq;
}
}