aboutsummaryrefslogtreecommitdiffstats
path: root/include/sound/asequencer.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sound/asequencer.h')
-rw-r--r--include/sound/asequencer.h378
1 files changed, 191 insertions, 187 deletions
diff --git a/include/sound/asequencer.h b/include/sound/asequencer.h
index 728efd504262..6691e4aa4ea7 100644
--- a/include/sound/asequencer.h
+++ b/include/sound/asequencer.h
@@ -22,11 +22,10 @@
22#ifndef __SOUND_ASEQUENCER_H 22#ifndef __SOUND_ASEQUENCER_H
23#define __SOUND_ASEQUENCER_H 23#define __SOUND_ASEQUENCER_H
24 24
25#ifndef __KERNEL__ 25#ifdef __KERNEL__
26#include <linux/ioctl.h> 26#include <linux/ioctl.h>
27#endif
28
29#include <sound/asound.h> 27#include <sound/asound.h>
28#endif
30 29
31/** version of the sequencer */ 30/** version of the sequencer */
32#define SNDRV_SEQ_VERSION SNDRV_PROTOCOL_VERSION (1, 0, 1) 31#define SNDRV_SEQ_VERSION SNDRV_PROTOCOL_VERSION (1, 0, 1)
@@ -36,13 +35,13 @@
36 */ 35 */
37 36
38/** system messages 37/** system messages
39 * event data type = #sndrv_seq_result_t 38 * event data type = #snd_seq_result
40 */ 39 */
41#define SNDRV_SEQ_EVENT_SYSTEM 0 40#define SNDRV_SEQ_EVENT_SYSTEM 0
42#define SNDRV_SEQ_EVENT_RESULT 1 41#define SNDRV_SEQ_EVENT_RESULT 1
43 42
44/** note messages (channel specific) 43/** note messages (channel specific)
45 * event data type = #sndrv_seq_ev_note 44 * event data type = #snd_seq_ev_note
46 */ 45 */
47#define SNDRV_SEQ_EVENT_NOTE 5 46#define SNDRV_SEQ_EVENT_NOTE 5
48#define SNDRV_SEQ_EVENT_NOTEON 6 47#define SNDRV_SEQ_EVENT_NOTEON 6
@@ -50,7 +49,7 @@
50#define SNDRV_SEQ_EVENT_KEYPRESS 8 49#define SNDRV_SEQ_EVENT_KEYPRESS 8
51 50
52/** control messages (channel specific) 51/** control messages (channel specific)
53 * event data type = #sndrv_seq_ev_ctrl 52 * event data type = #snd_seq_ev_ctrl
54 */ 53 */
55#define SNDRV_SEQ_EVENT_CONTROLLER 10 54#define SNDRV_SEQ_EVENT_CONTROLLER 10
56#define SNDRV_SEQ_EVENT_PGMCHANGE 11 55#define SNDRV_SEQ_EVENT_PGMCHANGE 11
@@ -61,7 +60,7 @@
61#define SNDRV_SEQ_EVENT_REGPARAM 16 /**< 14 bit RPN address + 14 bit unsigned value */ 60#define SNDRV_SEQ_EVENT_REGPARAM 16 /**< 14 bit RPN address + 14 bit unsigned value */
62 61
63/** synchronisation messages 62/** synchronisation messages
64 * event data type = #sndrv_seq_ev_ctrl 63 * event data type = #snd_seq_ev_ctrl
65 */ 64 */
66#define SNDRV_SEQ_EVENT_SONGPOS 20 /* Song Position Pointer with LSB and MSB values */ 65#define SNDRV_SEQ_EVENT_SONGPOS 20 /* Song Position Pointer with LSB and MSB values */
67#define SNDRV_SEQ_EVENT_SONGSEL 21 /* Song Select with song ID number */ 66#define SNDRV_SEQ_EVENT_SONGSEL 21 /* Song Select with song ID number */
@@ -70,7 +69,7 @@
70#define SNDRV_SEQ_EVENT_KEYSIGN 24 /* SMF Key Signature event */ 69#define SNDRV_SEQ_EVENT_KEYSIGN 24 /* SMF Key Signature event */
71 70
72/** timer messages 71/** timer messages
73 * event data type = sndrv_seq_ev_queue_control_t 72 * event data type = snd_seq_ev_queue_control
74 */ 73 */
75#define SNDRV_SEQ_EVENT_START 30 /* midi Real Time Start message */ 74#define SNDRV_SEQ_EVENT_START 30 /* midi Real Time Start message */
76#define SNDRV_SEQ_EVENT_CONTINUE 31 /* midi Real Time Continue message */ 75#define SNDRV_SEQ_EVENT_CONTINUE 31 /* midi Real Time Continue message */
@@ -96,7 +95,7 @@
96#define SNDRV_SEQ_EVENT_OSS 51 /* OSS raw event */ 95#define SNDRV_SEQ_EVENT_OSS 51 /* OSS raw event */
97 96
98/** system status messages (broadcast for subscribers) 97/** system status messages (broadcast for subscribers)
99 * event data type = sndrv_seq_addr_t 98 * event data type = snd_seq_addr
100 */ 99 */
101#define SNDRV_SEQ_EVENT_CLIENT_START 60 /* new client has connected */ 100#define SNDRV_SEQ_EVENT_CLIENT_START 60 /* new client has connected */
102#define SNDRV_SEQ_EVENT_CLIENT_EXIT 61 /* client has left the system */ 101#define SNDRV_SEQ_EVENT_CLIENT_EXIT 61 /* client has left the system */
@@ -106,13 +105,13 @@
106#define SNDRV_SEQ_EVENT_PORT_CHANGE 65 /* port status/info has changed */ 105#define SNDRV_SEQ_EVENT_PORT_CHANGE 65 /* port status/info has changed */
107 106
108/** port connection changes 107/** port connection changes
109 * event data type = sndrv_seq_connect_t 108 * event data type = snd_seq_connect
110 */ 109 */
111#define SNDRV_SEQ_EVENT_PORT_SUBSCRIBED 66 /* ports connected */ 110#define SNDRV_SEQ_EVENT_PORT_SUBSCRIBED 66 /* ports connected */
112#define SNDRV_SEQ_EVENT_PORT_UNSUBSCRIBED 67 /* ports disconnected */ 111#define SNDRV_SEQ_EVENT_PORT_UNSUBSCRIBED 67 /* ports disconnected */
113 112
114/** synthesizer events 113/** synthesizer events
115 * event data type = sndrv_seq_eve_sample_control_t 114 * event data type = snd_seq_eve_sample_control
116 */ 115 */
117#define SNDRV_SEQ_EVENT_SAMPLE 70 /* sample select */ 116#define SNDRV_SEQ_EVENT_SAMPLE 70 /* sample select */
118#define SNDRV_SEQ_EVENT_SAMPLE_CLUSTER 71 /* sample cluster select */ 117#define SNDRV_SEQ_EVENT_SAMPLE_CLUSTER 71 /* sample cluster select */
@@ -163,7 +162,7 @@
163/* 119-129: reserved */ 162/* 119-129: reserved */
164 163
165/* 130-139: variable length events 164/* 130-139: variable length events
166 * event data type = sndrv_seq_ev_ext 165 * event data type = snd_seq_ev_ext
167 * (SNDRV_SEQ_EVENT_LENGTH_VARIABLE must be set) 166 * (SNDRV_SEQ_EVENT_LENGTH_VARIABLE must be set)
168 */ 167 */
169#define SNDRV_SEQ_EVENT_SYSEX 130 /* system exclusive data (variable length) */ 168#define SNDRV_SEQ_EVENT_SYSEX 130 /* system exclusive data (variable length) */
@@ -187,18 +186,18 @@
187#define SNDRV_SEQ_EVENT_NONE 255 186#define SNDRV_SEQ_EVENT_NONE 255
188 187
189 188
190typedef unsigned char sndrv_seq_event_type_t; 189typedef unsigned char snd_seq_event_type_t;
191 190
192/** event address */ 191/** event address */
193struct sndrv_seq_addr { 192struct snd_seq_addr {
194 unsigned char client; /**< Client number: 0..255, 255 = broadcast to all clients */ 193 unsigned char client; /**< Client number: 0..255, 255 = broadcast to all clients */
195 unsigned char port; /**< Port within client: 0..255, 255 = broadcast to all ports */ 194 unsigned char port; /**< Port within client: 0..255, 255 = broadcast to all ports */
196}; 195};
197 196
198/** port connection */ 197/** port connection */
199struct sndrv_seq_connect { 198struct snd_seq_connect {
200 struct sndrv_seq_addr sender; 199 struct snd_seq_addr sender;
201 struct sndrv_seq_addr dest; 200 struct snd_seq_addr dest;
202}; 201};
203 202
204 203
@@ -227,7 +226,7 @@ struct sndrv_seq_connect {
227 226
228 227
229 /* note event */ 228 /* note event */
230struct sndrv_seq_ev_note { 229struct snd_seq_ev_note {
231 unsigned char channel; 230 unsigned char channel;
232 unsigned char note; 231 unsigned char note;
233 unsigned char velocity; 232 unsigned char velocity;
@@ -236,7 +235,7 @@ struct sndrv_seq_ev_note {
236}; 235};
237 236
238 /* controller event */ 237 /* controller event */
239struct sndrv_seq_ev_ctrl { 238struct snd_seq_ev_ctrl {
240 unsigned char channel; 239 unsigned char channel;
241 unsigned char unused1, unused2, unused3; /* pad */ 240 unsigned char unused1, unused2, unused3; /* pad */
242 unsigned int param; 241 unsigned int param;
@@ -244,59 +243,59 @@ struct sndrv_seq_ev_ctrl {
244}; 243};
245 244
246 /* generic set of bytes (12x8 bit) */ 245 /* generic set of bytes (12x8 bit) */
247struct sndrv_seq_ev_raw8 { 246struct snd_seq_ev_raw8 {
248 unsigned char d[12]; /* 8 bit value */ 247 unsigned char d[12]; /* 8 bit value */
249}; 248};
250 249
251 /* generic set of integers (3x32 bit) */ 250 /* generic set of integers (3x32 bit) */
252struct sndrv_seq_ev_raw32 { 251struct snd_seq_ev_raw32 {
253 unsigned int d[3]; /* 32 bit value */ 252 unsigned int d[3]; /* 32 bit value */
254}; 253};
255 254
256 /* external stored data */ 255 /* external stored data */
257struct sndrv_seq_ev_ext { 256struct snd_seq_ev_ext {
258 unsigned int len; /* length of data */ 257 unsigned int len; /* length of data */
259 void *ptr; /* pointer to data (note: maybe 64-bit) */ 258 void *ptr; /* pointer to data (note: maybe 64-bit) */
260} __attribute__((packed)); 259} __attribute__((packed));
261 260
262/* Instrument cluster type */ 261/* Instrument cluster type */
263typedef unsigned int sndrv_seq_instr_cluster_t; 262typedef unsigned int snd_seq_instr_cluster_t;
264 263
265/* Instrument type */ 264/* Instrument type */
266struct sndrv_seq_instr { 265struct snd_seq_instr {
267 sndrv_seq_instr_cluster_t cluster; 266 snd_seq_instr_cluster_t cluster;
268 unsigned int std; /* the upper byte means a private instrument (owner - client #) */ 267 unsigned int std; /* the upper byte means a private instrument (owner - client #) */
269 unsigned short bank; 268 unsigned short bank;
270 unsigned short prg; 269 unsigned short prg;
271}; 270};
272 271
273 /* sample number */ 272 /* sample number */
274struct sndrv_seq_ev_sample { 273struct snd_seq_ev_sample {
275 unsigned int std; 274 unsigned int std;
276 unsigned short bank; 275 unsigned short bank;
277 unsigned short prg; 276 unsigned short prg;
278}; 277};
279 278
280 /* sample cluster */ 279 /* sample cluster */
281struct sndrv_seq_ev_cluster { 280struct snd_seq_ev_cluster {
282 sndrv_seq_instr_cluster_t cluster; 281 snd_seq_instr_cluster_t cluster;
283}; 282};
284 283
285 /* sample position */ 284 /* sample position */
286typedef unsigned int sndrv_seq_position_t; /* playback position (in samples) * 16 */ 285typedef unsigned int snd_seq_position_t; /* playback position (in samples) * 16 */
287 286
288 /* sample stop mode */ 287 /* sample stop mode */
289enum sndrv_seq_stop_mode { 288enum {
290 SAMPLE_STOP_IMMEDIATELY = 0, /* terminate playing immediately */ 289 SAMPLE_STOP_IMMEDIATELY = 0, /* terminate playing immediately */
291 SAMPLE_STOP_VENVELOPE = 1, /* finish volume envelope */ 290 SAMPLE_STOP_VENVELOPE = 1, /* finish volume envelope */
292 SAMPLE_STOP_LOOP = 2 /* terminate loop and finish wave */ 291 SAMPLE_STOP_LOOP = 2 /* terminate loop and finish wave */
293}; 292};
294 293
295 /* sample frequency */ 294 /* sample frequency */
296typedef int sndrv_seq_frequency_t; /* playback frequency in HZ * 16 */ 295typedef int snd_seq_frequency_t; /* playback frequency in HZ * 16 */
297 296
298 /* sample volume control; if any value is set to -1 == do not change */ 297 /* sample volume control; if any value is set to -1 == do not change */
299struct sndrv_seq_ev_volume { 298struct snd_seq_ev_volume {
300 signed short volume; /* range: 0-16383 */ 299 signed short volume; /* range: 0-16383 */
301 signed short lr; /* left-right balance; range: 0-16383 */ 300 signed short lr; /* left-right balance; range: 0-16383 */
302 signed short fr; /* front-rear balance; range: 0-16383 */ 301 signed short fr; /* front-rear balance; range: 0-16383 */
@@ -304,22 +303,22 @@ struct sndrv_seq_ev_volume {
304}; 303};
305 304
306 /* simple loop redefinition */ 305 /* simple loop redefinition */
307struct sndrv_seq_ev_loop { 306struct snd_seq_ev_loop {
308 unsigned int start; /* loop start (in samples) * 16 */ 307 unsigned int start; /* loop start (in samples) * 16 */
309 unsigned int end; /* loop end (in samples) * 16 */ 308 unsigned int end; /* loop end (in samples) * 16 */
310}; 309};
311 310
312struct sndrv_seq_ev_sample_control { 311struct snd_seq_ev_sample_control {
313 unsigned char channel; 312 unsigned char channel;
314 unsigned char unused1, unused2, unused3; /* pad */ 313 unsigned char unused1, unused2, unused3; /* pad */
315 union { 314 union {
316 struct sndrv_seq_ev_sample sample; 315 struct snd_seq_ev_sample sample;
317 struct sndrv_seq_ev_cluster cluster; 316 struct snd_seq_ev_cluster cluster;
318 sndrv_seq_position_t position; 317 snd_seq_position_t position;
319 enum sndrv_seq_stop_mode stop_mode; 318 int stop_mode;
320 sndrv_seq_frequency_t frequency; 319 snd_seq_frequency_t frequency;
321 struct sndrv_seq_ev_volume volume; 320 struct snd_seq_ev_volume volume;
322 struct sndrv_seq_ev_loop loop; 321 struct snd_seq_ev_loop loop;
323 unsigned char raw8[8]; 322 unsigned char raw8[8];
324 } param; 323 } param;
325}; 324};
@@ -327,82 +326,82 @@ struct sndrv_seq_ev_sample_control {
327 326
328 327
329/* INSTR_BEGIN event */ 328/* INSTR_BEGIN event */
330struct sndrv_seq_ev_instr_begin { 329struct snd_seq_ev_instr_begin {
331 int timeout; /* zero = forever, otherwise timeout in ms */ 330 int timeout; /* zero = forever, otherwise timeout in ms */
332}; 331};
333 332
334struct sndrv_seq_result { 333struct snd_seq_result {
335 int event; /* processed event type */ 334 int event; /* processed event type */
336 int result; 335 int result;
337}; 336};
338 337
339 338
340struct sndrv_seq_real_time { 339struct snd_seq_real_time {
341 unsigned int tv_sec; /* seconds */ 340 unsigned int tv_sec; /* seconds */
342 unsigned int tv_nsec; /* nanoseconds */ 341 unsigned int tv_nsec; /* nanoseconds */
343}; 342};
344 343
345typedef unsigned int sndrv_seq_tick_time_t; /* midi ticks */ 344typedef unsigned int snd_seq_tick_time_t; /* midi ticks */
346 345
347union sndrv_seq_timestamp { 346union snd_seq_timestamp {
348 sndrv_seq_tick_time_t tick; 347 snd_seq_tick_time_t tick;
349 struct sndrv_seq_real_time time; 348 struct snd_seq_real_time time;
350}; 349};
351 350
352struct sndrv_seq_queue_skew { 351struct snd_seq_queue_skew {
353 unsigned int value; 352 unsigned int value;
354 unsigned int base; 353 unsigned int base;
355}; 354};
356 355
357 /* queue timer control */ 356 /* queue timer control */
358struct sndrv_seq_ev_queue_control { 357struct snd_seq_ev_queue_control {
359 unsigned char queue; /* affected queue */ 358 unsigned char queue; /* affected queue */
360 unsigned char pad[3]; /* reserved */ 359 unsigned char pad[3]; /* reserved */
361 union { 360 union {
362 signed int value; /* affected value (e.g. tempo) */ 361 signed int value; /* affected value (e.g. tempo) */
363 union sndrv_seq_timestamp time; /* time */ 362 union snd_seq_timestamp time; /* time */
364 unsigned int position; /* sync position */ 363 unsigned int position; /* sync position */
365 struct sndrv_seq_queue_skew skew; 364 struct snd_seq_queue_skew skew;
366 unsigned int d32[2]; 365 unsigned int d32[2];
367 unsigned char d8[8]; 366 unsigned char d8[8];
368 } param; 367 } param;
369}; 368};
370 369
371 /* quoted event - inside the kernel only */ 370 /* quoted event - inside the kernel only */
372struct sndrv_seq_ev_quote { 371struct snd_seq_ev_quote {
373 struct sndrv_seq_addr origin; /* original sender */ 372 struct snd_seq_addr origin; /* original sender */
374 unsigned short value; /* optional data */ 373 unsigned short value; /* optional data */
375 struct sndrv_seq_event *event; /* quoted event */ 374 struct snd_seq_event *event; /* quoted event */
376} __attribute__((packed)); 375} __attribute__((packed));
377 376
378 377
379 /* sequencer event */ 378 /* sequencer event */
380struct sndrv_seq_event { 379struct snd_seq_event {
381 sndrv_seq_event_type_t type; /* event type */ 380 snd_seq_event_type_t type; /* event type */
382 unsigned char flags; /* event flags */ 381 unsigned char flags; /* event flags */
383 char tag; 382 char tag;
384 383
385 unsigned char queue; /* schedule queue */ 384 unsigned char queue; /* schedule queue */
386 union sndrv_seq_timestamp time; /* schedule time */ 385 union snd_seq_timestamp time; /* schedule time */
387 386
388 387
389 struct sndrv_seq_addr source; /* source address */ 388 struct snd_seq_addr source; /* source address */
390 struct sndrv_seq_addr dest; /* destination address */ 389 struct snd_seq_addr dest; /* destination address */
391 390
392 union { /* event data... */ 391 union { /* event data... */
393 struct sndrv_seq_ev_note note; 392 struct snd_seq_ev_note note;
394 struct sndrv_seq_ev_ctrl control; 393 struct snd_seq_ev_ctrl control;
395 struct sndrv_seq_ev_raw8 raw8; 394 struct snd_seq_ev_raw8 raw8;
396 struct sndrv_seq_ev_raw32 raw32; 395 struct snd_seq_ev_raw32 raw32;
397 struct sndrv_seq_ev_ext ext; 396 struct snd_seq_ev_ext ext;
398 struct sndrv_seq_ev_queue_control queue; 397 struct snd_seq_ev_queue_control queue;
399 union sndrv_seq_timestamp time; 398 union snd_seq_timestamp time;
400 struct sndrv_seq_addr addr; 399 struct snd_seq_addr addr;
401 struct sndrv_seq_connect connect; 400 struct snd_seq_connect connect;
402 struct sndrv_seq_result result; 401 struct snd_seq_result result;
403 struct sndrv_seq_ev_instr_begin instr_begin; 402 struct snd_seq_ev_instr_begin instr_begin;
404 struct sndrv_seq_ev_sample_control sample; 403 struct snd_seq_ev_sample_control sample;
405 struct sndrv_seq_ev_quote quote; 404 struct snd_seq_ev_quote quote;
406 } data; 405 } data;
407}; 406};
408 407
@@ -410,72 +409,77 @@ struct sndrv_seq_event {
410/* 409/*
411 * bounce event - stored as variable size data 410 * bounce event - stored as variable size data
412 */ 411 */
413struct sndrv_seq_event_bounce { 412struct snd_seq_event_bounce {
414 int err; 413 int err;
415 struct sndrv_seq_event event; 414 struct snd_seq_event event;
416 /* external data follows here. */ 415 /* external data follows here. */
417}; 416};
418 417
419#define sndrv_seq_event_bounce_ext_data(ev) ((void*)((char *)(ev)->data.ext.ptr + sizeof(sndrv_seq_event_bounce_t))) 418#ifdef __KERNEL__
419
420/* helper macro */
421#define snd_seq_event_bounce_ext_data(ev) ((void*)((char *)(ev)->data.ext.ptr + sizeof(struct snd_seq_event_bounce)))
420 422
421/* 423/*
422 * type check macros 424 * type check macros
423 */ 425 */
424/* result events: 0-4 */ 426/* result events: 0-4 */
425#define sndrv_seq_ev_is_result_type(ev) ((ev)->type < 5) 427#define snd_seq_ev_is_result_type(ev) ((ev)->type < 5)
426/* channel specific events: 5-19 */ 428/* channel specific events: 5-19 */
427#define sndrv_seq_ev_is_channel_type(ev) ((ev)->type >= 5 && (ev)->type < 20) 429#define snd_seq_ev_is_channel_type(ev) ((ev)->type >= 5 && (ev)->type < 20)
428/* note events: 5-9 */ 430/* note events: 5-9 */
429#define sndrv_seq_ev_is_note_type(ev) ((ev)->type >= 5 && (ev)->type < 10) 431#define snd_seq_ev_is_note_type(ev) ((ev)->type >= 5 && (ev)->type < 10)
430/* control events: 10-19 */ 432/* control events: 10-19 */
431#define sndrv_seq_ev_is_control_type(ev) ((ev)->type >= 10 && (ev)->type < 20) 433#define snd_seq_ev_is_control_type(ev) ((ev)->type >= 10 && (ev)->type < 20)
432/* queue control events: 30-39 */ 434/* queue control events: 30-39 */
433#define sndrv_seq_ev_is_queue_type(ev) ((ev)->type >= 30 && (ev)->type < 40) 435#define snd_seq_ev_is_queue_type(ev) ((ev)->type >= 30 && (ev)->type < 40)
434/* system status messages */ 436/* system status messages */
435#define sndrv_seq_ev_is_message_type(ev) ((ev)->type >= 60 && (ev)->type < 69) 437#define snd_seq_ev_is_message_type(ev) ((ev)->type >= 60 && (ev)->type < 69)
436/* sample messages */ 438/* sample messages */
437#define sndrv_seq_ev_is_sample_type(ev) ((ev)->type >= 70 && (ev)->type < 79) 439#define snd_seq_ev_is_sample_type(ev) ((ev)->type >= 70 && (ev)->type < 79)
438/* user-defined messages */ 440/* user-defined messages */
439#define sndrv_seq_ev_is_user_type(ev) ((ev)->type >= 90 && (ev)->type < 99) 441#define snd_seq_ev_is_user_type(ev) ((ev)->type >= 90 && (ev)->type < 99)
440/* fixed length events: 0-99 */ 442/* fixed length events: 0-99 */
441#define sndrv_seq_ev_is_fixed_type(ev) ((ev)->type < 100) 443#define snd_seq_ev_is_fixed_type(ev) ((ev)->type < 100)
442/* instrument layer events: 100-129 */ 444/* instrument layer events: 100-129 */
443#define sndrv_seq_ev_is_instr_type(ev) ((ev)->type >= 100 && (ev)->type < 130) 445#define snd_seq_ev_is_instr_type(ev) ((ev)->type >= 100 && (ev)->type < 130)
444/* variable length events: 130-139 */ 446/* variable length events: 130-139 */
445#define sndrv_seq_ev_is_variable_type(ev) ((ev)->type >= 130 && (ev)->type < 140) 447#define snd_seq_ev_is_variable_type(ev) ((ev)->type >= 130 && (ev)->type < 140)
446/* reserved for kernel */ 448/* reserved for kernel */
447#define sndrv_seq_ev_is_reserved(ev) ((ev)->type >= 150) 449#define snd_seq_ev_is_reserved(ev) ((ev)->type >= 150)
448 450
449/* direct dispatched events */ 451/* direct dispatched events */
450#define sndrv_seq_ev_is_direct(ev) ((ev)->queue == SNDRV_SEQ_QUEUE_DIRECT) 452#define snd_seq_ev_is_direct(ev) ((ev)->queue == SNDRV_SEQ_QUEUE_DIRECT)
451 453
452/* 454/*
453 * macros to check event flags 455 * macros to check event flags
454 */ 456 */
455/* prior events */ 457/* prior events */
456#define sndrv_seq_ev_is_prior(ev) (((ev)->flags & SNDRV_SEQ_PRIORITY_MASK) == SNDRV_SEQ_PRIORITY_HIGH) 458#define snd_seq_ev_is_prior(ev) (((ev)->flags & SNDRV_SEQ_PRIORITY_MASK) == SNDRV_SEQ_PRIORITY_HIGH)
457 459
458/* event length type */ 460/* event length type */
459#define sndrv_seq_ev_length_type(ev) ((ev)->flags & SNDRV_SEQ_EVENT_LENGTH_MASK) 461#define snd_seq_ev_length_type(ev) ((ev)->flags & SNDRV_SEQ_EVENT_LENGTH_MASK)
460#define sndrv_seq_ev_is_fixed(ev) (sndrv_seq_ev_length_type(ev) == SNDRV_SEQ_EVENT_LENGTH_FIXED) 462#define snd_seq_ev_is_fixed(ev) (snd_seq_ev_length_type(ev) == SNDRV_SEQ_EVENT_LENGTH_FIXED)
461#define sndrv_seq_ev_is_variable(ev) (sndrv_seq_ev_length_type(ev) == SNDRV_SEQ_EVENT_LENGTH_VARIABLE) 463#define snd_seq_ev_is_variable(ev) (snd_seq_ev_length_type(ev) == SNDRV_SEQ_EVENT_LENGTH_VARIABLE)
462#define sndrv_seq_ev_is_varusr(ev) (sndrv_seq_ev_length_type(ev) == SNDRV_SEQ_EVENT_LENGTH_VARUSR) 464#define snd_seq_ev_is_varusr(ev) (snd_seq_ev_length_type(ev) == SNDRV_SEQ_EVENT_LENGTH_VARUSR)
463 465
464/* time-stamp type */ 466/* time-stamp type */
465#define sndrv_seq_ev_timestamp_type(ev) ((ev)->flags & SNDRV_SEQ_TIME_STAMP_MASK) 467#define snd_seq_ev_timestamp_type(ev) ((ev)->flags & SNDRV_SEQ_TIME_STAMP_MASK)
466#define sndrv_seq_ev_is_tick(ev) (sndrv_seq_ev_timestamp_type(ev) == SNDRV_SEQ_TIME_STAMP_TICK) 468#define snd_seq_ev_is_tick(ev) (snd_seq_ev_timestamp_type(ev) == SNDRV_SEQ_TIME_STAMP_TICK)
467#define sndrv_seq_ev_is_real(ev) (sndrv_seq_ev_timestamp_type(ev) == SNDRV_SEQ_TIME_STAMP_REAL) 469#define snd_seq_ev_is_real(ev) (snd_seq_ev_timestamp_type(ev) == SNDRV_SEQ_TIME_STAMP_REAL)
468 470
469/* time-mode type */ 471/* time-mode type */
470#define sndrv_seq_ev_timemode_type(ev) ((ev)->flags & SNDRV_SEQ_TIME_MODE_MASK) 472#define snd_seq_ev_timemode_type(ev) ((ev)->flags & SNDRV_SEQ_TIME_MODE_MASK)
471#define sndrv_seq_ev_is_abstime(ev) (sndrv_seq_ev_timemode_type(ev) == SNDRV_SEQ_TIME_MODE_ABS) 473#define snd_seq_ev_is_abstime(ev) (snd_seq_ev_timemode_type(ev) == SNDRV_SEQ_TIME_MODE_ABS)
472#define sndrv_seq_ev_is_reltime(ev) (sndrv_seq_ev_timemode_type(ev) == SNDRV_SEQ_TIME_MODE_REL) 474#define snd_seq_ev_is_reltime(ev) (snd_seq_ev_timemode_type(ev) == SNDRV_SEQ_TIME_MODE_REL)
473 475
474/* queue sync port */ 476/* queue sync port */
475#define sndrv_seq_queue_sync_port(q) ((q) + 16) 477#define snd_seq_queue_sync_port(q) ((q) + 16)
478
479#endif /* __KERNEL__ */
476 480
477 /* system information */ 481 /* system information */
478struct sndrv_seq_system_info { 482struct snd_seq_system_info {
479 int queues; /* maximum queues count */ 483 int queues; /* maximum queues count */
480 int clients; /* maximum clients count */ 484 int clients; /* maximum clients count */
481 int ports; /* maximum ports per client */ 485 int ports; /* maximum ports per client */
@@ -487,7 +491,7 @@ struct sndrv_seq_system_info {
487 491
488 492
489 /* system running information */ 493 /* system running information */
490struct sndrv_seq_running_info { 494struct snd_seq_running_info {
491 unsigned char client; /* client id */ 495 unsigned char client; /* client id */
492 unsigned char big_endian; /* 1 = big-endian */ 496 unsigned char big_endian; /* 1 = big-endian */
493 unsigned char cpu_mode; /* 4 = 32bit, 8 = 64bit */ 497 unsigned char cpu_mode; /* 4 = 32bit, 8 = 64bit */
@@ -498,16 +502,16 @@ struct sndrv_seq_running_info {
498 502
499 /* known client numbers */ 503 /* known client numbers */
500#define SNDRV_SEQ_CLIENT_SYSTEM 0 504#define SNDRV_SEQ_CLIENT_SYSTEM 0
501#define SNDRV_SEQ_CLIENT_DUMMY 62 /* dummy ports */ 505 /* internal client numbers */
502#define SNDRV_SEQ_CLIENT_OSS 63 /* oss sequencer emulator */ 506#define SNDRV_SEQ_CLIENT_DUMMY 14 /* midi through */
507#define SNDRV_SEQ_CLIENT_OSS 15 /* oss sequencer emulator */
503 508
504 509
505 /* client types */ 510 /* client types */
506enum sndrv_seq_client_type { 511typedef int __bitwise snd_seq_client_type_t;
507 NO_CLIENT = 0, 512#define NO_CLIENT ((__force snd_seq_client_type_t) 0)
508 USER_CLIENT = 1, 513#define USER_CLIENT ((__force snd_seq_client_type_t) 1)
509 KERNEL_CLIENT = 2 514#define KERNEL_CLIENT ((__force snd_seq_client_type_t) 2)
510};
511 515
512 /* event filter flags */ 516 /* event filter flags */
513#define SNDRV_SEQ_FILTER_BROADCAST (1<<0) /* accept broadcast messages */ 517#define SNDRV_SEQ_FILTER_BROADCAST (1<<0) /* accept broadcast messages */
@@ -515,9 +519,9 @@ enum sndrv_seq_client_type {
515#define SNDRV_SEQ_FILTER_BOUNCE (1<<2) /* accept bounce event in error */ 519#define SNDRV_SEQ_FILTER_BOUNCE (1<<2) /* accept bounce event in error */
516#define SNDRV_SEQ_FILTER_USE_EVENT (1<<31) /* use event filter */ 520#define SNDRV_SEQ_FILTER_USE_EVENT (1<<31) /* use event filter */
517 521
518struct sndrv_seq_client_info { 522struct snd_seq_client_info {
519 int client; /* client number to inquire */ 523 int client; /* client number to inquire */
520 enum sndrv_seq_client_type type; /* client type */ 524 snd_seq_client_type_t type; /* client type */
521 char name[64]; /* client name */ 525 char name[64]; /* client name */
522 unsigned int filter; /* filter flags */ 526 unsigned int filter; /* filter flags */
523 unsigned char multicast_filter[8]; /* multicast filter bitmap */ 527 unsigned char multicast_filter[8]; /* multicast filter bitmap */
@@ -529,7 +533,7 @@ struct sndrv_seq_client_info {
529 533
530 534
531/* client pool size */ 535/* client pool size */
532struct sndrv_seq_client_pool { 536struct snd_seq_client_pool {
533 int client; /* client number to inquire */ 537 int client; /* client number to inquire */
534 int output_pool; /* outgoing (write) pool size */ 538 int output_pool; /* outgoing (write) pool size */
535 int input_pool; /* incoming (read) pool size */ 539 int input_pool; /* incoming (read) pool size */
@@ -553,13 +557,13 @@ struct sndrv_seq_client_pool {
553#define SNDRV_SEQ_REMOVE_IGNORE_OFF (1<<8) /* Do not flush off events */ 557#define SNDRV_SEQ_REMOVE_IGNORE_OFF (1<<8) /* Do not flush off events */
554#define SNDRV_SEQ_REMOVE_TAG_MATCH (1<<9) /* Restrict to events with given tag */ 558#define SNDRV_SEQ_REMOVE_TAG_MATCH (1<<9) /* Restrict to events with given tag */
555 559
556struct sndrv_seq_remove_events { 560struct snd_seq_remove_events {
557 unsigned int remove_mode; /* Flags that determine what gets removed */ 561 unsigned int remove_mode; /* Flags that determine what gets removed */
558 562
559 union sndrv_seq_timestamp time; 563 union snd_seq_timestamp time;
560 564
561 unsigned char queue; /* Queue for REMOVE_DEST */ 565 unsigned char queue; /* Queue for REMOVE_DEST */
562 struct sndrv_seq_addr dest; /* Address for REMOVE_DEST */ 566 struct snd_seq_addr dest; /* Address for REMOVE_DEST */
563 unsigned char channel; /* Channel for REMOVE_DEST */ 567 unsigned char channel; /* Channel for REMOVE_DEST */
564 568
565 int type; /* For REMOVE_EVENT_TYPE */ 569 int type; /* For REMOVE_EVENT_TYPE */
@@ -608,8 +612,8 @@ struct sndrv_seq_remove_events {
608#define SNDRV_SEQ_PORT_FLG_TIMESTAMP (1<<1) 612#define SNDRV_SEQ_PORT_FLG_TIMESTAMP (1<<1)
609#define SNDRV_SEQ_PORT_FLG_TIME_REAL (1<<2) 613#define SNDRV_SEQ_PORT_FLG_TIME_REAL (1<<2)
610 614
611struct sndrv_seq_port_info { 615struct snd_seq_port_info {
612 struct sndrv_seq_addr addr; /* client/port numbers */ 616 struct snd_seq_addr addr; /* client/port numbers */
613 char name[64]; /* port name */ 617 char name[64]; /* port name */
614 618
615 unsigned int capability; /* port capability bits */ 619 unsigned int capability; /* port capability bits */
@@ -632,7 +636,7 @@ struct sndrv_seq_port_info {
632#define SNDRV_SEQ_QUEUE_FLG_SYNC (1<<0) /* sync enabled */ 636#define SNDRV_SEQ_QUEUE_FLG_SYNC (1<<0) /* sync enabled */
633 637
634/* queue information */ 638/* queue information */
635struct sndrv_seq_queue_info { 639struct snd_seq_queue_info {
636 int queue; /* queue id */ 640 int queue; /* queue id */
637 641
638 /* 642 /*
@@ -648,11 +652,11 @@ struct sndrv_seq_queue_info {
648}; 652};
649 653
650/* queue info/status */ 654/* queue info/status */
651struct sndrv_seq_queue_status { 655struct snd_seq_queue_status {
652 int queue; /* queue id */ 656 int queue; /* queue id */
653 int events; /* read-only - queue size */ 657 int events; /* read-only - queue size */
654 sndrv_seq_tick_time_t tick; /* current tick */ 658 snd_seq_tick_time_t tick; /* current tick */
655 struct sndrv_seq_real_time time; /* current time */ 659 struct snd_seq_real_time time; /* current time */
656 int running; /* running state of queue */ 660 int running; /* running state of queue */
657 int flags; /* various flags */ 661 int flags; /* various flags */
658 char reserved[64]; /* for the future */ 662 char reserved[64]; /* for the future */
@@ -660,7 +664,7 @@ struct sndrv_seq_queue_status {
660 664
661 665
662/* queue tempo */ 666/* queue tempo */
663struct sndrv_seq_queue_tempo { 667struct snd_seq_queue_tempo {
664 int queue; /* sequencer queue */ 668 int queue; /* sequencer queue */
665 unsigned int tempo; /* current tempo, us/tick */ 669 unsigned int tempo; /* current tempo, us/tick */
666 int ppq; /* time resolution, ticks/quarter */ 670 int ppq; /* time resolution, ticks/quarter */
@@ -676,12 +680,12 @@ struct sndrv_seq_queue_tempo {
676#define SNDRV_SEQ_TIMER_MIDI_TICK 2 /* Midi Timer Tick (TICK event) */ 680#define SNDRV_SEQ_TIMER_MIDI_TICK 2 /* Midi Timer Tick (TICK event) */
677 681
678/* queue timer info */ 682/* queue timer info */
679struct sndrv_seq_queue_timer { 683struct snd_seq_queue_timer {
680 int queue; /* sequencer queue */ 684 int queue; /* sequencer queue */
681 int type; /* source timer type */ 685 int type; /* source timer type */
682 union { 686 union {
683 struct { 687 struct {
684 struct sndrv_timer_id id; /* ALSA's timer ID */ 688 struct snd_timer_id id; /* ALSA's timer ID */
685 unsigned int resolution; /* resolution in Hz */ 689 unsigned int resolution; /* resolution in Hz */
686 } alsa; 690 } alsa;
687 } u; 691 } u;
@@ -689,7 +693,7 @@ struct sndrv_seq_queue_timer {
689}; 693};
690 694
691 695
692struct sndrv_seq_queue_client { 696struct snd_seq_queue_client {
693 int queue; /* sequencer queue */ 697 int queue; /* sequencer queue */
694 int client; /* sequencer client */ 698 int client; /* sequencer client */
695 int used; /* queue is used with this client 699 int used; /* queue is used with this client
@@ -703,9 +707,9 @@ struct sndrv_seq_queue_client {
703#define SNDRV_SEQ_PORT_SUBS_TIMESTAMP (1<<1) 707#define SNDRV_SEQ_PORT_SUBS_TIMESTAMP (1<<1)
704#define SNDRV_SEQ_PORT_SUBS_TIME_REAL (1<<2) 708#define SNDRV_SEQ_PORT_SUBS_TIME_REAL (1<<2)
705 709
706struct sndrv_seq_port_subscribe { 710struct snd_seq_port_subscribe {
707 struct sndrv_seq_addr sender; /* sender address */ 711 struct snd_seq_addr sender; /* sender address */
708 struct sndrv_seq_addr dest; /* destination address */ 712 struct snd_seq_addr dest; /* destination address */
709 unsigned int voices; /* number of voices to be allocated (0 = don't care) */ 713 unsigned int voices; /* number of voices to be allocated (0 = don't care) */
710 unsigned int flags; /* modes */ 714 unsigned int flags; /* modes */
711 unsigned char queue; /* input time-stamp queue (optional) */ 715 unsigned char queue; /* input time-stamp queue (optional) */
@@ -717,12 +721,12 @@ struct sndrv_seq_port_subscribe {
717#define SNDRV_SEQ_QUERY_SUBS_READ 0 721#define SNDRV_SEQ_QUERY_SUBS_READ 0
718#define SNDRV_SEQ_QUERY_SUBS_WRITE 1 722#define SNDRV_SEQ_QUERY_SUBS_WRITE 1
719 723
720struct sndrv_seq_query_subs { 724struct snd_seq_query_subs {
721 struct sndrv_seq_addr root; /* client/port id to be searched */ 725 struct snd_seq_addr root; /* client/port id to be searched */
722 int type; /* READ or WRITE */ 726 int type; /* READ or WRITE */
723 int index; /* 0..N-1 */ 727 int index; /* 0..N-1 */
724 int num_subs; /* R/O: number of subscriptions on this port */ 728 int num_subs; /* R/O: number of subscriptions on this port */
725 struct sndrv_seq_addr addr; /* R/O: result */ 729 struct snd_seq_addr addr; /* R/O: result */
726 unsigned char queue; /* R/O: result */ 730 unsigned char queue; /* R/O: result */
727 unsigned int flags; /* R/O: result */ 731 unsigned int flags; /* R/O: result */
728 char reserved[64]; /* for future use */ 732 char reserved[64]; /* for future use */
@@ -779,72 +783,72 @@ struct sndrv_seq_query_subs {
779#define SNDRV_SEQ_INSTR_FREE_CMD_SINGLE 3 783#define SNDRV_SEQ_INSTR_FREE_CMD_SINGLE 3
780 784
781/* size of ROM/RAM */ 785/* size of ROM/RAM */
782typedef unsigned int sndrv_seq_instr_size_t; 786typedef unsigned int snd_seq_instr_size_t;
783 787
784/* INSTR_INFO */ 788/* INSTR_INFO */
785 789
786struct sndrv_seq_instr_info { 790struct snd_seq_instr_info {
787 int result; /* operation result */ 791 int result; /* operation result */
788 unsigned int formats[8]; /* bitmap of supported formats */ 792 unsigned int formats[8]; /* bitmap of supported formats */
789 int ram_count; /* count of RAM banks */ 793 int ram_count; /* count of RAM banks */
790 sndrv_seq_instr_size_t ram_sizes[16]; /* size of RAM banks */ 794 snd_seq_instr_size_t ram_sizes[16]; /* size of RAM banks */
791 int rom_count; /* count of ROM banks */ 795 int rom_count; /* count of ROM banks */
792 sndrv_seq_instr_size_t rom_sizes[8]; /* size of ROM banks */ 796 snd_seq_instr_size_t rom_sizes[8]; /* size of ROM banks */
793 char reserved[128]; 797 char reserved[128];
794}; 798};
795 799
796/* INSTR_STATUS */ 800/* INSTR_STATUS */
797 801
798struct sndrv_seq_instr_status { 802struct snd_seq_instr_status {
799 int result; /* operation result */ 803 int result; /* operation result */
800 sndrv_seq_instr_size_t free_ram[16]; /* free RAM in banks */ 804 snd_seq_instr_size_t free_ram[16]; /* free RAM in banks */
801 int instrument_count; /* count of downloaded instruments */ 805 int instrument_count; /* count of downloaded instruments */
802 char reserved[128]; 806 char reserved[128];
803}; 807};
804 808
805/* INSTR_FORMAT_INFO */ 809/* INSTR_FORMAT_INFO */
806 810
807struct sndrv_seq_instr_format_info { 811struct snd_seq_instr_format_info {
808 char format[16]; /* format identifier - SNDRV_SEQ_INSTR_ID_* */ 812 char format[16]; /* format identifier - SNDRV_SEQ_INSTR_ID_* */
809 unsigned int len; /* max data length (without this structure) */ 813 unsigned int len; /* max data length (without this structure) */
810}; 814};
811 815
812struct sndrv_seq_instr_format_info_result { 816struct snd_seq_instr_format_info_result {
813 int result; /* operation result */ 817 int result; /* operation result */
814 char format[16]; /* format identifier */ 818 char format[16]; /* format identifier */
815 unsigned int len; /* filled data length (without this structure) */ 819 unsigned int len; /* filled data length (without this structure) */
816}; 820};
817 821
818/* instrument data */ 822/* instrument data */
819struct sndrv_seq_instr_data { 823struct snd_seq_instr_data {
820 char name[32]; /* instrument name */ 824 char name[32]; /* instrument name */
821 char reserved[16]; /* for the future use */ 825 char reserved[16]; /* for the future use */
822 int type; /* instrument type */ 826 int type; /* instrument type */
823 union { 827 union {
824 char format[16]; /* format identifier */ 828 char format[16]; /* format identifier */
825 struct sndrv_seq_instr alias; 829 struct snd_seq_instr alias;
826 } data; 830 } data;
827}; 831};
828 832
829/* INSTR_PUT/GET, data are stored in one block (extended), header + data */ 833/* INSTR_PUT/GET, data are stored in one block (extended), header + data */
830 834
831struct sndrv_seq_instr_header { 835struct snd_seq_instr_header {
832 union { 836 union {
833 struct sndrv_seq_instr instr; 837 struct snd_seq_instr instr;
834 sndrv_seq_instr_cluster_t cluster; 838 snd_seq_instr_cluster_t cluster;
835 } id; /* instrument identifier */ 839 } id; /* instrument identifier */
836 unsigned int cmd; /* get/put/free command */ 840 unsigned int cmd; /* get/put/free command */
837 unsigned int flags; /* query flags (only for get) */ 841 unsigned int flags; /* query flags (only for get) */
838 unsigned int len; /* real instrument data length (without header) */ 842 unsigned int len; /* real instrument data length (without header) */
839 int result; /* operation result */ 843 int result; /* operation result */
840 char reserved[16]; /* for the future */ 844 char reserved[16]; /* for the future */
841 struct sndrv_seq_instr_data data; /* instrument data (for put/get result) */ 845 struct snd_seq_instr_data data; /* instrument data (for put/get result) */
842}; 846};
843 847
844/* INSTR_CLUSTER_SET */ 848/* INSTR_CLUSTER_SET */
845 849
846struct sndrv_seq_instr_cluster_set { 850struct snd_seq_instr_cluster_set {
847 sndrv_seq_instr_cluster_t cluster; /* cluster identifier */ 851 snd_seq_instr_cluster_t cluster; /* cluster identifier */
848 char name[32]; /* cluster name */ 852 char name[32]; /* cluster name */
849 int priority; /* cluster priority */ 853 int priority; /* cluster priority */
850 char reserved[64]; /* for the future use */ 854 char reserved[64]; /* for the future use */
@@ -852,8 +856,8 @@ struct sndrv_seq_instr_cluster_set {
852 856
853/* INSTR_CLUSTER_GET */ 857/* INSTR_CLUSTER_GET */
854 858
855struct sndrv_seq_instr_cluster_get { 859struct snd_seq_instr_cluster_get {
856 sndrv_seq_instr_cluster_t cluster; /* cluster identifier */ 860 snd_seq_instr_cluster_t cluster; /* cluster identifier */
857 char name[32]; /* cluster name */ 861 char name[32]; /* cluster name */
858 int priority; /* cluster priority */ 862 int priority; /* cluster priority */
859 char reserved[64]; /* for the future use */ 863 char reserved[64]; /* for the future use */
@@ -865,44 +869,44 @@ struct sndrv_seq_instr_cluster_get {
865 869
866#define SNDRV_SEQ_IOCTL_PVERSION _IOR ('S', 0x00, int) 870#define SNDRV_SEQ_IOCTL_PVERSION _IOR ('S', 0x00, int)
867#define SNDRV_SEQ_IOCTL_CLIENT_ID _IOR ('S', 0x01, int) 871#define SNDRV_SEQ_IOCTL_CLIENT_ID _IOR ('S', 0x01, int)
868#define SNDRV_SEQ_IOCTL_SYSTEM_INFO _IOWR('S', 0x02, struct sndrv_seq_system_info) 872#define SNDRV_SEQ_IOCTL_SYSTEM_INFO _IOWR('S', 0x02, struct snd_seq_system_info)
869#define SNDRV_SEQ_IOCTL_RUNNING_MODE _IOWR('S', 0x03, struct sndrv_seq_running_info) 873#define SNDRV_SEQ_IOCTL_RUNNING_MODE _IOWR('S', 0x03, struct snd_seq_running_info)
870 874
871#define SNDRV_SEQ_IOCTL_GET_CLIENT_INFO _IOWR('S', 0x10, struct sndrv_seq_client_info) 875#define SNDRV_SEQ_IOCTL_GET_CLIENT_INFO _IOWR('S', 0x10, struct snd_seq_client_info)
872#define SNDRV_SEQ_IOCTL_SET_CLIENT_INFO _IOW ('S', 0x11, struct sndrv_seq_client_info) 876#define SNDRV_SEQ_IOCTL_SET_CLIENT_INFO _IOW ('S', 0x11, struct snd_seq_client_info)
873 877
874#define SNDRV_SEQ_IOCTL_CREATE_PORT _IOWR('S', 0x20, struct sndrv_seq_port_info) 878#define SNDRV_SEQ_IOCTL_CREATE_PORT _IOWR('S', 0x20, struct snd_seq_port_info)
875#define SNDRV_SEQ_IOCTL_DELETE_PORT _IOW ('S', 0x21, struct sndrv_seq_port_info) 879#define SNDRV_SEQ_IOCTL_DELETE_PORT _IOW ('S', 0x21, struct snd_seq_port_info)
876#define SNDRV_SEQ_IOCTL_GET_PORT_INFO _IOWR('S', 0x22, struct sndrv_seq_port_info) 880#define SNDRV_SEQ_IOCTL_GET_PORT_INFO _IOWR('S', 0x22, struct snd_seq_port_info)
877#define SNDRV_SEQ_IOCTL_SET_PORT_INFO _IOW ('S', 0x23, struct sndrv_seq_port_info) 881#define SNDRV_SEQ_IOCTL_SET_PORT_INFO _IOW ('S', 0x23, struct snd_seq_port_info)
878 882
879#define SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT _IOW ('S', 0x30, struct sndrv_seq_port_subscribe) 883#define SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT _IOW ('S', 0x30, struct snd_seq_port_subscribe)
880#define SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT _IOW ('S', 0x31, struct sndrv_seq_port_subscribe) 884#define SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT _IOW ('S', 0x31, struct snd_seq_port_subscribe)
881 885
882#define SNDRV_SEQ_IOCTL_CREATE_QUEUE _IOWR('S', 0x32, struct sndrv_seq_queue_info) 886#define SNDRV_SEQ_IOCTL_CREATE_QUEUE _IOWR('S', 0x32, struct snd_seq_queue_info)
883#define SNDRV_SEQ_IOCTL_DELETE_QUEUE _IOW ('S', 0x33, struct sndrv_seq_queue_info) 887#define SNDRV_SEQ_IOCTL_DELETE_QUEUE _IOW ('S', 0x33, struct snd_seq_queue_info)
884#define SNDRV_SEQ_IOCTL_GET_QUEUE_INFO _IOWR('S', 0x34, struct sndrv_seq_queue_info) 888#define SNDRV_SEQ_IOCTL_GET_QUEUE_INFO _IOWR('S', 0x34, struct snd_seq_queue_info)
885#define SNDRV_SEQ_IOCTL_SET_QUEUE_INFO _IOWR('S', 0x35, struct sndrv_seq_queue_info) 889#define SNDRV_SEQ_IOCTL_SET_QUEUE_INFO _IOWR('S', 0x35, struct snd_seq_queue_info)
886#define SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE _IOWR('S', 0x36, struct sndrv_seq_queue_info) 890#define SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE _IOWR('S', 0x36, struct snd_seq_queue_info)
887#define SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS _IOWR('S', 0x40, struct sndrv_seq_queue_status) 891#define SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS _IOWR('S', 0x40, struct snd_seq_queue_status)
888#define SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO _IOWR('S', 0x41, struct sndrv_seq_queue_tempo) 892#define SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO _IOWR('S', 0x41, struct snd_seq_queue_tempo)
889#define SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO _IOW ('S', 0x42, struct sndrv_seq_queue_tempo) 893#define SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO _IOW ('S', 0x42, struct snd_seq_queue_tempo)
890#define SNDRV_SEQ_IOCTL_GET_QUEUE_OWNER _IOWR('S', 0x43, struct sndrv_seq_queue_owner) 894#define SNDRV_SEQ_IOCTL_GET_QUEUE_OWNER _IOWR('S', 0x43, struct snd_seq_queue_owner)
891#define SNDRV_SEQ_IOCTL_SET_QUEUE_OWNER _IOW ('S', 0x44, struct sndrv_seq_queue_owner) 895#define SNDRV_SEQ_IOCTL_SET_QUEUE_OWNER _IOW ('S', 0x44, struct snd_seq_queue_owner)
892#define SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER _IOWR('S', 0x45, struct sndrv_seq_queue_timer) 896#define SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER _IOWR('S', 0x45, struct snd_seq_queue_timer)
893#define SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER _IOW ('S', 0x46, struct sndrv_seq_queue_timer) 897#define SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER _IOW ('S', 0x46, struct snd_seq_queue_timer)
894/* XXX 898/* XXX
895#define SNDRV_SEQ_IOCTL_GET_QUEUE_SYNC _IOWR('S', 0x53, struct sndrv_seq_queue_sync) 899#define SNDRV_SEQ_IOCTL_GET_QUEUE_SYNC _IOWR('S', 0x53, struct snd_seq_queue_sync)
896#define SNDRV_SEQ_IOCTL_SET_QUEUE_SYNC _IOW ('S', 0x54, struct sndrv_seq_queue_sync) 900#define SNDRV_SEQ_IOCTL_SET_QUEUE_SYNC _IOW ('S', 0x54, struct snd_seq_queue_sync)
897*/ 901*/
898#define SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT _IOWR('S', 0x49, struct sndrv_seq_queue_client) 902#define SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT _IOWR('S', 0x49, struct snd_seq_queue_client)
899#define SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT _IOW ('S', 0x4a, struct sndrv_seq_queue_client) 903#define SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT _IOW ('S', 0x4a, struct snd_seq_queue_client)
900#define SNDRV_SEQ_IOCTL_GET_CLIENT_POOL _IOWR('S', 0x4b, struct sndrv_seq_client_pool) 904#define SNDRV_SEQ_IOCTL_GET_CLIENT_POOL _IOWR('S', 0x4b, struct snd_seq_client_pool)
901#define SNDRV_SEQ_IOCTL_SET_CLIENT_POOL _IOW ('S', 0x4c, struct sndrv_seq_client_pool) 905#define SNDRV_SEQ_IOCTL_SET_CLIENT_POOL _IOW ('S', 0x4c, struct snd_seq_client_pool)
902#define SNDRV_SEQ_IOCTL_REMOVE_EVENTS _IOW ('S', 0x4e, struct sndrv_seq_remove_events) 906#define SNDRV_SEQ_IOCTL_REMOVE_EVENTS _IOW ('S', 0x4e, struct snd_seq_remove_events)
903#define SNDRV_SEQ_IOCTL_QUERY_SUBS _IOWR('S', 0x4f, struct sndrv_seq_query_subs) 907#define SNDRV_SEQ_IOCTL_QUERY_SUBS _IOWR('S', 0x4f, struct snd_seq_query_subs)
904#define SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION _IOWR('S', 0x50, struct sndrv_seq_port_subscribe) 908#define SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION _IOWR('S', 0x50, struct snd_seq_port_subscribe)
905#define SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT _IOWR('S', 0x51, struct sndrv_seq_client_info) 909#define SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT _IOWR('S', 0x51, struct snd_seq_client_info)
906#define SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT _IOWR('S', 0x52, struct sndrv_seq_port_info) 910#define SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT _IOWR('S', 0x52, struct snd_seq_port_info)
907 911
908#endif /* __SOUND_ASEQUENCER_H */ 912#endif /* __SOUND_ASEQUENCER_H */