ALSA: control: Keep the previous numid at snd_ctl_rename_id()
authorTakashi Iwai <tiwai@suse.de>
Tue, 6 Jun 2023 09:40:35 +0000 (11:40 +0200)
committerTakashi Iwai <tiwai@suse.de>
Tue, 6 Jun 2023 12:34:30 +0000 (14:34 +0200)
commit306f3f78a5ff578bdfd97c658a862cb2c2419fb6
treedee338eb0f318f33e5ba8110a61e790eca812f90
parentebcbfd846367c980e105c787d372c4239e9ed922
ALSA: control: Keep the previous numid at snd_ctl_rename_id()

We don't need to change the numid at each time snd_ctl_rename_id() is
called, as the control element size itself doesn't change.  Let's keep
the previous numid value.

Along with it, add a note about calling this function only in the
card init phase.

Reviewed-by: Jaroslav Kysela <perex@perex.cz>
Link: https://lore.kernel.org/r/20230606094035.14808-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/core/control.c