]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ALSA: seq: ump: Fix seq port updates per FB info notify
authorTakashi Iwai <tiwai@suse.de>
Thu, 28 Nov 2024 17:04:22 +0000 (18:04 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 14 Dec 2024 19:03:14 +0000 (20:03 +0100)
commit01c3525718e851845dfac4ed542e644355656ce5
tree479988de3cc09b860771174367a33d4300158865
parent5c9e3bb43a354a2245caebbbbb4a5b8c034fdd56
ALSA: seq: ump: Fix seq port updates per FB info notify

[ Upstream commit aaa55faa2495320e44bc643a917c701f2cc89ee7 ]

update_port_infos() is called when a UMP FB Info update notification
is received, and this function is supposed to update the attributes of
the corresponding sequencer port.  However, the function had a few
issues and it brought to the incorrect states.  Namely:

- It tried to get a wrong sequencer info for the update without
  correcting the port number with the group-offset 1
- The loop exited immediately when a sequencer port isn't present;
  this ended up with the truncation if a sequencer port in the middle
  goes away

This patch addresses those bugs.

Fixes: 4a16a3af0571 ("ALSA: seq: ump: Handle FB info update")
Link: https://patch.msgid.link/20241128170423.23351-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/core/seq/seq_ump_client.c