]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ALSA: usb-audio: Clean up mixer element list traverse
authorTakashi Iwai <tiwai@suse.de>
Thu, 3 May 2018 10:33:32 +0000 (12:33 +0200)
committerSasha Levin <sashal@kernel.org>
Tue, 30 Jun 2020 19:38:41 +0000 (15:38 -0400)
commit380006c7c1e366b3d0aef666ade254e193aa1947
treec635fa79a21837b25cb835d25710e2f28cebc32f
parent65f4bed11018b6538a363bab1a122b77082ab898
ALSA: usb-audio: Clean up mixer element list traverse

[ Upstream commit 8c558076c740e8009a96c6fdc3d4245dde62be77 ]

Introduce a new macro for iterating over mixer element list for
avoiding the open codes in many places.  Also the open-coded
container_of() and the forced cast to struct usb_mixer_elem_info are
replaced with another simple macro, too.

No functional changes but just readability improvement.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/usb/mixer.c
sound/usb/mixer.h
sound/usb/mixer_quirks.c
sound/usb/mixer_scarlett.c