]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
ALSA: usb-audio: Simplify NULL comparison in mixer_quirks
authorCristian Ciocaltea <cristian.ciocaltea@collabora.com>
Mon, 26 May 2025 14:07:46 +0000 (17:07 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 2 Oct 2025 11:35:44 +0000 (13:35 +0200)
[ Upstream commit f2d6d660e8fd5f4467e80743f82119201e67fa9c ]

Handle report from checkpatch.pl:

  CHECK: Comparison to NULL could be written "t->name"

Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Link: https://patch.msgid.link/20250526-dualsense-alsa-jack-v1-7-1a821463b632@collabora.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/usb/mixer_quirks.c

index 715b0922243c1f1880cc47a956178fdfb47c8c7b..9243094cc0637dd82ff98cf34c30651ab2122f97 100644 (file)
@@ -126,7 +126,7 @@ static int snd_create_std_mono_table(struct usb_mixer_interface *mixer,
 {
        int err;
 
-       while (t->name != NULL) {
+       while (t->name) {
                err = snd_create_std_mono_ctl(mixer, t->unitid, t->control,
                                t->cmask, t->val_type, t->name, t->tlv_callback);
                if (err < 0)