]> 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:40:36 +0000 (13:40 +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 f91dbc9255f12f3bc50d7dc9b87023295d1ca882..9a5e8c47ce0d2dd5b74667931d63f1a78ac061d7 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)