Skip to content

Commit

Permalink
ALSA: seq: ump: Notify port changes to system port
Browse files Browse the repository at this point in the history
For allowing applications to track the FB active changes, this patch
adds the notification from the system port at each time a FB change is
handled and the active flag or re-grouping happens.

Link: https://lore.kernel.org/r/20230612081054.17200-8-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai committed Jun 12, 2023
1 parent 4a16a3a commit 174a6df
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions sound/core/seq/seq_system.c
Original file line number Diff line number Diff line change
@@ -85,6 +85,7 @@ void snd_seq_system_broadcast(int client, int port, int type)
ev.type = type;
snd_seq_kernel_client_dispatch(sysclient, &ev, 0, 0);
}
EXPORT_SYMBOL_GPL(snd_seq_system_broadcast);

/* entry points for broadcasting system events */
int snd_seq_system_notify(int client, int port, struct snd_seq_event *ev)
3 changes: 3 additions & 0 deletions sound/core/seq/seq_ump_client.c
Original file line number Diff line number Diff line change
@@ -13,6 +13,7 @@
#include <sound/seq_kernel.h>
#include <sound/seq_device.h>
#include "seq_clientmgr.h"
#include "seq_system.h"

struct seq_ump_client;
struct seq_ump_group;
@@ -273,6 +274,8 @@ static void update_port_infos(struct seq_ump_client *client)
new);
if (err < 0)
goto error;
/* notify to system port */
snd_seq_system_client_ev_port_change(client->seq_client, i);
}
error:
kfree(new);

0 comments on commit 174a6df

Please sign in to comment.