|
10 | 10 |
|
11 | 11 |
|
12 | 12 | /* entry points for broadcasting system events */
|
13 |
| -void snd_seq_system_broadcast(int client, int port, int type); |
| 13 | +void snd_seq_system_broadcast(int client, int port, int type, bool atomic); |
14 | 14 |
|
15 |
| -#define snd_seq_system_client_ev_client_start(client) snd_seq_system_broadcast(client, 0, SNDRV_SEQ_EVENT_CLIENT_START) |
16 |
| -#define snd_seq_system_client_ev_client_exit(client) snd_seq_system_broadcast(client, 0, SNDRV_SEQ_EVENT_CLIENT_EXIT) |
17 |
| -#define snd_seq_system_client_ev_client_change(client) snd_seq_system_broadcast(client, 0, SNDRV_SEQ_EVENT_CLIENT_CHANGE) |
18 |
| -#define snd_seq_system_client_ev_port_start(client, port) snd_seq_system_broadcast(client, port, SNDRV_SEQ_EVENT_PORT_START) |
19 |
| -#define snd_seq_system_client_ev_port_exit(client, port) snd_seq_system_broadcast(client, port, SNDRV_SEQ_EVENT_PORT_EXIT) |
20 |
| -#define snd_seq_system_client_ev_port_change(client, port) snd_seq_system_broadcast(client, port, SNDRV_SEQ_EVENT_PORT_CHANGE) |
| 15 | +/* normal system notification event broadcast */ |
| 16 | +#define notify_event(client, port, type) \ |
| 17 | + snd_seq_system_broadcast(client, port, type, false) |
21 | 18 |
|
22 |
| -int snd_seq_system_notify(int client, int port, struct snd_seq_event *ev); |
| 19 | +#define snd_seq_system_client_ev_client_start(client) notify_event(client, 0, SNDRV_SEQ_EVENT_CLIENT_START) |
| 20 | +#define snd_seq_system_client_ev_client_exit(client) notify_event(client, 0, SNDRV_SEQ_EVENT_CLIENT_EXIT) |
| 21 | +#define snd_seq_system_client_ev_client_change(client) notify_event(client, 0, SNDRV_SEQ_EVENT_CLIENT_CHANGE) |
| 22 | +#define snd_seq_system_client_ev_port_start(client, port) notify_event(client, port, SNDRV_SEQ_EVENT_PORT_START) |
| 23 | +#define snd_seq_system_client_ev_port_exit(client, port) notify_event(client, port, SNDRV_SEQ_EVENT_PORT_EXIT) |
| 24 | +#define snd_seq_system_client_ev_port_change(client, port) notify_event(client, port, SNDRV_SEQ_EVENT_PORT_CHANGE) |
| 25 | + |
| 26 | +int snd_seq_system_notify(int client, int port, struct snd_seq_event *ev, |
| 27 | + bool atomic); |
23 | 28 |
|
24 | 29 | /* register our internal client */
|
25 | 30 | int snd_seq_system_client_init(void);
|
|
0 commit comments