Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: ti: davinci-i2s: remove unnecessary NULL check before clk_disable_unprepare()

clk_disable_unprepare() already checks NULL by using IS_ERR_OR_NULL.
Remove unneeded NULL check for dev->ext_clk here.

Signed-off-by: Chen Ni <nichen@iscas.ac.cn>
Link: https://patch.msgid.link/20250312033509.1235268-1-nichen@iscas.ac.cn
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Chen Ni and committed by
Mark Brown
1458fae1 d9a06936

+2 -4
+2 -4
sound/soc/ti/davinci-i2s.c
··· 892 892 err_unregister_component: 893 893 snd_soc_unregister_component(&pdev->dev); 894 894 err_disable_ext_clk: 895 - if (dev->ext_clk) 896 - clk_disable_unprepare(dev->ext_clk); 895 + clk_disable_unprepare(dev->ext_clk); 897 896 err_disable_clk: 898 897 clk_disable_unprepare(dev->clk); 899 898 ··· 907 908 908 909 clk_disable_unprepare(dev->clk); 909 910 910 - if (dev->ext_clk) 911 - clk_disable_unprepare(dev->ext_clk); 911 + clk_disable_unprepare(dev->ext_clk); 912 912 } 913 913 914 914 static const struct of_device_id davinci_i2s_match[] __maybe_unused = {