mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2026-09-22 09:34:56 +02:00
ALSA: core: use ARRAY_SIZE() in snd_minor_info_read()
Use ARRAY_SIZE(snd_minors) instead of SNDRV_OS_MINORS directly, for consistency with snd_find_free_minor() and snd_unregister_device() in the same file. No functional change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260707074556.569451-1-phucduc.bui@gmail.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
committed by
Takashi Iwai
parent
cd3447e1b6
commit
5171dddf10
+1
-1
@@ -358,7 +358,7 @@ static void snd_minor_info_read(struct snd_info_entry *entry, struct snd_info_bu
|
||||
struct snd_minor *mptr;
|
||||
|
||||
guard(mutex)(&sound_mutex);
|
||||
for (minor = 0; minor < SNDRV_OS_MINORS; ++minor) {
|
||||
for (minor = 0; minor < ARRAY_SIZE(snd_minors); ++minor) {
|
||||
mptr = snd_minors[minor];
|
||||
if (!mptr)
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user