X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=sound%2Fcore%2Fseq%2Foss%2Fseq_oss_device.h;h=9a8567c928ec4bc262061b1314d73f4e0869373d;hb=43bc926fffd92024b46cafaf7350d669ba9ca884;hp=da23c4db8dd5f9e01fb3ada1e4a147314e629fae;hpb=cee37fe97739d85991964371c1f3a745c00dd236;p=linux-2.6.git diff --git a/sound/core/seq/oss/seq_oss_device.h b/sound/core/seq/oss/seq_oss_device.h index da23c4db8..9a8567c92 100644 --- a/sound/core/seq/oss/seq_oss_device.h +++ b/sound/core/seq/oss/seq_oss_device.h @@ -55,32 +55,24 @@ * type definitions */ -typedef struct seq_oss_devinfo_t seq_oss_devinfo_t; -typedef struct seq_oss_writeq_t seq_oss_writeq_t; -typedef struct seq_oss_readq_t seq_oss_readq_t; -typedef struct seq_oss_timer_t seq_oss_timer_t; -typedef struct seq_oss_synthinfo_t seq_oss_synthinfo_t; -typedef struct seq_oss_synth_sysex_t seq_oss_synth_sysex_t; -typedef struct seq_oss_chinfo_t seq_oss_chinfo_t; typedef unsigned int reltime_t; typedef unsigned int abstime_t; -typedef union evrec_t evrec_t; /* * synthesizer channel information */ -struct seq_oss_chinfo_t { +struct seq_oss_chinfo { int note, vel; }; /* * synthesizer information */ -struct seq_oss_synthinfo_t { - snd_seq_oss_arg_t arg; - seq_oss_chinfo_t *ch; - seq_oss_synth_sysex_t *sysex; +struct seq_oss_synthinfo { + struct snd_seq_oss_arg arg; + struct seq_oss_chinfo *ch; + struct seq_oss_synth_sysex *sysex; int nr_voices; int opened; int is_midi; @@ -92,14 +84,14 @@ struct seq_oss_synthinfo_t { * sequencer client information */ -struct seq_oss_devinfo_t { +struct seq_oss_devinfo { int index; /* application index */ int cseq; /* sequencer client number */ int port; /* sequencer port number */ int queue; /* sequencer queue number */ - snd_seq_addr_t addr; /* address of this device */ + struct snd_seq_addr addr; /* address of this device */ int seq_mode; /* sequencer mode */ int file_mode; /* file access */ @@ -109,17 +101,17 @@ struct seq_oss_devinfo_t { /* synth device table */ int max_synthdev; - seq_oss_synthinfo_t synths[SNDRV_SEQ_OSS_MAX_SYNTH_DEVS]; + struct seq_oss_synthinfo synths[SNDRV_SEQ_OSS_MAX_SYNTH_DEVS]; int synth_opened; /* output queue */ - seq_oss_writeq_t *writeq; + struct seq_oss_writeq *writeq; /* midi input queue */ - seq_oss_readq_t *readq; + struct seq_oss_readq *readq; /* timer */ - seq_oss_timer_t *timer; + struct seq_oss_timer *timer; }; @@ -133,24 +125,24 @@ int snd_seq_oss_delete_client(void); /* device file interface */ int snd_seq_oss_open(struct file *file, int level); -void snd_seq_oss_release(seq_oss_devinfo_t *dp); -int snd_seq_oss_ioctl(seq_oss_devinfo_t *dp, unsigned int cmd, unsigned long arg); -int snd_seq_oss_read(seq_oss_devinfo_t *dev, char __user *buf, int count); -int snd_seq_oss_write(seq_oss_devinfo_t *dp, const char __user *buf, int count, struct file *opt); -unsigned int snd_seq_oss_poll(seq_oss_devinfo_t *dp, struct file *file, poll_table * wait); +void snd_seq_oss_release(struct seq_oss_devinfo *dp); +int snd_seq_oss_ioctl(struct seq_oss_devinfo *dp, unsigned int cmd, unsigned long arg); +int snd_seq_oss_read(struct seq_oss_devinfo *dev, char __user *buf, int count); +int snd_seq_oss_write(struct seq_oss_devinfo *dp, const char __user *buf, int count, struct file *opt); +unsigned int snd_seq_oss_poll(struct seq_oss_devinfo *dp, struct file *file, poll_table * wait); -void snd_seq_oss_reset(seq_oss_devinfo_t *dp); -void snd_seq_oss_drain_write(seq_oss_devinfo_t *dp); +void snd_seq_oss_reset(struct seq_oss_devinfo *dp); +void snd_seq_oss_drain_write(struct seq_oss_devinfo *dp); /* */ -void snd_seq_oss_process_queue(seq_oss_devinfo_t *dp, abstime_t time); +void snd_seq_oss_process_queue(struct seq_oss_devinfo *dp, abstime_t time); /* proc interface */ -void snd_seq_oss_system_info_read(snd_info_buffer_t *buf); -void snd_seq_oss_midi_info_read(snd_info_buffer_t *buf); -void snd_seq_oss_synth_info_read(snd_info_buffer_t *buf); -void snd_seq_oss_readq_info_read(seq_oss_readq_t *q, snd_info_buffer_t *buf); +void snd_seq_oss_system_info_read(struct snd_info_buffer *buf); +void snd_seq_oss_midi_info_read(struct snd_info_buffer *buf); +void snd_seq_oss_synth_info_read(struct snd_info_buffer *buf); +void snd_seq_oss_readq_info_read(struct seq_oss_readq *q, struct snd_info_buffer *buf); /* file mode macros */ #define is_read_mode(mode) ((mode) & SNDRV_SEQ_OSS_FILE_READ) @@ -158,22 +150,22 @@ void snd_seq_oss_readq_info_read(seq_oss_readq_t *q, snd_info_buffer_t *buf); #define is_nonblock_mode(mode) ((mode) & SNDRV_SEQ_OSS_FILE_NONBLOCK) /* dispatch event */ -inline static int -snd_seq_oss_dispatch(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, int atomic, int hop) +static inline int +snd_seq_oss_dispatch(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, int atomic, int hop) { return snd_seq_kernel_client_dispatch(dp->cseq, ev, atomic, hop); } /* ioctl */ -inline static int -snd_seq_oss_control(seq_oss_devinfo_t *dp, unsigned int type, void *arg) +static inline int +snd_seq_oss_control(struct seq_oss_devinfo *dp, unsigned int type, void *arg) { return snd_seq_kernel_client_ctl(dp->cseq, type, arg); } /* fill the addresses in header */ -inline static void -snd_seq_oss_fill_addr(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, +static inline void +snd_seq_oss_fill_addr(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, int dest_client, int dest_port) { ev->queue = dp->queue;