[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20250407062352.2771861-1-nichen@iscas.ac.cn>
Date: Mon, 7 Apr 2025 14:23:52 +0800
From: Chen Ni <nichen@...as.ac.cn>
To: lgirdwood@...il.com,
broonie@...nel.org,
perex@...ex.cz,
tiwai@...e.com,
shenghao-ding@...com,
colin.i.king@...il.com,
linus.walleij@...aro.org,
afd@...com,
robh@...nel.org,
viro@...iv.linux.org.uk,
gehao@...inos.cn
Cc: linux-sound@...r.kernel.org,
linux-kernel@...r.kernel.org,
Chen Ni <nichen@...as.ac.cn>
Subject: [PATCH] ASoC: pcm6240: Remove unnecessary NULL check before release_firmware()
release_firmware() checks for NULL pointers internally.
Remove unneeded NULL check for fmw here.
Signed-off-by: Chen Ni <nichen@...as.ac.cn>
---
sound/soc/codecs/pcm6240.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/sound/soc/codecs/pcm6240.c b/sound/soc/codecs/pcm6240.c
index b2bd2f172ae7..75af12231d1d 100644
--- a/sound/soc/codecs/pcm6240.c
+++ b/sound/soc/codecs/pcm6240.c
@@ -1642,8 +1642,7 @@ static int pcmdevice_comp_probe(struct snd_soc_component *comp)
}
ret = pcmdev_profile_ctrl_add(pcm_dev);
out:
- if (fw_entry)
- release_firmware(fw_entry);
+ release_firmware(fw_entry);
mutex_unlock(&pcm_dev->codec_lock);
return ret;
--
2.25.1
Powered by blists - more mailing lists