diff options
author | 2020-04-27 17:11:45 +0800 | |
---|---|---|
committer | 2020-04-27 14:08:40 +0100 | |
commit | e782ddbb0873d4d96bda890b295130696e0739fc (patch) | |
tree | defe3aaf4f956f2a4427b1bc13de23d2f4f65a16 /sound/soc/hisilicon | |
parent | ASoC: snd-sof-intel-hda-common - add hda_model parameter and pass it to HDA c... (diff) | |
download | linux-e782ddbb0873d4d96bda890b295130696e0739fc.tar.gz linux-e782ddbb0873d4d96bda890b295130696e0739fc.tar.bz2 linux-e782ddbb0873d4d96bda890b295130696e0739fc.zip |
ASoC: hisilicon: Use IS_ERR() instead of IS_ERR_OR_NULL()
In the function hi6210_i2s_probe(), devm_clk_get() doesn't return NULL.
Thus use IS_ERR() to validate the return value instead of IS_ERR_OR_NULL().
Signed-off-by: Zhang Shengju <zhangshengju@cmss.chinamobile.com>
Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com>
Link: https://lore.kernel.org/r/20200427091145.4268-1-tangbin@cmss.chinamobile.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/hisilicon')
-rw-r--r-- | sound/soc/hisilicon/hi6210-i2s.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/hisilicon/hi6210-i2s.c b/sound/soc/hisilicon/hi6210-i2s.c index ab3b76d298b3..f14ce025327a 100644 --- a/sound/soc/hisilicon/hi6210-i2s.c +++ b/sound/soc/hisilicon/hi6210-i2s.c @@ -570,12 +570,12 @@ static int hi6210_i2s_probe(struct platform_device *pdev) return PTR_ERR(i2s->sysctrl); i2s->clk[CLK_DACODEC] = devm_clk_get(&pdev->dev, "dacodec"); - if (IS_ERR_OR_NULL(i2s->clk[CLK_DACODEC])) + if (IS_ERR(i2s->clk[CLK_DACODEC])) return PTR_ERR(i2s->clk[CLK_DACODEC]); i2s->clocks++; i2s->clk[CLK_I2S_BASE] = devm_clk_get(&pdev->dev, "i2s-base"); - if (IS_ERR_OR_NULL(i2s->clk[CLK_I2S_BASE])) + if (IS_ERR(i2s->clk[CLK_I2S_BASE])) return PTR_ERR(i2s->clk[CLK_I2S_BASE]); i2s->clocks++; |