aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2005-11-17 08:05:16 -0500
committerJaroslav Kysela <perex@suse.cz>2006-01-03 06:17:57 -0500
commit080dece3460b534bedc4ef4ba3abaa57e9486331 (patch)
tree7e35242b3d716cd29f62d96e0920230147cb5c03
parent19ac31e82cc7328c01bf26f824f33c7c38cb6075 (diff)
[ALSA] Remove xxx_t typedefs: Sequencer OSS-emulation
Modules: ALSA<-OSS sequencer,ALSA sequencer Remove xxx_t typedefs from the core sequencer OSS-emulation codes. Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r--include/sound/seq_oss.h30
-rw-r--r--sound/core/seq/oss/seq_oss.c24
-rw-r--r--sound/core/seq/oss/seq_oss_device.h60
-rw-r--r--sound/core/seq/oss/seq_oss_event.c60
-rw-r--r--sound/core/seq/oss/seq_oss_event.h50
-rw-r--r--sound/core/seq/oss/seq_oss_init.c52
-rw-r--r--sound/core/seq/oss/seq_oss_ioctl.c12
-rw-r--r--sound/core/seq/oss/seq_oss_midi.c96
-rw-r--r--sound/core/seq/oss/seq_oss_midi.h27
-rw-r--r--sound/core/seq/oss/seq_oss_readq.c32
-rw-r--r--sound/core/seq/oss/seq_oss_readq.h24
-rw-r--r--sound/core/seq/oss/seq_oss_rw.c18
-rw-r--r--sound/core/seq/oss/seq_oss_synth.c92
-rw-r--r--sound/core/seq/oss/seq_oss_synth.h32
-rw-r--r--sound/core/seq/oss/seq_oss_timer.c34
-rw-r--r--sound/core/seq/oss/seq_oss_timer.h22
-rw-r--r--sound/core/seq/oss/seq_oss_writeq.c34
-rw-r--r--sound/core/seq/oss/seq_oss_writeq.h18
18 files changed, 352 insertions, 365 deletions
diff --git a/include/sound/seq_oss.h b/include/sound/seq_oss.h
index bd7e57322ab6..9b060bbd6e02 100644
--- a/include/sound/seq_oss.h
+++ b/include/sound/seq_oss.h
@@ -25,22 +25,16 @@
25#include "seq_kernel.h" 25#include "seq_kernel.h"
26 26
27/* 27/*
28 * type definitions
29 */
30typedef struct snd_seq_oss_arg_t snd_seq_oss_arg_t;
31typedef struct snd_seq_oss_callback_t snd_seq_oss_callback_t;
32
33/*
34 * argument structure for synthesizer operations 28 * argument structure for synthesizer operations
35 */ 29 */
36struct snd_seq_oss_arg_t { 30struct snd_seq_oss_arg {
37 /* given by OSS sequencer */ 31 /* given by OSS sequencer */
38 int app_index; /* application unique index */ 32 int app_index; /* application unique index */
39 int file_mode; /* file mode - see below */ 33 int file_mode; /* file mode - see below */
40 int seq_mode; /* sequencer mode - see below */ 34 int seq_mode; /* sequencer mode - see below */
41 35
42 /* following must be initialized in open callback */ 36 /* following must be initialized in open callback */
43 snd_seq_addr_t addr; /* opened port address */ 37 struct snd_seq_addr addr; /* opened port address */
44 void *private_data; /* private data for lowlevel drivers */ 38 void *private_data; /* private data for lowlevel drivers */
45 39
46 /* note-on event passing mode: initially given by OSS seq, 40 /* note-on event passing mode: initially given by OSS seq,
@@ -53,14 +47,14 @@ struct snd_seq_oss_arg_t {
53/* 47/*
54 * synthesizer operation callbacks 48 * synthesizer operation callbacks
55 */ 49 */
56struct snd_seq_oss_callback_t { 50struct snd_seq_oss_callback {
57 struct module *owner; 51 struct module *owner;
58 int (*open)(snd_seq_oss_arg_t *p, void *closure); 52 int (*open)(struct snd_seq_oss_arg *p, void *closure);
59 int (*close)(snd_seq_oss_arg_t *p); 53 int (*close)(struct snd_seq_oss_arg *p);
60 int (*ioctl)(snd_seq_oss_arg_t *p, unsigned int cmd, unsigned long arg); 54 int (*ioctl)(struct snd_seq_oss_arg *p, unsigned int cmd, unsigned long arg);
61 int (*load_patch)(snd_seq_oss_arg_t *p, int format, const char __user *buf, int offs, int count); 55 int (*load_patch)(struct snd_seq_oss_arg *p, int format, const char __user *buf, int offs, int count);
62 int (*reset)(snd_seq_oss_arg_t *p); 56 int (*reset)(struct snd_seq_oss_arg *p);
63 int (*raw_event)(snd_seq_oss_arg_t *p, unsigned char *data); 57 int (*raw_event)(struct snd_seq_oss_arg *p, unsigned char *data);
64}; 58};
65 59
66/* flag: file_mode */ 60/* flag: file_mode */
@@ -88,13 +82,13 @@ struct snd_seq_oss_callback_t {
88/* 82/*
89 * data pointer to snd_seq_register_device 83 * data pointer to snd_seq_register_device
90 */ 84 */
91typedef struct snd_seq_oss_reg { 85struct snd_seq_oss_reg {
92 int type; 86 int type;
93 int subtype; 87 int subtype;
94 int nvoices; 88 int nvoices;
95 snd_seq_oss_callback_t oper; 89 struct snd_seq_oss_callback oper;
96 void *private_data; 90 void *private_data;
97} snd_seq_oss_reg_t; 91};
98 92
99/* device id */ 93/* device id */
100#define SNDRV_SEQ_DEV_ID_OSS "seq-oss" 94#define SNDRV_SEQ_DEV_ID_OSS "seq-oss"
diff --git a/sound/core/seq/oss/seq_oss.c b/sound/core/seq/oss/seq_oss.c
index 4c0558c0a8b4..2371e41b13ef 100644
--- a/sound/core/seq/oss/seq_oss.c
+++ b/sound/core/seq/oss/seq_oss.c
@@ -62,7 +62,7 @@ static ssize_t odev_write(struct file *file, const char __user *buf, size_t coun
62static long odev_ioctl(struct file *file, unsigned int cmd, unsigned long arg); 62static long odev_ioctl(struct file *file, unsigned int cmd, unsigned long arg);
63static unsigned int odev_poll(struct file *file, poll_table * wait); 63static unsigned int odev_poll(struct file *file, poll_table * wait);
64#ifdef CONFIG_PROC_FS 64#ifdef CONFIG_PROC_FS
65static void info_read(snd_info_entry_t *entry, snd_info_buffer_t *buf); 65static void info_read(struct snd_info_entry *entry, struct snd_info_buffer *buf);
66#endif 66#endif
67 67
68 68
@@ -73,7 +73,7 @@ static void info_read(snd_info_entry_t *entry, snd_info_buffer_t *buf);
73static int __init alsa_seq_oss_init(void) 73static int __init alsa_seq_oss_init(void)
74{ 74{
75 int rc; 75 int rc;
76 static snd_seq_dev_ops_t ops = { 76 static struct snd_seq_dev_ops ops = {
77 snd_seq_oss_synth_register, 77 snd_seq_oss_synth_register,
78 snd_seq_oss_synth_unregister, 78 snd_seq_oss_synth_unregister,
79 }; 79 };
@@ -92,7 +92,7 @@ static int __init alsa_seq_oss_init(void)
92 } 92 }
93 93
94 if ((rc = snd_seq_device_register_driver(SNDRV_SEQ_DEV_ID_OSS, &ops, 94 if ((rc = snd_seq_device_register_driver(SNDRV_SEQ_DEV_ID_OSS, &ops,
95 sizeof(snd_seq_oss_reg_t))) < 0) { 95 sizeof(struct snd_seq_oss_reg))) < 0) {
96 snd_seq_oss_delete_client(); 96 snd_seq_oss_delete_client();
97 unregister_proc(); 97 unregister_proc();
98 unregister_device(); 98 unregister_device();
@@ -144,7 +144,7 @@ odev_open(struct inode *inode, struct file *file)
144static int 144static int
145odev_release(struct inode *inode, struct file *file) 145odev_release(struct inode *inode, struct file *file)
146{ 146{
147 seq_oss_devinfo_t *dp; 147 struct seq_oss_devinfo *dp;
148 148
149 if ((dp = file->private_data) == NULL) 149 if ((dp = file->private_data) == NULL)
150 return 0; 150 return 0;
@@ -161,7 +161,7 @@ odev_release(struct inode *inode, struct file *file)
161static ssize_t 161static ssize_t
162odev_read(struct file *file, char __user *buf, size_t count, loff_t *offset) 162odev_read(struct file *file, char __user *buf, size_t count, loff_t *offset)
163{ 163{
164 seq_oss_devinfo_t *dp; 164 struct seq_oss_devinfo *dp;
165 dp = file->private_data; 165 dp = file->private_data;
166 snd_assert(dp != NULL, return -EIO); 166 snd_assert(dp != NULL, return -EIO);
167 return snd_seq_oss_read(dp, buf, count); 167 return snd_seq_oss_read(dp, buf, count);
@@ -171,7 +171,7 @@ odev_read(struct file *file, char __user *buf, size_t count, loff_t *offset)
171static ssize_t 171static ssize_t
172odev_write(struct file *file, const char __user *buf, size_t count, loff_t *offset) 172odev_write(struct file *file, const char __user *buf, size_t count, loff_t *offset)
173{ 173{
174 seq_oss_devinfo_t *dp; 174 struct seq_oss_devinfo *dp;
175 dp = file->private_data; 175 dp = file->private_data;
176 snd_assert(dp != NULL, return -EIO); 176 snd_assert(dp != NULL, return -EIO);
177 return snd_seq_oss_write(dp, buf, count, file); 177 return snd_seq_oss_write(dp, buf, count, file);
@@ -180,7 +180,7 @@ odev_write(struct file *file, const char __user *buf, size_t count, loff_t *offs
180static long 180static long
181odev_ioctl(struct file *file, unsigned int cmd, unsigned long arg) 181odev_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
182{ 182{
183 seq_oss_devinfo_t *dp; 183 struct seq_oss_devinfo *dp;
184 dp = file->private_data; 184 dp = file->private_data;
185 snd_assert(dp != NULL, return -EIO); 185 snd_assert(dp != NULL, return -EIO);
186 return snd_seq_oss_ioctl(dp, cmd, arg); 186 return snd_seq_oss_ioctl(dp, cmd, arg);
@@ -195,7 +195,7 @@ odev_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
195static unsigned int 195static unsigned int
196odev_poll(struct file *file, poll_table * wait) 196odev_poll(struct file *file, poll_table * wait)
197{ 197{
198 seq_oss_devinfo_t *dp; 198 struct seq_oss_devinfo *dp;
199 dp = file->private_data; 199 dp = file->private_data;
200 snd_assert(dp != NULL, return 0); 200 snd_assert(dp != NULL, return 0);
201 return snd_seq_oss_poll(dp, file, wait); 201 return snd_seq_oss_poll(dp, file, wait);
@@ -217,7 +217,7 @@ static struct file_operations seq_oss_f_ops =
217 .compat_ioctl = odev_ioctl_compat, 217 .compat_ioctl = odev_ioctl_compat,
218}; 218};
219 219
220static snd_minor_t seq_oss_reg = { 220static struct snd_minor seq_oss_reg = {
221 .comment = "sequencer", 221 .comment = "sequencer",
222 .f_ops = &seq_oss_f_ops, 222 .f_ops = &seq_oss_f_ops,
223}; 223};
@@ -268,10 +268,10 @@ unregister_device(void)
268 268
269#ifdef CONFIG_PROC_FS 269#ifdef CONFIG_PROC_FS
270 270
271static snd_info_entry_t *info_entry; 271static struct snd_info_entry *info_entry;
272 272
273static void 273static void
274info_read(snd_info_entry_t *entry, snd_info_buffer_t *buf) 274info_read(struct snd_info_entry *entry, struct snd_info_buffer *buf)
275{ 275{
276 down(&register_mutex); 276 down(&register_mutex);
277 snd_iprintf(buf, "OSS sequencer emulation version %s\n", SNDRV_SEQ_OSS_VERSION_STR); 277 snd_iprintf(buf, "OSS sequencer emulation version %s\n", SNDRV_SEQ_OSS_VERSION_STR);
@@ -287,7 +287,7 @@ static int __init
287register_proc(void) 287register_proc(void)
288{ 288{
289#ifdef CONFIG_PROC_FS 289#ifdef CONFIG_PROC_FS
290 snd_info_entry_t *entry; 290 struct snd_info_entry *entry;
291 291
292 entry = snd_info_create_module_entry(THIS_MODULE, SNDRV_SEQ_OSS_PROCNAME, snd_seq_root); 292 entry = snd_info_create_module_entry(THIS_MODULE, SNDRV_SEQ_OSS_PROCNAME, snd_seq_root);
293 if (entry == NULL) 293 if (entry == NULL)
diff --git a/sound/core/seq/oss/seq_oss_device.h b/sound/core/seq/oss/seq_oss_device.h
index 973786758c55..9a8567c928ec 100644
--- a/sound/core/seq/oss/seq_oss_device.h
+++ b/sound/core/seq/oss/seq_oss_device.h
@@ -55,32 +55,24 @@
55 * type definitions 55 * type definitions
56 */ 56 */
57 57
58typedef struct seq_oss_devinfo_t seq_oss_devinfo_t;
59typedef struct seq_oss_writeq_t seq_oss_writeq_t;
60typedef struct seq_oss_readq_t seq_oss_readq_t;
61typedef struct seq_oss_timer_t seq_oss_timer_t;
62typedef struct seq_oss_synthinfo_t seq_oss_synthinfo_t;
63typedef struct seq_oss_synth_sysex_t seq_oss_synth_sysex_t;
64typedef struct seq_oss_chinfo_t seq_oss_chinfo_t;
65typedef unsigned int reltime_t; 58typedef unsigned int reltime_t;
66typedef unsigned int abstime_t; 59typedef unsigned int abstime_t;
67typedef union evrec_t evrec_t;
68 60
69 61
70/* 62/*
71 * synthesizer channel information 63 * synthesizer channel information
72 */ 64 */
73struct seq_oss_chinfo_t { 65struct seq_oss_chinfo {
74 int note, vel; 66 int note, vel;
75}; 67};
76 68
77/* 69/*
78 * synthesizer information 70 * synthesizer information
79 */ 71 */
80struct seq_oss_synthinfo_t { 72struct seq_oss_synthinfo {
81 snd_seq_oss_arg_t arg; 73 struct snd_seq_oss_arg arg;
82 seq_oss_chinfo_t *ch; 74 struct seq_oss_chinfo *ch;
83 seq_oss_synth_sysex_t *sysex; 75 struct seq_oss_synth_sysex *sysex;
84 int nr_voices; 76 int nr_voices;
85 int opened; 77 int opened;
86 int is_midi; 78 int is_midi;
@@ -92,14 +84,14 @@ struct seq_oss_synthinfo_t {
92 * sequencer client information 84 * sequencer client information
93 */ 85 */
94 86
95struct seq_oss_devinfo_t { 87struct seq_oss_devinfo {
96 88
97 int index; /* application index */ 89 int index; /* application index */
98 int cseq; /* sequencer client number */ 90 int cseq; /* sequencer client number */
99 int port; /* sequencer port number */ 91 int port; /* sequencer port number */
100 int queue; /* sequencer queue number */ 92 int queue; /* sequencer queue number */
101 93
102 snd_seq_addr_t addr; /* address of this device */ 94 struct snd_seq_addr addr; /* address of this device */
103 95
104 int seq_mode; /* sequencer mode */ 96 int seq_mode; /* sequencer mode */
105 int file_mode; /* file access */ 97 int file_mode; /* file access */
@@ -109,17 +101,17 @@ struct seq_oss_devinfo_t {
109 101
110 /* synth device table */ 102 /* synth device table */
111 int max_synthdev; 103 int max_synthdev;
112 seq_oss_synthinfo_t synths[SNDRV_SEQ_OSS_MAX_SYNTH_DEVS]; 104 struct seq_oss_synthinfo synths[SNDRV_SEQ_OSS_MAX_SYNTH_DEVS];
113 int synth_opened; 105 int synth_opened;
114 106
115 /* output queue */ 107 /* output queue */
116 seq_oss_writeq_t *writeq; 108 struct seq_oss_writeq *writeq;
117 109
118 /* midi input queue */ 110 /* midi input queue */
119 seq_oss_readq_t *readq; 111 struct seq_oss_readq *readq;
120 112
121 /* timer */ 113 /* timer */
122 seq_oss_timer_t *timer; 114 struct seq_oss_timer *timer;
123}; 115};
124 116
125 117
@@ -133,24 +125,24 @@ int snd_seq_oss_delete_client(void);
133 125
134/* device file interface */ 126/* device file interface */
135int snd_seq_oss_open(struct file *file, int level); 127int snd_seq_oss_open(struct file *file, int level);
136void snd_seq_oss_release(seq_oss_devinfo_t *dp); 128void snd_seq_oss_release(struct seq_oss_devinfo *dp);
137int snd_seq_oss_ioctl(seq_oss_devinfo_t *dp, unsigned int cmd, unsigned long arg); 129int snd_seq_oss_ioctl(struct seq_oss_devinfo *dp, unsigned int cmd, unsigned long arg);
138int snd_seq_oss_read(seq_oss_devinfo_t *dev, char __user *buf, int count); 130int snd_seq_oss_read(struct seq_oss_devinfo *dev, char __user *buf, int count);
139int snd_seq_oss_write(seq_oss_devinfo_t *dp, const char __user *buf, int count, struct file *opt); 131int snd_seq_oss_write(struct seq_oss_devinfo *dp, const char __user *buf, int count, struct file *opt);
140unsigned int snd_seq_oss_poll(seq_oss_devinfo_t *dp, struct file *file, poll_table * wait); 132unsigned int snd_seq_oss_poll(struct seq_oss_devinfo *dp, struct file *file, poll_table * wait);
141 133
142void snd_seq_oss_reset(seq_oss_devinfo_t *dp); 134void snd_seq_oss_reset(struct seq_oss_devinfo *dp);
143void snd_seq_oss_drain_write(seq_oss_devinfo_t *dp); 135void snd_seq_oss_drain_write(struct seq_oss_devinfo *dp);
144 136
145/* */ 137/* */
146void snd_seq_oss_process_queue(seq_oss_devinfo_t *dp, abstime_t time); 138void snd_seq_oss_process_queue(struct seq_oss_devinfo *dp, abstime_t time);
147 139
148 140
149/* proc interface */ 141/* proc interface */
150void snd_seq_oss_system_info_read(snd_info_buffer_t *buf); 142void snd_seq_oss_system_info_read(struct snd_info_buffer *buf);
151void snd_seq_oss_midi_info_read(snd_info_buffer_t *buf); 143void snd_seq_oss_midi_info_read(struct snd_info_buffer *buf);
152void snd_seq_oss_synth_info_read(snd_info_buffer_t *buf); 144void snd_seq_oss_synth_info_read(struct snd_info_buffer *buf);
153void snd_seq_oss_readq_info_read(seq_oss_readq_t *q, snd_info_buffer_t *buf); 145void snd_seq_oss_readq_info_read(struct seq_oss_readq *q, struct snd_info_buffer *buf);
154 146
155/* file mode macros */ 147/* file mode macros */
156#define is_read_mode(mode) ((mode) & SNDRV_SEQ_OSS_FILE_READ) 148#define is_read_mode(mode) ((mode) & SNDRV_SEQ_OSS_FILE_READ)
@@ -159,21 +151,21 @@ void snd_seq_oss_readq_info_read(seq_oss_readq_t *q, snd_info_buffer_t *buf);
159 151
160/* dispatch event */ 152/* dispatch event */
161static inline int 153static inline int
162snd_seq_oss_dispatch(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, int atomic, int hop) 154snd_seq_oss_dispatch(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, int atomic, int hop)
163{ 155{
164 return snd_seq_kernel_client_dispatch(dp->cseq, ev, atomic, hop); 156 return snd_seq_kernel_client_dispatch(dp->cseq, ev, atomic, hop);
165} 157}
166 158
167/* ioctl */ 159/* ioctl */
168static inline int 160static inline int
169snd_seq_oss_control(seq_oss_devinfo_t *dp, unsigned int type, void *arg) 161snd_seq_oss_control(struct seq_oss_devinfo *dp, unsigned int type, void *arg)
170{ 162{
171 return snd_seq_kernel_client_ctl(dp->cseq, type, arg); 163 return snd_seq_kernel_client_ctl(dp->cseq, type, arg);
172} 164}
173 165
174/* fill the addresses in header */ 166/* fill the addresses in header */
175static inline void 167static inline void
176snd_seq_oss_fill_addr(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, 168snd_seq_oss_fill_addr(struct seq_oss_devinfo *dp, struct snd_seq_event *ev,
177 int dest_client, int dest_port) 169 int dest_client, int dest_port)
178{ 170{
179 ev->queue = dp->queue; 171 ev->queue = dp->queue;
diff --git a/sound/core/seq/oss/seq_oss_event.c b/sound/core/seq/oss/seq_oss_event.c
index 58e52ddd2927..066f5f3e3f4c 100644
--- a/sound/core/seq/oss/seq_oss_event.c
+++ b/sound/core/seq/oss/seq_oss_event.c
@@ -31,17 +31,17 @@
31/* 31/*
32 * prototypes 32 * prototypes
33 */ 33 */
34static int extended_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev); 34static int extended_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev);
35static int chn_voice_event(seq_oss_devinfo_t *dp, evrec_t *event_rec, snd_seq_event_t *ev); 35static int chn_voice_event(struct seq_oss_devinfo *dp, union evrec *event_rec, struct snd_seq_event *ev);
36static int chn_common_event(seq_oss_devinfo_t *dp, evrec_t *event_rec, snd_seq_event_t *ev); 36static int chn_common_event(struct seq_oss_devinfo *dp, union evrec *event_rec, struct snd_seq_event *ev);
37static int timing_event(seq_oss_devinfo_t *dp, evrec_t *event_rec, snd_seq_event_t *ev); 37static int timing_event(struct seq_oss_devinfo *dp, union evrec *event_rec, struct snd_seq_event *ev);
38static int local_event(seq_oss_devinfo_t *dp, evrec_t *event_rec, snd_seq_event_t *ev); 38static int local_event(struct seq_oss_devinfo *dp, union evrec *event_rec, struct snd_seq_event *ev);
39static int old_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev); 39static int old_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev);
40static int note_on_event(seq_oss_devinfo_t *dp, int dev, int ch, int note, int vel, snd_seq_event_t *ev); 40static int note_on_event(struct seq_oss_devinfo *dp, int dev, int ch, int note, int vel, struct snd_seq_event *ev);
41static int note_off_event(seq_oss_devinfo_t *dp, int dev, int ch, int note, int vel, snd_seq_event_t *ev); 41static int note_off_event(struct seq_oss_devinfo *dp, int dev, int ch, int note, int vel, struct snd_seq_event *ev);
42static int set_note_event(seq_oss_devinfo_t *dp, int dev, int type, int ch, int note, int vel, snd_seq_event_t *ev); 42static int set_note_event(struct seq_oss_devinfo *dp, int dev, int type, int ch, int note, int vel, struct snd_seq_event *ev);
43static int set_control_event(seq_oss_devinfo_t *dp, int dev, int type, int ch, int param, int val, snd_seq_event_t *ev); 43static int set_control_event(struct seq_oss_devinfo *dp, int dev, int type, int ch, int param, int val, struct snd_seq_event *ev);
44static int set_echo_event(seq_oss_devinfo_t *dp, evrec_t *rec, snd_seq_event_t *ev); 44static int set_echo_event(struct seq_oss_devinfo *dp, union evrec *rec, struct snd_seq_event *ev);
45 45
46 46
47/* 47/*
@@ -51,7 +51,7 @@ static int set_echo_event(seq_oss_devinfo_t *dp, evrec_t *rec, snd_seq_event_t *
51 */ 51 */
52 52
53int 53int
54snd_seq_oss_process_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 54snd_seq_oss_process_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
55{ 55{
56 switch (q->s.code) { 56 switch (q->s.code) {
57 case SEQ_EXTENDED: 57 case SEQ_EXTENDED:
@@ -104,7 +104,7 @@ snd_seq_oss_process_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev
104 104
105/* old type events: mode1 only */ 105/* old type events: mode1 only */
106static int 106static int
107old_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 107old_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
108{ 108{
109 switch (q->s.code) { 109 switch (q->s.code) {
110 case SEQ_NOTEOFF: 110 case SEQ_NOTEOFF:
@@ -130,7 +130,7 @@ old_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev)
130 130
131/* 8bytes extended event: mode1 only */ 131/* 8bytes extended event: mode1 only */
132static int 132static int
133extended_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 133extended_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
134{ 134{
135 int val; 135 int val;
136 136
@@ -184,7 +184,7 @@ extended_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev)
184 184
185/* channel voice events: mode1 and 2 */ 185/* channel voice events: mode1 and 2 */
186static int 186static int
187chn_voice_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 187chn_voice_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
188{ 188{
189 if (q->v.chn >= 32) 189 if (q->v.chn >= 32)
190 return -EINVAL; 190 return -EINVAL;
@@ -205,7 +205,7 @@ chn_voice_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev)
205 205
206/* channel common events: mode1 and 2 */ 206/* channel common events: mode1 and 2 */
207static int 207static int
208chn_common_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 208chn_common_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
209{ 209{
210 if (q->l.chn >= 32) 210 if (q->l.chn >= 32)
211 return -EINVAL; 211 return -EINVAL;
@@ -232,14 +232,14 @@ chn_common_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev)
232 232
233/* timer events: mode1 and mode2 */ 233/* timer events: mode1 and mode2 */
234static int 234static int
235timing_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 235timing_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
236{ 236{
237 switch (q->t.cmd) { 237 switch (q->t.cmd) {
238 case TMR_ECHO: 238 case TMR_ECHO:
239 if (dp->seq_mode == SNDRV_SEQ_OSS_MODE_MUSIC) 239 if (dp->seq_mode == SNDRV_SEQ_OSS_MODE_MUSIC)
240 return set_echo_event(dp, q, ev); 240 return set_echo_event(dp, q, ev);
241 else { 241 else {
242 evrec_t tmp; 242 union evrec tmp;
243 memset(&tmp, 0, sizeof(tmp)); 243 memset(&tmp, 0, sizeof(tmp));
244 /* XXX: only for little-endian! */ 244 /* XXX: only for little-endian! */
245 tmp.echo = (q->t.time << 8) | SEQ_ECHO; 245 tmp.echo = (q->t.time << 8) | SEQ_ECHO;
@@ -267,7 +267,7 @@ timing_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev)
267 267
268/* local events: mode1 and 2 */ 268/* local events: mode1 and 2 */
269static int 269static int
270local_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev) 270local_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev)
271{ 271{
272 return -EINVAL; 272 return -EINVAL;
273} 273}
@@ -283,9 +283,9 @@ local_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev)
283 * Use key-pressure if note >= 128 283 * Use key-pressure if note >= 128
284 */ 284 */
285static int 285static int
286note_on_event(seq_oss_devinfo_t *dp, int dev, int ch, int note, int vel, snd_seq_event_t *ev) 286note_on_event(struct seq_oss_devinfo *dp, int dev, int ch, int note, int vel, struct snd_seq_event *ev)
287{ 287{
288 seq_oss_synthinfo_t *info = &dp->synths[dev]; 288 struct seq_oss_synthinfo *info = &dp->synths[dev];
289 switch (info->arg.event_passing) { 289 switch (info->arg.event_passing) {
290 case SNDRV_SEQ_OSS_PROCESS_EVENTS: 290 case SNDRV_SEQ_OSS_PROCESS_EVENTS:
291 if (! info->ch || ch < 0 || ch >= info->nr_voices) { 291 if (! info->ch || ch < 0 || ch >= info->nr_voices) {
@@ -338,9 +338,9 @@ note_on_event(seq_oss_devinfo_t *dp, int dev, int ch, int note, int vel, snd_seq
338 * process note-off event for OSS synth 338 * process note-off event for OSS synth
339 */ 339 */
340static int 340static int
341note_off_event(seq_oss_devinfo_t *dp, int dev, int ch, int note, int vel, snd_seq_event_t *ev) 341note_off_event(struct seq_oss_devinfo *dp, int dev, int ch, int note, int vel, struct snd_seq_event *ev)
342{ 342{
343 seq_oss_synthinfo_t *info = &dp->synths[dev]; 343 struct seq_oss_synthinfo *info = &dp->synths[dev];
344 switch (info->arg.event_passing) { 344 switch (info->arg.event_passing) {
345 case SNDRV_SEQ_OSS_PROCESS_EVENTS: 345 case SNDRV_SEQ_OSS_PROCESS_EVENTS:
346 if (! info->ch || ch < 0 || ch >= info->nr_voices) { 346 if (! info->ch || ch < 0 || ch >= info->nr_voices) {
@@ -369,7 +369,7 @@ note_off_event(seq_oss_devinfo_t *dp, int dev, int ch, int note, int vel, snd_se
369 * create a note event 369 * create a note event
370 */ 370 */
371static int 371static int
372set_note_event(seq_oss_devinfo_t *dp, int dev, int type, int ch, int note, int vel, snd_seq_event_t *ev) 372set_note_event(struct seq_oss_devinfo *dp, int dev, int type, int ch, int note, int vel, struct snd_seq_event *ev)
373{ 373{
374 if (! snd_seq_oss_synth_is_valid(dp, dev)) 374 if (! snd_seq_oss_synth_is_valid(dp, dev))
375 return -ENXIO; 375 return -ENXIO;
@@ -387,7 +387,7 @@ set_note_event(seq_oss_devinfo_t *dp, int dev, int type, int ch, int note, int v
387 * create a control event 387 * create a control event
388 */ 388 */
389static int 389static int
390set_control_event(seq_oss_devinfo_t *dp, int dev, int type, int ch, int param, int val, snd_seq_event_t *ev) 390set_control_event(struct seq_oss_devinfo *dp, int dev, int type, int ch, int param, int val, struct snd_seq_event *ev)
391{ 391{
392 if (! snd_seq_oss_synth_is_valid(dp, dev)) 392 if (! snd_seq_oss_synth_is_valid(dp, dev))
393 return -ENXIO; 393 return -ENXIO;
@@ -405,7 +405,7 @@ set_control_event(seq_oss_devinfo_t *dp, int dev, int type, int ch, int param, i
405 * create an echo event 405 * create an echo event
406 */ 406 */
407static int 407static int
408set_echo_event(seq_oss_devinfo_t *dp, evrec_t *rec, snd_seq_event_t *ev) 408set_echo_event(struct seq_oss_devinfo *dp, union evrec *rec, struct snd_seq_event *ev)
409{ 409{
410 ev->type = SNDRV_SEQ_EVENT_ECHO; 410 ev->type = SNDRV_SEQ_EVENT_ECHO;
411 /* echo back to itself */ 411 /* echo back to itself */
@@ -419,11 +419,11 @@ set_echo_event(seq_oss_devinfo_t *dp, evrec_t *rec, snd_seq_event_t *ev)
419 * the echo event is processed here. 419 * the echo event is processed here.
420 */ 420 */
421int 421int
422snd_seq_oss_event_input(snd_seq_event_t *ev, int direct, void *private_data, 422snd_seq_oss_event_input(struct snd_seq_event *ev, int direct, void *private_data,
423 int atomic, int hop) 423 int atomic, int hop)
424{ 424{
425 seq_oss_devinfo_t *dp = (seq_oss_devinfo_t *)private_data; 425 struct seq_oss_devinfo *dp = (struct seq_oss_devinfo *)private_data;
426 evrec_t *rec; 426 union evrec *rec;
427 427
428 if (ev->type != SNDRV_SEQ_EVENT_ECHO) 428 if (ev->type != SNDRV_SEQ_EVENT_ECHO)
429 return snd_seq_oss_midi_input(ev, direct, private_data); 429 return snd_seq_oss_midi_input(ev, direct, private_data);
@@ -431,7 +431,7 @@ snd_seq_oss_event_input(snd_seq_event_t *ev, int direct, void *private_data,
431 if (ev->source.client != dp->cseq) 431 if (ev->source.client != dp->cseq)
432 return 0; /* ignored */ 432 return 0; /* ignored */
433 433
434 rec = (evrec_t*)&ev->data; 434 rec = (union evrec*)&ev->data;
435 if (rec->s.code == SEQ_SYNCTIMER) { 435 if (rec->s.code == SEQ_SYNCTIMER) {
436 /* sync echo back */ 436 /* sync echo back */
437 snd_seq_oss_writeq_wakeup(dp->writeq, rec->t.time); 437 snd_seq_oss_writeq_wakeup(dp->writeq, rec->t.time);
diff --git a/sound/core/seq/oss/seq_oss_event.h b/sound/core/seq/oss/seq_oss_event.h
index bf1d4d3f53c9..9a4d9adb7b8c 100644
--- a/sound/core/seq/oss/seq_oss_event.h
+++ b/sound/core/seq/oss/seq_oss_event.h
@@ -29,74 +29,74 @@
29#define LONG_EVENT_SIZE 8 29#define LONG_EVENT_SIZE 8
30 30
31/* short event (4bytes) */ 31/* short event (4bytes) */
32typedef struct evrec_short_t { 32struct evrec_short {
33 unsigned char code; 33 unsigned char code;
34 unsigned char parm1; 34 unsigned char parm1;
35 unsigned char dev; 35 unsigned char dev;
36 unsigned char parm2; 36 unsigned char parm2;
37} evrec_short_t; 37};
38 38
39/* short note events (4bytes) */ 39/* short note events (4bytes) */
40typedef struct evrec_note_t { 40struct evrec_note {
41 unsigned char code; 41 unsigned char code;
42 unsigned char chn; 42 unsigned char chn;
43 unsigned char note; 43 unsigned char note;
44 unsigned char vel; 44 unsigned char vel;
45} evrec_note_t; 45};
46 46
47/* long timer events (8bytes) */ 47/* long timer events (8bytes) */
48typedef struct evrec_timer_t { 48struct evrec_timer {
49 unsigned char code; 49 unsigned char code;
50 unsigned char cmd; 50 unsigned char cmd;
51 unsigned char dummy1, dummy2; 51 unsigned char dummy1, dummy2;
52 unsigned int time; 52 unsigned int time;
53} evrec_timer_t; 53};
54 54
55/* long extended events (8bytes) */ 55/* long extended events (8bytes) */
56typedef struct evrec_extended_t { 56struct evrec_extended {
57 unsigned char code; 57 unsigned char code;
58 unsigned char cmd; 58 unsigned char cmd;
59 unsigned char dev; 59 unsigned char dev;
60 unsigned char chn; 60 unsigned char chn;
61 unsigned char p1, p2, p3, p4; 61 unsigned char p1, p2, p3, p4;
62} evrec_extended_t; 62};
63 63
64/* long channel events (8bytes) */ 64/* long channel events (8bytes) */
65typedef struct evrec_long_t { 65struct evrec_long {
66 unsigned char code; 66 unsigned char code;
67 unsigned char dev; 67 unsigned char dev;
68 unsigned char cmd; 68 unsigned char cmd;
69 unsigned char chn; 69 unsigned char chn;
70 unsigned char p1, p2; 70 unsigned char p1, p2;
71 unsigned short val; 71 unsigned short val;
72} evrec_long_t; 72};
73 73
74/* channel voice events (8bytes) */ 74/* channel voice events (8bytes) */
75typedef struct evrec_voice_t { 75struct evrec_voice {
76 unsigned char code; 76 unsigned char code;
77 unsigned char dev; 77 unsigned char dev;
78 unsigned char cmd; 78 unsigned char cmd;
79 unsigned char chn; 79 unsigned char chn;
80 unsigned char note, parm; 80 unsigned char note, parm;
81 unsigned short dummy; 81 unsigned short dummy;
82} evrec_voice_t; 82};
83 83
84/* sysex events (8bytes) */ 84/* sysex events (8bytes) */
85typedef struct evrec_sysex_t { 85struct evrec_sysex {
86 unsigned char code; 86 unsigned char code;
87 unsigned char dev; 87 unsigned char dev;
88 unsigned char buf[6]; 88 unsigned char buf[6];
89} evrec_sysex_t; 89};
90 90
91/* event record */ 91/* event record */
92union evrec_t { 92union evrec {
93 evrec_short_t s; 93 struct evrec_short s;
94 evrec_note_t n; 94 struct evrec_note n;
95 evrec_long_t l; 95 struct evrec_long l;
96 evrec_voice_t v; 96 struct evrec_voice v;
97 evrec_timer_t t; 97 struct evrec_timer t;
98 evrec_extended_t e; 98 struct evrec_extended e;
99 evrec_sysex_t x; 99 struct evrec_sysex x;
100 unsigned int echo; 100 unsigned int echo;
101 unsigned char c[LONG_EVENT_SIZE]; 101 unsigned char c[LONG_EVENT_SIZE];
102}; 102};
@@ -104,9 +104,9 @@ union evrec_t {
104#define ev_is_long(ev) ((ev)->s.code >= 128) 104#define ev_is_long(ev) ((ev)->s.code >= 128)
105#define ev_length(ev) ((ev)->s.code >= 128 ? LONG_EVENT_SIZE : SHORT_EVENT_SIZE) 105#define ev_length(ev) ((ev)->s.code >= 128 ? LONG_EVENT_SIZE : SHORT_EVENT_SIZE)
106 106
107int snd_seq_oss_process_event(seq_oss_devinfo_t *dp, evrec_t *q, snd_seq_event_t *ev); 107int snd_seq_oss_process_event(struct seq_oss_devinfo *dp, union evrec *q, struct snd_seq_event *ev);
108int snd_seq_oss_process_timer_event(seq_oss_timer_t *rec, evrec_t *q); 108int snd_seq_oss_process_timer_event(struct seq_oss_timer *rec, union evrec *q);
109int snd_seq_oss_event_input(snd_seq_event_t *ev, int direct, void *private_data, int atomic, int hop); 109int snd_seq_oss_event_input(struct snd_seq_event *ev, int direct, void *private_data, int atomic, int hop);
110 110
111 111
112#endif /* __SEQ_OSS_EVENT_H */ 112#endif /* __SEQ_OSS_EVENT_H */
diff --git a/sound/core/seq/oss/seq_oss_init.c b/sound/core/seq/oss/seq_oss_init.c
index 1ab1cf8158c8..1d4473eadcf3 100644
--- a/sound/core/seq/oss/seq_oss_init.c
+++ b/sound/core/seq/oss/seq_oss_init.c
@@ -41,17 +41,17 @@ static int system_client = -1; /* ALSA sequencer client number */
41static int system_port = -1; 41static int system_port = -1;
42 42
43static int num_clients; 43static int num_clients;
44static seq_oss_devinfo_t *client_table[SNDRV_SEQ_OSS_MAX_CLIENTS]; 44static struct seq_oss_devinfo *client_table[SNDRV_SEQ_OSS_MAX_CLIENTS];
45 45
46 46
47/* 47/*
48 * prototypes 48 * prototypes
49 */ 49 */
50static int receive_announce(snd_seq_event_t *ev, int direct, void *private, int atomic, int hop); 50static int receive_announce(struct snd_seq_event *ev, int direct, void *private, int atomic, int hop);
51static int translate_mode(struct file *file); 51static int translate_mode(struct file *file);
52static int create_port(seq_oss_devinfo_t *dp); 52static int create_port(struct seq_oss_devinfo *dp);
53static int delete_port(seq_oss_devinfo_t *dp); 53static int delete_port(struct seq_oss_devinfo *dp);
54static int alloc_seq_queue(seq_oss_devinfo_t *dp); 54static int alloc_seq_queue(struct seq_oss_devinfo *dp);
55static int delete_seq_queue(int queue); 55static int delete_seq_queue(int queue);
56static void free_devinfo(void *private); 56static void free_devinfo(void *private);
57 57
@@ -65,10 +65,10 @@ int __init
65snd_seq_oss_create_client(void) 65snd_seq_oss_create_client(void)
66{ 66{
67 int rc; 67 int rc;
68 snd_seq_client_callback_t callback; 68 struct snd_seq_client_callback callback;
69 snd_seq_client_info_t *info; 69 struct snd_seq_client_info *info;
70 snd_seq_port_info_t *port; 70 struct snd_seq_port_info *port;
71 snd_seq_port_callback_t port_callback; 71 struct snd_seq_port_callback port_callback;
72 72
73 info = kmalloc(sizeof(*info), GFP_KERNEL); 73 info = kmalloc(sizeof(*info), GFP_KERNEL);
74 port = kmalloc(sizeof(*port), GFP_KERNEL); 74 port = kmalloc(sizeof(*port), GFP_KERNEL);
@@ -118,7 +118,7 @@ snd_seq_oss_create_client(void)
118 118
119 call_ctl(SNDRV_SEQ_IOCTL_CREATE_PORT, port); 119 call_ctl(SNDRV_SEQ_IOCTL_CREATE_PORT, port);
120 if ((system_port = port->addr.port) >= 0) { 120 if ((system_port = port->addr.port) >= 0) {
121 snd_seq_port_subscribe_t subs; 121 struct snd_seq_port_subscribe subs;
122 122
123 memset(&subs, 0, sizeof(subs)); 123 memset(&subs, 0, sizeof(subs));
124 subs.sender.client = SNDRV_SEQ_CLIENT_SYSTEM; 124 subs.sender.client = SNDRV_SEQ_CLIENT_SYSTEM;
@@ -140,9 +140,9 @@ snd_seq_oss_create_client(void)
140 * receive annoucement from system port, and check the midi device 140 * receive annoucement from system port, and check the midi device
141 */ 141 */
142static int 142static int
143receive_announce(snd_seq_event_t *ev, int direct, void *private, int atomic, int hop) 143receive_announce(struct snd_seq_event *ev, int direct, void *private, int atomic, int hop)
144{ 144{
145 snd_seq_port_info_t pinfo; 145 struct snd_seq_port_info pinfo;
146 146
147 if (atomic) 147 if (atomic)
148 return 0; /* it must not happen */ 148 return 0; /* it must not happen */
@@ -191,7 +191,7 @@ int
191snd_seq_oss_open(struct file *file, int level) 191snd_seq_oss_open(struct file *file, int level)
192{ 192{
193 int i, rc; 193 int i, rc;
194 seq_oss_devinfo_t *dp; 194 struct seq_oss_devinfo *dp;
195 195
196 if ((dp = kzalloc(sizeof(*dp), GFP_KERNEL)) == NULL) { 196 if ((dp = kzalloc(sizeof(*dp), GFP_KERNEL)) == NULL) {
197 snd_printk(KERN_ERR "can't malloc device info\n"); 197 snd_printk(KERN_ERR "can't malloc device info\n");
@@ -323,11 +323,11 @@ translate_mode(struct file *file)
323 * create sequencer port 323 * create sequencer port
324 */ 324 */
325static int 325static int
326create_port(seq_oss_devinfo_t *dp) 326create_port(struct seq_oss_devinfo *dp)
327{ 327{
328 int rc; 328 int rc;
329 snd_seq_port_info_t port; 329 struct snd_seq_port_info port;
330 snd_seq_port_callback_t callback; 330 struct snd_seq_port_callback callback;
331 331
332 memset(&port, 0, sizeof(port)); 332 memset(&port, 0, sizeof(port));
333 port.addr.client = dp->cseq; 333 port.addr.client = dp->cseq;
@@ -358,7 +358,7 @@ create_port(seq_oss_devinfo_t *dp)
358 * delete ALSA port 358 * delete ALSA port
359 */ 359 */
360static int 360static int
361delete_port(seq_oss_devinfo_t *dp) 361delete_port(struct seq_oss_devinfo *dp)
362{ 362{
363 if (dp->port < 0) 363 if (dp->port < 0)
364 return 0; 364 return 0;
@@ -371,9 +371,9 @@ delete_port(seq_oss_devinfo_t *dp)
371 * allocate a queue 371 * allocate a queue
372 */ 372 */
373static int 373static int
374alloc_seq_queue(seq_oss_devinfo_t *dp) 374alloc_seq_queue(struct seq_oss_devinfo *dp)
375{ 375{
376 snd_seq_queue_info_t qinfo; 376 struct snd_seq_queue_info qinfo;
377 int rc; 377 int rc;
378 378
379 memset(&qinfo, 0, sizeof(qinfo)); 379 memset(&qinfo, 0, sizeof(qinfo));
@@ -392,7 +392,7 @@ alloc_seq_queue(seq_oss_devinfo_t *dp)
392static int 392static int
393delete_seq_queue(int queue) 393delete_seq_queue(int queue)
394{ 394{
395 snd_seq_queue_info_t qinfo; 395 struct snd_seq_queue_info qinfo;
396 int rc; 396 int rc;
397 397
398 if (queue < 0) 398 if (queue < 0)
@@ -412,7 +412,7 @@ delete_seq_queue(int queue)
412static void 412static void
413free_devinfo(void *private) 413free_devinfo(void *private)
414{ 414{
415 seq_oss_devinfo_t *dp = (seq_oss_devinfo_t *)private; 415 struct seq_oss_devinfo *dp = (struct seq_oss_devinfo *)private;
416 416
417 if (dp->timer) 417 if (dp->timer)
418 snd_seq_oss_timer_delete(dp->timer); 418 snd_seq_oss_timer_delete(dp->timer);
@@ -431,7 +431,7 @@ free_devinfo(void *private)
431 * close sequencer device 431 * close sequencer device
432 */ 432 */
433void 433void
434snd_seq_oss_release(seq_oss_devinfo_t *dp) 434snd_seq_oss_release(struct seq_oss_devinfo *dp)
435{ 435{
436 int queue; 436 int queue;
437 437
@@ -460,7 +460,7 @@ snd_seq_oss_release(seq_oss_devinfo_t *dp)
460 * Wait until the queue is empty (if we don't have nonblock) 460 * Wait until the queue is empty (if we don't have nonblock)
461 */ 461 */
462void 462void
463snd_seq_oss_drain_write(seq_oss_devinfo_t *dp) 463snd_seq_oss_drain_write(struct seq_oss_devinfo *dp)
464{ 464{
465 if (! dp->timer->running) 465 if (! dp->timer->running)
466 return; 466 return;
@@ -477,7 +477,7 @@ snd_seq_oss_drain_write(seq_oss_devinfo_t *dp)
477 * reset sequencer devices 477 * reset sequencer devices
478 */ 478 */
479void 479void
480snd_seq_oss_reset(seq_oss_devinfo_t *dp) 480snd_seq_oss_reset(struct seq_oss_devinfo *dp)
481{ 481{
482 int i; 482 int i;
483 483
@@ -525,10 +525,10 @@ filemode_str(int val)
525 * proc interface 525 * proc interface
526 */ 526 */
527void 527void
528snd_seq_oss_system_info_read(snd_info_buffer_t *buf) 528snd_seq_oss_system_info_read(struct snd_info_buffer *buf)
529{ 529{
530 int i; 530 int i;
531 seq_oss_devinfo_t *dp; 531 struct seq_oss_devinfo *dp;
532 532
533 snd_iprintf(buf, "ALSA client number %d\n", system_client); 533 snd_iprintf(buf, "ALSA client number %d\n", system_client);
534 snd_iprintf(buf, "ALSA receiver port %d\n", system_port); 534 snd_iprintf(buf, "ALSA receiver port %d\n", system_port);
diff --git a/sound/core/seq/oss/seq_oss_ioctl.c b/sound/core/seq/oss/seq_oss_ioctl.c
index e86f18d00f39..5ac701c903c1 100644
--- a/sound/core/seq/oss/seq_oss_ioctl.c
+++ b/sound/core/seq/oss/seq_oss_ioctl.c
@@ -28,7 +28,7 @@
28#include "seq_oss_midi.h" 28#include "seq_oss_midi.h"
29#include "seq_oss_event.h" 29#include "seq_oss_event.h"
30 30
31static int snd_seq_oss_synth_info_user(seq_oss_devinfo_t *dp, void __user *arg) 31static int snd_seq_oss_synth_info_user(struct seq_oss_devinfo *dp, void __user *arg)
32{ 32{
33 struct synth_info info; 33 struct synth_info info;
34 34
@@ -41,7 +41,7 @@ static int snd_seq_oss_synth_info_user(seq_oss_devinfo_t *dp, void __user *arg)
41 return 0; 41 return 0;
42} 42}
43 43
44static int snd_seq_oss_midi_info_user(seq_oss_devinfo_t *dp, void __user *arg) 44static int snd_seq_oss_midi_info_user(struct seq_oss_devinfo *dp, void __user *arg)
45{ 45{
46 struct midi_info info; 46 struct midi_info info;
47 47
@@ -54,24 +54,24 @@ static int snd_seq_oss_midi_info_user(seq_oss_devinfo_t *dp, void __user *arg)
54 return 0; 54 return 0;
55} 55}
56 56
57static int snd_seq_oss_oob_user(seq_oss_devinfo_t *dp, void __user *arg) 57static int snd_seq_oss_oob_user(struct seq_oss_devinfo *dp, void __user *arg)
58{ 58{
59 unsigned char ev[8]; 59 unsigned char ev[8];
60 snd_seq_event_t tmpev; 60 struct snd_seq_event tmpev;
61 61
62 if (copy_from_user(ev, arg, 8)) 62 if (copy_from_user(ev, arg, 8))
63 return -EFAULT; 63 return -EFAULT;
64 memset(&tmpev, 0, sizeof(tmpev)); 64 memset(&tmpev, 0, sizeof(tmpev));
65 snd_seq_oss_fill_addr(dp, &tmpev, dp->addr.port, dp->addr.client); 65 snd_seq_oss_fill_addr(dp, &tmpev, dp->addr.port, dp->addr.client);
66 tmpev.time.tick = 0; 66 tmpev.time.tick = 0;
67 if (! snd_seq_oss_process_event(dp, (evrec_t*)ev, &tmpev)) { 67 if (! snd_seq_oss_process_event(dp, (union evrec *)ev, &tmpev)) {
68 snd_seq_oss_dispatch(dp, &tmpev, 0, 0); 68 snd_seq_oss_dispatch(dp, &tmpev, 0, 0);
69 } 69 }
70 return 0; 70 return 0;
71} 71}
72 72
73int 73int
74snd_seq_oss_ioctl(seq_oss_devinfo_t *dp, unsigned int cmd, unsigned long carg) 74snd_seq_oss_ioctl(struct seq_oss_devinfo *dp, unsigned int cmd, unsigned long carg)
75{ 75{
76 int dev, val; 76 int dev, val;
77 void __user *arg = (void __user *)carg; 77 void __user *arg = (void __user *)carg;
diff --git a/sound/core/seq/oss/seq_oss_midi.c b/sound/core/seq/oss/seq_oss_midi.c
index f0e95c8f2eef..eb7ae990965c 100644
--- a/sound/core/seq/oss/seq_oss_midi.c
+++ b/sound/core/seq/oss/seq_oss_midi.c
@@ -37,15 +37,15 @@
37/* 37/*
38 * definition of midi device record 38 * definition of midi device record
39 */ 39 */
40struct seq_oss_midi_t { 40struct seq_oss_midi {
41 int seq_device; /* device number */ 41 int seq_device; /* device number */
42 int client; /* sequencer client number */ 42 int client; /* sequencer client number */
43 int port; /* sequencer port number */ 43 int port; /* sequencer port number */
44 unsigned int flags; /* port capability */ 44 unsigned int flags; /* port capability */
45 int opened; /* flag for opening */ 45 int opened; /* flag for opening */
46 unsigned char name[SNDRV_SEQ_OSS_MAX_MIDI_NAME]; 46 unsigned char name[SNDRV_SEQ_OSS_MAX_MIDI_NAME];
47 snd_midi_event_t *coder; /* MIDI event coder */ 47 struct snd_midi_event *coder; /* MIDI event coder */
48 seq_oss_devinfo_t *devinfo; /* assigned OSSseq device */ 48 struct seq_oss_devinfo *devinfo; /* assigned OSSseq device */
49 snd_use_lock_t use_lock; 49 snd_use_lock_t use_lock;
50}; 50};
51 51
@@ -54,17 +54,17 @@ struct seq_oss_midi_t {
54 * midi device table 54 * midi device table
55 */ 55 */
56static int max_midi_devs; 56static int max_midi_devs;
57static seq_oss_midi_t *midi_devs[SNDRV_SEQ_OSS_MAX_MIDI_DEVS]; 57static struct seq_oss_midi *midi_devs[SNDRV_SEQ_OSS_MAX_MIDI_DEVS];
58 58
59static DEFINE_SPINLOCK(register_lock); 59static DEFINE_SPINLOCK(register_lock);
60 60
61/* 61/*
62 * prototypes 62 * prototypes
63 */ 63 */
64static seq_oss_midi_t *get_mdev(int dev); 64static struct seq_oss_midi *get_mdev(int dev);
65static seq_oss_midi_t *get_mididev(seq_oss_devinfo_t *dp, int dev); 65static struct seq_oss_midi *get_mididev(struct seq_oss_devinfo *dp, int dev);
66static int send_synth_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, int dev); 66static int send_synth_event(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, int dev);
67static int send_midi_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, seq_oss_midi_t *mdev); 67static int send_midi_event(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, struct seq_oss_midi *mdev);
68 68
69/* 69/*
70 * look up the existing ports 70 * look up the existing ports
@@ -73,8 +73,8 @@ static int send_midi_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, seq_oss_m
73int __init 73int __init
74snd_seq_oss_midi_lookup_ports(int client) 74snd_seq_oss_midi_lookup_ports(int client)
75{ 75{
76 snd_seq_client_info_t *clinfo; 76 struct snd_seq_client_info *clinfo;
77 snd_seq_port_info_t *pinfo; 77 struct snd_seq_port_info *pinfo;
78 78
79 clinfo = kzalloc(sizeof(*clinfo), GFP_KERNEL); 79 clinfo = kzalloc(sizeof(*clinfo), GFP_KERNEL);
80 pinfo = kzalloc(sizeof(*pinfo), GFP_KERNEL); 80 pinfo = kzalloc(sizeof(*pinfo), GFP_KERNEL);
@@ -100,10 +100,10 @@ snd_seq_oss_midi_lookup_ports(int client)
100 100
101/* 101/*
102 */ 102 */
103static seq_oss_midi_t * 103static struct seq_oss_midi *
104get_mdev(int dev) 104get_mdev(int dev)
105{ 105{
106 seq_oss_midi_t *mdev; 106 struct seq_oss_midi *mdev;
107 unsigned long flags; 107 unsigned long flags;
108 108
109 spin_lock_irqsave(&register_lock, flags); 109 spin_lock_irqsave(&register_lock, flags);
@@ -117,11 +117,11 @@ get_mdev(int dev)
117/* 117/*
118 * look for the identical slot 118 * look for the identical slot
119 */ 119 */
120static seq_oss_midi_t * 120static struct seq_oss_midi *
121find_slot(int client, int port) 121find_slot(int client, int port)
122{ 122{
123 int i; 123 int i;
124 seq_oss_midi_t *mdev; 124 struct seq_oss_midi *mdev;
125 unsigned long flags; 125 unsigned long flags;
126 126
127 spin_lock_irqsave(&register_lock, flags); 127 spin_lock_irqsave(&register_lock, flags);
@@ -145,10 +145,10 @@ find_slot(int client, int port)
145 * register a new port if it doesn't exist yet 145 * register a new port if it doesn't exist yet
146 */ 146 */
147int 147int
148snd_seq_oss_midi_check_new_port(snd_seq_port_info_t *pinfo) 148snd_seq_oss_midi_check_new_port(struct snd_seq_port_info *pinfo)
149{ 149{
150 int i; 150 int i;
151 seq_oss_midi_t *mdev; 151 struct seq_oss_midi *mdev;
152 unsigned long flags; 152 unsigned long flags;
153 153
154 debug_printk(("check for MIDI client %d port %d\n", pinfo->addr.client, pinfo->addr.port)); 154 debug_printk(("check for MIDI client %d port %d\n", pinfo->addr.client, pinfo->addr.port));
@@ -226,7 +226,7 @@ snd_seq_oss_midi_check_new_port(snd_seq_port_info_t *pinfo)
226int 226int
227snd_seq_oss_midi_check_exit_port(int client, int port) 227snd_seq_oss_midi_check_exit_port(int client, int port)
228{ 228{
229 seq_oss_midi_t *mdev; 229 struct seq_oss_midi *mdev;
230 unsigned long flags; 230 unsigned long flags;
231 int index; 231 int index;
232 232
@@ -258,7 +258,7 @@ void
258snd_seq_oss_midi_clear_all(void) 258snd_seq_oss_midi_clear_all(void)
259{ 259{
260 int i; 260 int i;
261 seq_oss_midi_t *mdev; 261 struct seq_oss_midi *mdev;
262 unsigned long flags; 262 unsigned long flags;
263 263
264 spin_lock_irqsave(&register_lock, flags); 264 spin_lock_irqsave(&register_lock, flags);
@@ -279,7 +279,7 @@ snd_seq_oss_midi_clear_all(void)
279 * set up midi tables 279 * set up midi tables
280 */ 280 */
281void 281void
282snd_seq_oss_midi_setup(seq_oss_devinfo_t *dp) 282snd_seq_oss_midi_setup(struct seq_oss_devinfo *dp)
283{ 283{
284 dp->max_mididev = max_midi_devs; 284 dp->max_mididev = max_midi_devs;
285} 285}
@@ -288,7 +288,7 @@ snd_seq_oss_midi_setup(seq_oss_devinfo_t *dp)
288 * clean up midi tables 288 * clean up midi tables
289 */ 289 */
290void 290void
291snd_seq_oss_midi_cleanup(seq_oss_devinfo_t *dp) 291snd_seq_oss_midi_cleanup(struct seq_oss_devinfo *dp)
292{ 292{
293 int i; 293 int i;
294 for (i = 0; i < dp->max_mididev; i++) 294 for (i = 0; i < dp->max_mididev; i++)
@@ -301,7 +301,7 @@ snd_seq_oss_midi_cleanup(seq_oss_devinfo_t *dp)
301 * open all midi devices. ignore errors. 301 * open all midi devices. ignore errors.
302 */ 302 */
303void 303void
304snd_seq_oss_midi_open_all(seq_oss_devinfo_t *dp, int file_mode) 304snd_seq_oss_midi_open_all(struct seq_oss_devinfo *dp, int file_mode)
305{ 305{
306 int i; 306 int i;
307 for (i = 0; i < dp->max_mididev; i++) 307 for (i = 0; i < dp->max_mididev; i++)
@@ -312,8 +312,8 @@ snd_seq_oss_midi_open_all(seq_oss_devinfo_t *dp, int file_mode)
312/* 312/*
313 * get the midi device information 313 * get the midi device information
314 */ 314 */
315static seq_oss_midi_t * 315static struct seq_oss_midi *
316get_mididev(seq_oss_devinfo_t *dp, int dev) 316get_mididev(struct seq_oss_devinfo *dp, int dev)
317{ 317{
318 if (dev < 0 || dev >= dp->max_mididev) 318 if (dev < 0 || dev >= dp->max_mididev)
319 return NULL; 319 return NULL;
@@ -325,11 +325,11 @@ get_mididev(seq_oss_devinfo_t *dp, int dev)
325 * open the midi device if not opened yet 325 * open the midi device if not opened yet
326 */ 326 */
327int 327int
328snd_seq_oss_midi_open(seq_oss_devinfo_t *dp, int dev, int fmode) 328snd_seq_oss_midi_open(struct seq_oss_devinfo *dp, int dev, int fmode)
329{ 329{
330 int perm; 330 int perm;
331 seq_oss_midi_t *mdev; 331 struct seq_oss_midi *mdev;
332 snd_seq_port_subscribe_t subs; 332 struct snd_seq_port_subscribe subs;
333 333
334 if ((mdev = get_mididev(dp, dev)) == NULL) 334 if ((mdev = get_mididev(dp, dev)) == NULL)
335 return -ENODEV; 335 return -ENODEV;
@@ -392,10 +392,10 @@ snd_seq_oss_midi_open(seq_oss_devinfo_t *dp, int dev, int fmode)
392 * close the midi device if already opened 392 * close the midi device if already opened
393 */ 393 */
394int 394int
395snd_seq_oss_midi_close(seq_oss_devinfo_t *dp, int dev) 395snd_seq_oss_midi_close(struct seq_oss_devinfo *dp, int dev)
396{ 396{
397 seq_oss_midi_t *mdev; 397 struct seq_oss_midi *mdev;
398 snd_seq_port_subscribe_t subs; 398 struct snd_seq_port_subscribe subs;
399 399
400 if ((mdev = get_mididev(dp, dev)) == NULL) 400 if ((mdev = get_mididev(dp, dev)) == NULL)
401 return -ENODEV; 401 return -ENODEV;
@@ -430,9 +430,9 @@ snd_seq_oss_midi_close(seq_oss_devinfo_t *dp, int dev)
430 * change seq capability flags to file mode flags 430 * change seq capability flags to file mode flags
431 */ 431 */
432int 432int
433snd_seq_oss_midi_filemode(seq_oss_devinfo_t *dp, int dev) 433snd_seq_oss_midi_filemode(struct seq_oss_devinfo *dp, int dev)
434{ 434{
435 seq_oss_midi_t *mdev; 435 struct seq_oss_midi *mdev;
436 int mode; 436 int mode;
437 437
438 if ((mdev = get_mididev(dp, dev)) == NULL) 438 if ((mdev = get_mididev(dp, dev)) == NULL)
@@ -453,9 +453,9 @@ snd_seq_oss_midi_filemode(seq_oss_devinfo_t *dp, int dev)
453 * so far, only close the device. 453 * so far, only close the device.
454 */ 454 */
455void 455void
456snd_seq_oss_midi_reset(seq_oss_devinfo_t *dp, int dev) 456snd_seq_oss_midi_reset(struct seq_oss_devinfo *dp, int dev)
457{ 457{
458 seq_oss_midi_t *mdev; 458 struct seq_oss_midi *mdev;
459 459
460 if ((mdev = get_mididev(dp, dev)) == NULL) 460 if ((mdev = get_mididev(dp, dev)) == NULL)
461 return; 461 return;
@@ -465,7 +465,7 @@ snd_seq_oss_midi_reset(seq_oss_devinfo_t *dp, int dev)
465 } 465 }
466 466
467 if (mdev->opened & PERM_WRITE) { 467 if (mdev->opened & PERM_WRITE) {
468 snd_seq_event_t ev; 468 struct snd_seq_event ev;
469 int c; 469 int c;
470 470
471 debug_printk(("resetting client %d port %d\n", mdev->client, mdev->port)); 471 debug_printk(("resetting client %d port %d\n", mdev->client, mdev->port));
@@ -501,9 +501,9 @@ snd_seq_oss_midi_reset(seq_oss_devinfo_t *dp, int dev)
501 * get client/port of the specified MIDI device 501 * get client/port of the specified MIDI device
502 */ 502 */
503void 503void
504snd_seq_oss_midi_get_addr(seq_oss_devinfo_t *dp, int dev, snd_seq_addr_t *addr) 504snd_seq_oss_midi_get_addr(struct seq_oss_devinfo *dp, int dev, struct snd_seq_addr *addr)
505{ 505{
506 seq_oss_midi_t *mdev; 506 struct seq_oss_midi *mdev;
507 507
508 if ((mdev = get_mididev(dp, dev)) == NULL) 508 if ((mdev = get_mididev(dp, dev)) == NULL)
509 return; 509 return;
@@ -517,10 +517,10 @@ snd_seq_oss_midi_get_addr(seq_oss_devinfo_t *dp, int dev, snd_seq_addr_t *addr)
517 * input callback - this can be atomic 517 * input callback - this can be atomic
518 */ 518 */
519int 519int
520snd_seq_oss_midi_input(snd_seq_event_t *ev, int direct, void *private_data) 520snd_seq_oss_midi_input(struct snd_seq_event *ev, int direct, void *private_data)
521{ 521{
522 seq_oss_devinfo_t *dp = (seq_oss_devinfo_t *)private_data; 522 struct seq_oss_devinfo *dp = (struct seq_oss_devinfo *)private_data;
523 seq_oss_midi_t *mdev; 523 struct seq_oss_midi *mdev;
524 int rc; 524 int rc;
525 525
526 if (dp->readq == NULL) 526 if (dp->readq == NULL)
@@ -545,9 +545,9 @@ snd_seq_oss_midi_input(snd_seq_event_t *ev, int direct, void *private_data)
545 * convert ALSA sequencer event to OSS synth event 545 * convert ALSA sequencer event to OSS synth event
546 */ 546 */
547static int 547static int
548send_synth_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, int dev) 548send_synth_event(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, int dev)
549{ 549{
550 evrec_t ossev; 550 union evrec ossev;
551 551
552 memset(&ossev, 0, sizeof(ossev)); 552 memset(&ossev, 0, sizeof(ossev));
553 553
@@ -606,7 +606,7 @@ send_synth_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, int dev)
606 * decode event and send MIDI bytes to read queue 606 * decode event and send MIDI bytes to read queue
607 */ 607 */
608static int 608static int
609send_midi_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, seq_oss_midi_t *mdev) 609send_midi_event(struct seq_oss_devinfo *dp, struct snd_seq_event *ev, struct seq_oss_midi *mdev)
610{ 610{
611 char msg[32]; 611 char msg[32];
612 int len; 612 int len;
@@ -634,9 +634,9 @@ send_midi_event(seq_oss_devinfo_t *dp, snd_seq_event_t *ev, seq_oss_midi_t *mdev
634 * non-zero : invalid - ignored 634 * non-zero : invalid - ignored
635 */ 635 */
636int 636int
637snd_seq_oss_midi_putc(seq_oss_devinfo_t *dp, int dev, unsigned char c, snd_seq_event_t *ev) 637snd_seq_oss_midi_putc(struct seq_oss_devinfo *dp, int dev, unsigned char c, struct snd_seq_event *ev)
638{ 638{
639 seq_oss_midi_t *mdev; 639 struct seq_oss_midi *mdev;
640 640
641 if ((mdev = get_mididev(dp, dev)) == NULL) 641 if ((mdev = get_mididev(dp, dev)) == NULL)
642 return -ENODEV; 642 return -ENODEV;
@@ -653,9 +653,9 @@ snd_seq_oss_midi_putc(seq_oss_devinfo_t *dp, int dev, unsigned char c, snd_seq_e
653 * create OSS compatible midi_info record 653 * create OSS compatible midi_info record
654 */ 654 */
655int 655int
656snd_seq_oss_midi_make_info(seq_oss_devinfo_t *dp, int dev, struct midi_info *inf) 656snd_seq_oss_midi_make_info(struct seq_oss_devinfo *dp, int dev, struct midi_info *inf)
657{ 657{
658 seq_oss_midi_t *mdev; 658 struct seq_oss_midi *mdev;
659 659
660 if ((mdev = get_mididev(dp, dev)) == NULL) 660 if ((mdev = get_mididev(dp, dev)) == NULL)
661 return -ENXIO; 661 return -ENXIO;
@@ -686,10 +686,10 @@ capmode_str(int val)
686} 686}
687 687
688void 688void
689snd_seq_oss_midi_info_read(snd_info_buffer_t *buf) 689snd_seq_oss_midi_info_read(struct snd_info_buffer *buf)
690{ 690{
691 int i; 691 int i;
692 seq_oss_midi_t *mdev; 692 struct seq_oss_midi *mdev;
693 693
694 snd_iprintf(buf, "\nNumber of MIDI devices: %d\n", max_midi_devs); 694 snd_iprintf(buf, "\nNumber of MIDI devices: %d\n", max_midi_devs);
695 for (i = 0; i < max_midi_devs; i++) { 695 for (i = 0; i < max_midi_devs; i++) {
diff --git a/sound/core/seq/oss/seq_oss_midi.h b/sound/core/seq/oss/seq_oss_midi.h
index 462484b2b6fe..84eb866ba58e 100644
--- a/sound/core/seq/oss/seq_oss_midi.h
+++ b/sound/core/seq/oss/seq_oss_midi.h
@@ -26,24 +26,23 @@
26#include "seq_oss_device.h" 26#include "seq_oss_device.h"
27#include <sound/seq_oss_legacy.h> 27#include <sound/seq_oss_legacy.h>
28 28
29typedef struct seq_oss_midi_t seq_oss_midi_t;
30
31int snd_seq_oss_midi_lookup_ports(int client); 29int snd_seq_oss_midi_lookup_ports(int client);
32int snd_seq_oss_midi_check_new_port(snd_seq_port_info_t *pinfo); 30int snd_seq_oss_midi_check_new_port(struct snd_seq_port_info *pinfo);
33int snd_seq_oss_midi_check_exit_port(int client, int port); 31int snd_seq_oss_midi_check_exit_port(int client, int port);
34void snd_seq_oss_midi_clear_all(void); 32void snd_seq_oss_midi_clear_all(void);
35 33
36void snd_seq_oss_midi_setup(seq_oss_devinfo_t *dp); 34void snd_seq_oss_midi_setup(struct seq_oss_devinfo *dp);
37void snd_seq_oss_midi_cleanup(seq_oss_devinfo_t *dp); 35void snd_seq_oss_midi_cleanup(struct seq_oss_devinfo *dp);
38 36
39int snd_seq_oss_midi_open(seq_oss_devinfo_t *dp, int dev, int file_mode); 37int snd_seq_oss_midi_open(struct seq_oss_devinfo *dp, int dev, int file_mode);
40void snd_seq_oss_midi_open_all(seq_oss_devinfo_t *dp, int file_mode); 38void snd_seq_oss_midi_open_all(struct seq_oss_devinfo *dp, int file_mode);
41int snd_seq_oss_midi_close(seq_oss_devinfo_t *dp, int dev); 39int snd_seq_oss_midi_close(struct seq_oss_devinfo *dp, int dev);
42void snd_seq_oss_midi_reset(seq_oss_devinfo_t *dp, int dev); 40void snd_seq_oss_midi_reset(struct seq_oss_devinfo *dp, int dev);
43int snd_seq_oss_midi_putc(seq_oss_devinfo_t *dp, int dev, unsigned char c, snd_seq_event_t *ev); 41int snd_seq_oss_midi_putc(struct seq_oss_devinfo *dp, int dev, unsigned char c,
44int snd_seq_oss_midi_input(snd_seq_event_t *ev, int direct, void *private); 42 struct snd_seq_event *ev);
45int snd_seq_oss_midi_filemode(seq_oss_devinfo_t *dp, int dev); 43int snd_seq_oss_midi_input(struct snd_seq_event *ev, int direct, void *private);
46int snd_seq_oss_midi_make_info(seq_oss_devinfo_t *dp, int dev, struct midi_info *inf); 44int snd_seq_oss_midi_filemode(struct seq_oss_devinfo *dp, int dev);
47void snd_seq_oss_midi_get_addr(seq_oss_devinfo_t *dp, int dev, snd_seq_addr_t *addr); 45int snd_seq_oss_midi_make_info(struct seq_oss_devinfo *dp, int dev, struct midi_info *inf);
46void snd_seq_oss_midi_get_addr(struct seq_oss_devinfo *dp, int dev, struct snd_seq_addr *addr);
48 47
49#endif 48#endif
diff --git a/sound/core/seq/oss/seq_oss_readq.c b/sound/core/seq/oss/seq_oss_readq.c
index 55571e15cd38..abc70078add3 100644
--- a/sound/core/seq/oss/seq_oss_readq.c
+++ b/sound/core/seq/oss/seq_oss_readq.c
@@ -41,17 +41,17 @@
41/* 41/*
42 * create a read queue 42 * create a read queue
43 */ 43 */
44seq_oss_readq_t * 44struct seq_oss_readq *
45snd_seq_oss_readq_new(seq_oss_devinfo_t *dp, int maxlen) 45snd_seq_oss_readq_new(struct seq_oss_devinfo *dp, int maxlen)
46{ 46{
47 seq_oss_readq_t *q; 47 struct seq_oss_readq *q;
48 48
49 if ((q = kzalloc(sizeof(*q), GFP_KERNEL)) == NULL) { 49 if ((q = kzalloc(sizeof(*q), GFP_KERNEL)) == NULL) {
50 snd_printk(KERN_ERR "can't malloc read queue\n"); 50 snd_printk(KERN_ERR "can't malloc read queue\n");
51 return NULL; 51 return NULL;
52 } 52 }
53 53
54 if ((q->q = kcalloc(maxlen, sizeof(evrec_t), GFP_KERNEL)) == NULL) { 54 if ((q->q = kcalloc(maxlen, sizeof(union evrec), GFP_KERNEL)) == NULL) {
55 snd_printk(KERN_ERR "can't malloc read queue buffer\n"); 55 snd_printk(KERN_ERR "can't malloc read queue buffer\n");
56 kfree(q); 56 kfree(q);
57 return NULL; 57 return NULL;
@@ -72,7 +72,7 @@ snd_seq_oss_readq_new(seq_oss_devinfo_t *dp, int maxlen)
72 * delete the read queue 72 * delete the read queue
73 */ 73 */
74void 74void
75snd_seq_oss_readq_delete(seq_oss_readq_t *q) 75snd_seq_oss_readq_delete(struct seq_oss_readq *q)
76{ 76{
77 if (q) { 77 if (q) {
78 kfree(q->q); 78 kfree(q->q);
@@ -84,7 +84,7 @@ snd_seq_oss_readq_delete(seq_oss_readq_t *q)
84 * reset the read queue 84 * reset the read queue
85 */ 85 */
86void 86void
87snd_seq_oss_readq_clear(seq_oss_readq_t *q) 87snd_seq_oss_readq_clear(struct seq_oss_readq *q)
88{ 88{
89 if (q->qlen) { 89 if (q->qlen) {
90 q->qlen = 0; 90 q->qlen = 0;
@@ -100,9 +100,9 @@ snd_seq_oss_readq_clear(seq_oss_readq_t *q)
100 * put a midi byte 100 * put a midi byte
101 */ 101 */
102int 102int
103snd_seq_oss_readq_puts(seq_oss_readq_t *q, int dev, unsigned char *data, int len) 103snd_seq_oss_readq_puts(struct seq_oss_readq *q, int dev, unsigned char *data, int len)
104{ 104{
105 evrec_t rec; 105 union evrec rec;
106 int result; 106 int result;
107 107
108 memset(&rec, 0, sizeof(rec)); 108 memset(&rec, 0, sizeof(rec));
@@ -123,7 +123,7 @@ snd_seq_oss_readq_puts(seq_oss_readq_t *q, int dev, unsigned char *data, int len
123 * return zero if enqueued 123 * return zero if enqueued
124 */ 124 */
125int 125int
126snd_seq_oss_readq_put_event(seq_oss_readq_t *q, evrec_t *ev) 126snd_seq_oss_readq_put_event(struct seq_oss_readq *q, union evrec *ev)
127{ 127{
128 unsigned long flags; 128 unsigned long flags;
129 129
@@ -152,7 +152,7 @@ snd_seq_oss_readq_put_event(seq_oss_readq_t *q, evrec_t *ev)
152 * caller must hold lock 152 * caller must hold lock
153 */ 153 */
154int 154int
155snd_seq_oss_readq_pick(seq_oss_readq_t *q, evrec_t *rec) 155snd_seq_oss_readq_pick(struct seq_oss_readq *q, union evrec *rec)
156{ 156{
157 if (q->qlen == 0) 157 if (q->qlen == 0)
158 return -EAGAIN; 158 return -EAGAIN;
@@ -164,7 +164,7 @@ snd_seq_oss_readq_pick(seq_oss_readq_t *q, evrec_t *rec)
164 * sleep until ready 164 * sleep until ready
165 */ 165 */
166void 166void
167snd_seq_oss_readq_wait(seq_oss_readq_t *q) 167snd_seq_oss_readq_wait(struct seq_oss_readq *q)
168{ 168{
169 wait_event_interruptible_timeout(q->midi_sleep, 169 wait_event_interruptible_timeout(q->midi_sleep,
170 (q->qlen > 0 || q->head == q->tail), 170 (q->qlen > 0 || q->head == q->tail),
@@ -176,7 +176,7 @@ snd_seq_oss_readq_wait(seq_oss_readq_t *q)
176 * caller must hold lock 176 * caller must hold lock
177 */ 177 */
178void 178void
179snd_seq_oss_readq_free(seq_oss_readq_t *q) 179snd_seq_oss_readq_free(struct seq_oss_readq *q)
180{ 180{
181 if (q->qlen > 0) { 181 if (q->qlen > 0) {
182 q->head = (q->head + 1) % q->maxlen; 182 q->head = (q->head + 1) % q->maxlen;
@@ -189,7 +189,7 @@ snd_seq_oss_readq_free(seq_oss_readq_t *q)
189 * return non-zero if readq is not empty. 189 * return non-zero if readq is not empty.
190 */ 190 */
191unsigned int 191unsigned int
192snd_seq_oss_readq_poll(seq_oss_readq_t *q, struct file *file, poll_table *wait) 192snd_seq_oss_readq_poll(struct seq_oss_readq *q, struct file *file, poll_table *wait)
193{ 193{
194 poll_wait(file, &q->midi_sleep, wait); 194 poll_wait(file, &q->midi_sleep, wait);
195 return q->qlen; 195 return q->qlen;
@@ -199,10 +199,10 @@ snd_seq_oss_readq_poll(seq_oss_readq_t *q, struct file *file, poll_table *wait)
199 * put a timestamp 199 * put a timestamp
200 */ 200 */
201int 201int
202snd_seq_oss_readq_put_timestamp(seq_oss_readq_t *q, unsigned long curt, int seq_mode) 202snd_seq_oss_readq_put_timestamp(struct seq_oss_readq *q, unsigned long curt, int seq_mode)
203{ 203{
204 if (curt != q->input_time) { 204 if (curt != q->input_time) {
205 evrec_t rec; 205 union evrec rec;
206 memset(&rec, 0, sizeof(rec)); 206 memset(&rec, 0, sizeof(rec));
207 switch (seq_mode) { 207 switch (seq_mode) {
208 case SNDRV_SEQ_OSS_MODE_SYNTH: 208 case SNDRV_SEQ_OSS_MODE_SYNTH:
@@ -226,7 +226,7 @@ snd_seq_oss_readq_put_timestamp(seq_oss_readq_t *q, unsigned long curt, int seq_
226 * proc interface 226 * proc interface
227 */ 227 */
228void 228void
229snd_seq_oss_readq_info_read(seq_oss_readq_t *q, snd_info_buffer_t *buf) 229snd_seq_oss_readq_info_read(struct seq_oss_readq *q, struct snd_info_buffer *buf)
230{ 230{
231 snd_iprintf(buf, " read queue [%s] length = %d : tick = %ld\n", 231 snd_iprintf(buf, " read queue [%s] length = %d : tick = %ld\n",
232 (waitqueue_active(&q->midi_sleep) ? "sleeping":"running"), 232 (waitqueue_active(&q->midi_sleep) ? "sleeping":"running"),
diff --git a/sound/core/seq/oss/seq_oss_readq.h b/sound/core/seq/oss/seq_oss_readq.h
index 303b9298f206..f1463f1f449e 100644
--- a/sound/core/seq/oss/seq_oss_readq.h
+++ b/sound/core/seq/oss/seq_oss_readq.h
@@ -28,8 +28,8 @@
28/* 28/*
29 * definition of read queue 29 * definition of read queue
30 */ 30 */
31struct seq_oss_readq_t { 31struct seq_oss_readq {
32 evrec_t *q; 32 union evrec *q;
33 int qlen; 33 int qlen;
34 int maxlen; 34 int maxlen;
35 int head, tail; 35 int head, tail;
@@ -39,16 +39,16 @@ struct seq_oss_readq_t {
39 spinlock_t lock; 39 spinlock_t lock;
40}; 40};
41 41
42seq_oss_readq_t *snd_seq_oss_readq_new(seq_oss_devinfo_t *dp, int maxlen); 42struct seq_oss_readq *snd_seq_oss_readq_new(struct seq_oss_devinfo *dp, int maxlen);
43void snd_seq_oss_readq_delete(seq_oss_readq_t *q); 43void snd_seq_oss_readq_delete(struct seq_oss_readq *q);
44void snd_seq_oss_readq_clear(seq_oss_readq_t *readq); 44void snd_seq_oss_readq_clear(struct seq_oss_readq *readq);
45unsigned int snd_seq_oss_readq_poll(seq_oss_readq_t *readq, struct file *file, poll_table *wait); 45unsigned int snd_seq_oss_readq_poll(struct seq_oss_readq *readq, struct file *file, poll_table *wait);
46int snd_seq_oss_readq_puts(seq_oss_readq_t *readq, int dev, unsigned char *data, int len); 46int snd_seq_oss_readq_puts(struct seq_oss_readq *readq, int dev, unsigned char *data, int len);
47int snd_seq_oss_readq_put_event(seq_oss_readq_t *readq, evrec_t *ev); 47int snd_seq_oss_readq_put_event(struct seq_oss_readq *readq, union evrec *ev);
48int snd_seq_oss_readq_put_timestamp(seq_oss_readq_t *readq, unsigned long curt, int seq_mode); 48int snd_seq_oss_readq_put_timestamp(struct seq_oss_readq *readq, unsigned long curt, int seq_mode);
49int snd_seq_oss_readq_pick(seq_oss_readq_t *q, evrec_t *rec); 49int snd_seq_oss_readq_pick(struct seq_oss_readq *q, union evrec *rec);
50void snd_seq_oss_readq_wait(seq_oss_readq_t *q); 50void snd_seq_oss_readq_wait(struct seq_oss_readq *q);
51void snd_seq_oss_readq_free(seq_oss_readq_t *q); 51void snd_seq_oss_readq_free(struct seq_oss_readq *q);
52 52
53#define snd_seq_oss_readq_lock(q, flags) spin_lock_irqsave(&(q)->lock, flags) 53#define snd_seq_oss_readq_lock(q, flags) spin_lock_irqsave(&(q)->lock, flags)
54#define snd_seq_oss_readq_unlock(q, flags) spin_unlock_irqrestore(&(q)->lock, flags) 54#define snd_seq_oss_readq_unlock(q, flags) spin_unlock_irqrestore(&(q)->lock, flags)
diff --git a/sound/core/seq/oss/seq_oss_rw.c b/sound/core/seq/oss/seq_oss_rw.c
index 1d8fbd22e3e3..6a7b6aceeca9 100644
--- a/sound/core/seq/oss/seq_oss_rw.c
+++ b/sound/core/seq/oss/seq_oss_rw.c
@@ -33,7 +33,7 @@
33/* 33/*
34 * protoypes 34 * protoypes
35 */ 35 */
36static int insert_queue(seq_oss_devinfo_t *dp, evrec_t *rec, struct file *opt); 36static int insert_queue(struct seq_oss_devinfo *dp, union evrec *rec, struct file *opt);
37 37
38 38
39/* 39/*
@@ -41,12 +41,12 @@ static int insert_queue(seq_oss_devinfo_t *dp, evrec_t *rec, struct file *opt);
41 */ 41 */
42 42
43int 43int
44snd_seq_oss_read(seq_oss_devinfo_t *dp, char __user *buf, int count) 44snd_seq_oss_read(struct seq_oss_devinfo *dp, char __user *buf, int count)
45{ 45{
46 seq_oss_readq_t *readq = dp->readq; 46 struct seq_oss_readq *readq = dp->readq;
47 int result = 0, err = 0; 47 int result = 0, err = 0;
48 int ev_len; 48 int ev_len;
49 evrec_t rec; 49 union evrec rec;
50 unsigned long flags; 50 unsigned long flags;
51 51
52 if (readq == NULL || ! is_read_mode(dp->file_mode)) 52 if (readq == NULL || ! is_read_mode(dp->file_mode))
@@ -93,11 +93,11 @@ snd_seq_oss_read(seq_oss_devinfo_t *dp, char __user *buf, int count)
93 */ 93 */
94 94
95int 95int
96snd_seq_oss_write(seq_oss_devinfo_t *dp, const char __user *buf, int count, struct file *opt) 96snd_seq_oss_write(struct seq_oss_devinfo *dp, const char __user *buf, int count, struct file *opt)
97{ 97{
98 int result = 0, err = 0; 98 int result = 0, err = 0;
99 int ev_size, fmt; 99 int ev_size, fmt;
100 evrec_t rec; 100 union evrec rec;
101 101
102 if (! is_write_mode(dp->file_mode) || dp->writeq == NULL) 102 if (! is_write_mode(dp->file_mode) || dp->writeq == NULL)
103 return -ENXIO; 103 return -ENXIO;
@@ -161,10 +161,10 @@ snd_seq_oss_write(seq_oss_devinfo_t *dp, const char __user *buf, int count, stru
161 * return: 0 = OK, non-zero = NG 161 * return: 0 = OK, non-zero = NG
162 */ 162 */
163static int 163static int
164insert_queue(seq_oss_devinfo_t *dp, evrec_t *rec, struct file *opt) 164insert_queue(struct seq_oss_devinfo *dp, union evrec *rec, struct file *opt)
165{ 165{
166 int rc = 0; 166 int rc = 0;
167 snd_seq_event_t event; 167 struct snd_seq_event event;
168 168
169 /* if this is a timing event, process the current time */ 169 /* if this is a timing event, process the current time */
170 if (snd_seq_oss_process_timer_event(dp->timer, rec)) 170 if (snd_seq_oss_process_timer_event(dp->timer, rec))
@@ -197,7 +197,7 @@ insert_queue(seq_oss_devinfo_t *dp, evrec_t *rec, struct file *opt)
197 */ 197 */
198 198
199unsigned int 199unsigned int
200snd_seq_oss_poll(seq_oss_devinfo_t *dp, struct file *file, poll_table * wait) 200snd_seq_oss_poll(struct seq_oss_devinfo *dp, struct file *file, poll_table * wait)
201{ 201{
202 unsigned int mask = 0; 202 unsigned int mask = 0;
203 203
diff --git a/sound/core/seq/oss/seq_oss_synth.c b/sound/core/seq/oss/seq_oss_synth.c
index 8257fce2ca1b..0b6025c92b9e 100644
--- a/sound/core/seq/oss/seq_oss_synth.c
+++ b/sound/core/seq/oss/seq_oss_synth.c
@@ -37,14 +37,14 @@
37 */ 37 */
38 38
39/* sysex buffer */ 39/* sysex buffer */
40struct seq_oss_synth_sysex_t { 40struct seq_oss_synth_sysex {
41 int len; 41 int len;
42 int skip; 42 int skip;
43 unsigned char buf[MAX_SYSEX_BUFLEN]; 43 unsigned char buf[MAX_SYSEX_BUFLEN];
44}; 44};
45 45
46/* synth info */ 46/* synth info */
47struct seq_oss_synth_t { 47struct seq_oss_synth {
48 int seq_device; 48 int seq_device;
49 49
50 /* for synth_info */ 50 /* for synth_info */
@@ -53,7 +53,7 @@ struct seq_oss_synth_t {
53 int nr_voices; 53 int nr_voices;
54 54
55 char name[SNDRV_SEQ_OSS_MAX_SYNTH_NAME]; 55 char name[SNDRV_SEQ_OSS_MAX_SYNTH_NAME];
56 snd_seq_oss_callback_t oper; 56 struct snd_seq_oss_callback oper;
57 57
58 int opened; 58 int opened;
59 59
@@ -66,8 +66,8 @@ struct seq_oss_synth_t {
66 * device table 66 * device table
67 */ 67 */
68static int max_synth_devs; 68static int max_synth_devs;
69static seq_oss_synth_t *synth_devs[SNDRV_SEQ_OSS_MAX_SYNTH_DEVS]; 69static struct seq_oss_synth *synth_devs[SNDRV_SEQ_OSS_MAX_SYNTH_DEVS];
70static seq_oss_synth_t midi_synth_dev = { 70static struct seq_oss_synth midi_synth_dev = {
71 -1, /* seq_device */ 71 -1, /* seq_device */
72 SYNTH_TYPE_MIDI, /* synth_type */ 72 SYNTH_TYPE_MIDI, /* synth_type */
73 0, /* synth_subtype */ 73 0, /* synth_subtype */
@@ -80,8 +80,8 @@ static DEFINE_SPINLOCK(register_lock);
80/* 80/*
81 * prototypes 81 * prototypes
82 */ 82 */
83static seq_oss_synth_t *get_synthdev(seq_oss_devinfo_t *dp, int dev); 83static struct seq_oss_synth *get_synthdev(struct seq_oss_devinfo *dp, int dev);
84static void reset_channels(seq_oss_synthinfo_t *info); 84static void reset_channels(struct seq_oss_synthinfo *info);
85 85
86/* 86/*
87 * global initialization 87 * global initialization
@@ -96,11 +96,11 @@ snd_seq_oss_synth_init(void)
96 * registration of the synth device 96 * registration of the synth device
97 */ 97 */
98int 98int
99snd_seq_oss_synth_register(snd_seq_device_t *dev) 99snd_seq_oss_synth_register(struct snd_seq_device *dev)
100{ 100{
101 int i; 101 int i;
102 seq_oss_synth_t *rec; 102 struct seq_oss_synth *rec;
103 snd_seq_oss_reg_t *reg = SNDRV_SEQ_DEVICE_ARGPTR(dev); 103 struct snd_seq_oss_reg *reg = SNDRV_SEQ_DEVICE_ARGPTR(dev);
104 unsigned long flags; 104 unsigned long flags;
105 105
106 if ((rec = kzalloc(sizeof(*rec), GFP_KERNEL)) == NULL) { 106 if ((rec = kzalloc(sizeof(*rec), GFP_KERNEL)) == NULL) {
@@ -148,10 +148,10 @@ snd_seq_oss_synth_register(snd_seq_device_t *dev)
148 148
149 149
150int 150int
151snd_seq_oss_synth_unregister(snd_seq_device_t *dev) 151snd_seq_oss_synth_unregister(struct snd_seq_device *dev)
152{ 152{
153 int index; 153 int index;
154 seq_oss_synth_t *rec = dev->driver_data; 154 struct seq_oss_synth *rec = dev->driver_data;
155 unsigned long flags; 155 unsigned long flags;
156 156
157 spin_lock_irqsave(&register_lock, flags); 157 spin_lock_irqsave(&register_lock, flags);
@@ -187,10 +187,10 @@ snd_seq_oss_synth_unregister(snd_seq_device_t *dev)
187 187
188/* 188/*
189 */ 189 */
190static seq_oss_synth_t * 190static struct seq_oss_synth *
191get_sdev(int dev) 191get_sdev(int dev)
192{ 192{
193 seq_oss_synth_t *rec; 193 struct seq_oss_synth *rec;
194 unsigned long flags; 194 unsigned long flags;
195 195
196 spin_lock_irqsave(&register_lock, flags); 196 spin_lock_irqsave(&register_lock, flags);
@@ -207,11 +207,11 @@ get_sdev(int dev)
207 */ 207 */
208 208
209void 209void
210snd_seq_oss_synth_setup(seq_oss_devinfo_t *dp) 210snd_seq_oss_synth_setup(struct seq_oss_devinfo *dp)
211{ 211{
212 int i; 212 int i;
213 seq_oss_synth_t *rec; 213 struct seq_oss_synth *rec;
214 seq_oss_synthinfo_t *info; 214 struct seq_oss_synthinfo *info;
215 215
216 dp->max_synthdev = max_synth_devs; 216 dp->max_synthdev = max_synth_devs;
217 dp->synth_opened = 0; 217 dp->synth_opened = 0;
@@ -244,7 +244,7 @@ snd_seq_oss_synth_setup(seq_oss_devinfo_t *dp)
244 } 244 }
245 info->nr_voices = rec->nr_voices; 245 info->nr_voices = rec->nr_voices;
246 if (info->nr_voices > 0) { 246 if (info->nr_voices > 0) {
247 info->ch = kcalloc(info->nr_voices, sizeof(seq_oss_chinfo_t), GFP_KERNEL); 247 info->ch = kcalloc(info->nr_voices, sizeof(struct seq_oss_chinfo), GFP_KERNEL);
248 if (!info->ch) 248 if (!info->ch)
249 BUG(); 249 BUG();
250 reset_channels(info); 250 reset_channels(info);
@@ -263,7 +263,7 @@ snd_seq_oss_synth_setup(seq_oss_devinfo_t *dp)
263 */ 263 */
264 264
265void 265void
266snd_seq_oss_synth_setup_midi(seq_oss_devinfo_t *dp) 266snd_seq_oss_synth_setup_midi(struct seq_oss_devinfo *dp)
267{ 267{
268 int i; 268 int i;
269 269
@@ -271,7 +271,7 @@ snd_seq_oss_synth_setup_midi(seq_oss_devinfo_t *dp)
271 return; 271 return;
272 272
273 for (i = 0; i < dp->max_mididev; i++) { 273 for (i = 0; i < dp->max_mididev; i++) {
274 seq_oss_synthinfo_t *info; 274 struct seq_oss_synthinfo *info;
275 info = &dp->synths[dp->max_synthdev]; 275 info = &dp->synths[dp->max_synthdev];
276 if (snd_seq_oss_midi_open(dp, i, dp->file_mode) < 0) 276 if (snd_seq_oss_midi_open(dp, i, dp->file_mode) < 0)
277 continue; 277 continue;
@@ -297,11 +297,11 @@ snd_seq_oss_synth_setup_midi(seq_oss_devinfo_t *dp)
297 */ 297 */
298 298
299void 299void
300snd_seq_oss_synth_cleanup(seq_oss_devinfo_t *dp) 300snd_seq_oss_synth_cleanup(struct seq_oss_devinfo *dp)
301{ 301{
302 int i; 302 int i;
303 seq_oss_synth_t *rec; 303 struct seq_oss_synth *rec;
304 seq_oss_synthinfo_t *info; 304 struct seq_oss_synthinfo *info;
305 305
306 snd_assert(dp->max_synthdev <= SNDRV_SEQ_OSS_MAX_SYNTH_DEVS, return); 306 snd_assert(dp->max_synthdev <= SNDRV_SEQ_OSS_MAX_SYNTH_DEVS, return);
307 for (i = 0; i < dp->max_synthdev; i++) { 307 for (i = 0; i < dp->max_synthdev; i++) {
@@ -338,7 +338,7 @@ snd_seq_oss_synth_cleanup(seq_oss_devinfo_t *dp)
338 * check if the specified device is MIDI mapped device 338 * check if the specified device is MIDI mapped device
339 */ 339 */
340static int 340static int
341is_midi_dev(seq_oss_devinfo_t *dp, int dev) 341is_midi_dev(struct seq_oss_devinfo *dp, int dev)
342{ 342{
343 if (dev < 0 || dev >= dp->max_synthdev) 343 if (dev < 0 || dev >= dp->max_synthdev)
344 return 0; 344 return 0;
@@ -350,10 +350,10 @@ is_midi_dev(seq_oss_devinfo_t *dp, int dev)
350/* 350/*
351 * return synth device information pointer 351 * return synth device information pointer
352 */ 352 */
353static seq_oss_synth_t * 353static struct seq_oss_synth *
354get_synthdev(seq_oss_devinfo_t *dp, int dev) 354get_synthdev(struct seq_oss_devinfo *dp, int dev)
355{ 355{
356 seq_oss_synth_t *rec; 356 struct seq_oss_synth *rec;
357 if (dev < 0 || dev >= dp->max_synthdev) 357 if (dev < 0 || dev >= dp->max_synthdev)
358 return NULL; 358 return NULL;
359 if (! dp->synths[dev].opened) 359 if (! dp->synths[dev].opened)
@@ -374,7 +374,7 @@ get_synthdev(seq_oss_devinfo_t *dp, int dev)
374 * reset note and velocity on each channel. 374 * reset note and velocity on each channel.
375 */ 375 */
376static void 376static void
377reset_channels(seq_oss_synthinfo_t *info) 377reset_channels(struct seq_oss_synthinfo *info)
378{ 378{
379 int i; 379 int i;
380 if (info->ch == NULL || ! info->nr_voices) 380 if (info->ch == NULL || ! info->nr_voices)
@@ -392,10 +392,10 @@ reset_channels(seq_oss_synthinfo_t *info)
392 * event to the corresponding port. 392 * event to the corresponding port.
393 */ 393 */
394void 394void
395snd_seq_oss_synth_reset(seq_oss_devinfo_t *dp, int dev) 395snd_seq_oss_synth_reset(struct seq_oss_devinfo *dp, int dev)
396{ 396{
397 seq_oss_synth_t *rec; 397 struct seq_oss_synth *rec;
398 seq_oss_synthinfo_t *info; 398 struct seq_oss_synthinfo *info;
399 399
400 snd_assert(dev >= 0 && dev < dp->max_synthdev, return); 400 snd_assert(dev >= 0 && dev < dp->max_synthdev, return);
401 info = &dp->synths[dev]; 401 info = &dp->synths[dev];
@@ -428,7 +428,7 @@ snd_seq_oss_synth_reset(seq_oss_devinfo_t *dp, int dev)
428 if (rec->oper.reset) { 428 if (rec->oper.reset) {
429 rec->oper.reset(&info->arg); 429 rec->oper.reset(&info->arg);
430 } else { 430 } else {
431 snd_seq_event_t ev; 431 struct snd_seq_event ev;
432 memset(&ev, 0, sizeof(ev)); 432 memset(&ev, 0, sizeof(ev));
433 snd_seq_oss_fill_addr(dp, &ev, info->arg.addr.client, 433 snd_seq_oss_fill_addr(dp, &ev, info->arg.addr.client,
434 info->arg.addr.port); 434 info->arg.addr.port);
@@ -444,10 +444,10 @@ snd_seq_oss_synth_reset(seq_oss_devinfo_t *dp, int dev)
444 * call load_patch callback function 444 * call load_patch callback function
445 */ 445 */
446int 446int
447snd_seq_oss_synth_load_patch(seq_oss_devinfo_t *dp, int dev, int fmt, 447snd_seq_oss_synth_load_patch(struct seq_oss_devinfo *dp, int dev, int fmt,
448 const char __user *buf, int p, int c) 448 const char __user *buf, int p, int c)
449{ 449{
450 seq_oss_synth_t *rec; 450 struct seq_oss_synth *rec;
451 int rc; 451 int rc;
452 452
453 if (dev < 0 || dev >= dp->max_synthdev) 453 if (dev < 0 || dev >= dp->max_synthdev)
@@ -470,9 +470,9 @@ snd_seq_oss_synth_load_patch(seq_oss_devinfo_t *dp, int dev, int fmt,
470 * check if the device is valid synth device 470 * check if the device is valid synth device
471 */ 471 */
472int 472int
473snd_seq_oss_synth_is_valid(seq_oss_devinfo_t *dp, int dev) 473snd_seq_oss_synth_is_valid(struct seq_oss_devinfo *dp, int dev)
474{ 474{
475 seq_oss_synth_t *rec; 475 struct seq_oss_synth *rec;
476 rec = get_synthdev(dp, dev); 476 rec = get_synthdev(dp, dev);
477 if (rec) { 477 if (rec) {
478 snd_use_lock_free(&rec->use_lock); 478 snd_use_lock_free(&rec->use_lock);
@@ -488,11 +488,11 @@ snd_seq_oss_synth_is_valid(seq_oss_devinfo_t *dp, int dev)
488 * (0xff). 488 * (0xff).
489 */ 489 */
490int 490int
491snd_seq_oss_synth_sysex(seq_oss_devinfo_t *dp, int dev, unsigned char *buf, snd_seq_event_t *ev) 491snd_seq_oss_synth_sysex(struct seq_oss_devinfo *dp, int dev, unsigned char *buf, struct snd_seq_event *ev)
492{ 492{
493 int i, send; 493 int i, send;
494 unsigned char *dest; 494 unsigned char *dest;
495 seq_oss_synth_sysex_t *sysex; 495 struct seq_oss_synth_sysex *sysex;
496 496
497 if (! snd_seq_oss_synth_is_valid(dp, dev)) 497 if (! snd_seq_oss_synth_is_valid(dp, dev))
498 return -ENXIO; 498 return -ENXIO;
@@ -545,7 +545,7 @@ snd_seq_oss_synth_sysex(seq_oss_devinfo_t *dp, int dev, unsigned char *buf, snd_
545 * fill the event source/destination addresses 545 * fill the event source/destination addresses
546 */ 546 */
547int 547int
548snd_seq_oss_synth_addr(seq_oss_devinfo_t *dp, int dev, snd_seq_event_t *ev) 548snd_seq_oss_synth_addr(struct seq_oss_devinfo *dp, int dev, struct snd_seq_event *ev)
549{ 549{
550 if (! snd_seq_oss_synth_is_valid(dp, dev)) 550 if (! snd_seq_oss_synth_is_valid(dp, dev))
551 return -EINVAL; 551 return -EINVAL;
@@ -559,9 +559,9 @@ snd_seq_oss_synth_addr(seq_oss_devinfo_t *dp, int dev, snd_seq_event_t *ev)
559 * OSS compatible ioctl 559 * OSS compatible ioctl
560 */ 560 */
561int 561int
562snd_seq_oss_synth_ioctl(seq_oss_devinfo_t *dp, int dev, unsigned int cmd, unsigned long addr) 562snd_seq_oss_synth_ioctl(struct seq_oss_devinfo *dp, int dev, unsigned int cmd, unsigned long addr)
563{ 563{
564 seq_oss_synth_t *rec; 564 struct seq_oss_synth *rec;
565 int rc; 565 int rc;
566 566
567 if (is_midi_dev(dp, dev)) 567 if (is_midi_dev(dp, dev))
@@ -581,7 +581,7 @@ snd_seq_oss_synth_ioctl(seq_oss_devinfo_t *dp, int dev, unsigned int cmd, unsign
581 * send OSS raw events - SEQ_PRIVATE and SEQ_VOLUME 581 * send OSS raw events - SEQ_PRIVATE and SEQ_VOLUME
582 */ 582 */
583int 583int
584snd_seq_oss_synth_raw_event(seq_oss_devinfo_t *dp, int dev, unsigned char *data, snd_seq_event_t *ev) 584snd_seq_oss_synth_raw_event(struct seq_oss_devinfo *dp, int dev, unsigned char *data, struct snd_seq_event *ev)
585{ 585{
586 if (! snd_seq_oss_synth_is_valid(dp, dev) || is_midi_dev(dp, dev)) 586 if (! snd_seq_oss_synth_is_valid(dp, dev) || is_midi_dev(dp, dev))
587 return -ENXIO; 587 return -ENXIO;
@@ -595,9 +595,9 @@ snd_seq_oss_synth_raw_event(seq_oss_devinfo_t *dp, int dev, unsigned char *data,
595 * create OSS compatible synth_info record 595 * create OSS compatible synth_info record
596 */ 596 */
597int 597int
598snd_seq_oss_synth_make_info(seq_oss_devinfo_t *dp, int dev, struct synth_info *inf) 598snd_seq_oss_synth_make_info(struct seq_oss_devinfo *dp, int dev, struct synth_info *inf)
599{ 599{
600 seq_oss_synth_t *rec; 600 struct seq_oss_synth *rec;
601 601
602 if (dp->synths[dev].is_midi) { 602 if (dp->synths[dev].is_midi) {
603 struct midi_info minf; 603 struct midi_info minf;
@@ -625,10 +625,10 @@ snd_seq_oss_synth_make_info(seq_oss_devinfo_t *dp, int dev, struct synth_info *i
625 * proc interface 625 * proc interface
626 */ 626 */
627void 627void
628snd_seq_oss_synth_info_read(snd_info_buffer_t *buf) 628snd_seq_oss_synth_info_read(struct snd_info_buffer *buf)
629{ 629{
630 int i; 630 int i;
631 seq_oss_synth_t *rec; 631 struct seq_oss_synth *rec;
632 632
633 snd_iprintf(buf, "\nNumber of synth devices: %d\n", max_synth_devs); 633 snd_iprintf(buf, "\nNumber of synth devices: %d\n", max_synth_devs);
634 for (i = 0; i < max_synth_devs; i++) { 634 for (i = 0; i < max_synth_devs; i++) {
diff --git a/sound/core/seq/oss/seq_oss_synth.h b/sound/core/seq/oss/seq_oss_synth.h
index 07bc0e2cfb82..dbdfcbb80eaa 100644
--- a/sound/core/seq/oss/seq_oss_synth.h
+++ b/sound/core/seq/oss/seq_oss_synth.h
@@ -27,23 +27,25 @@
27#include <sound/seq_oss_legacy.h> 27#include <sound/seq_oss_legacy.h>
28#include <sound/seq_device.h> 28#include <sound/seq_device.h>
29 29
30typedef struct seq_oss_synth_t seq_oss_synth_t;
31
32void snd_seq_oss_synth_init(void); 30void snd_seq_oss_synth_init(void);
33int snd_seq_oss_synth_register(snd_seq_device_t *dev); 31int snd_seq_oss_synth_register(struct snd_seq_device *dev);
34int snd_seq_oss_synth_unregister(snd_seq_device_t *dev); 32int snd_seq_oss_synth_unregister(struct snd_seq_device *dev);
35void snd_seq_oss_synth_setup(seq_oss_devinfo_t *dp); 33void snd_seq_oss_synth_setup(struct seq_oss_devinfo *dp);
36void snd_seq_oss_synth_setup_midi(seq_oss_devinfo_t *dp); 34void snd_seq_oss_synth_setup_midi(struct seq_oss_devinfo *dp);
37void snd_seq_oss_synth_cleanup(seq_oss_devinfo_t *dp); 35void snd_seq_oss_synth_cleanup(struct seq_oss_devinfo *dp);
38 36
39void snd_seq_oss_synth_reset(seq_oss_devinfo_t *dp, int dev); 37void snd_seq_oss_synth_reset(struct seq_oss_devinfo *dp, int dev);
40int snd_seq_oss_synth_load_patch(seq_oss_devinfo_t *dp, int dev, int fmt, const char __user *buf, int p, int c); 38int snd_seq_oss_synth_load_patch(struct seq_oss_devinfo *dp, int dev, int fmt,
41int snd_seq_oss_synth_is_valid(seq_oss_devinfo_t *dp, int dev); 39 const char __user *buf, int p, int c);
42int snd_seq_oss_synth_sysex(seq_oss_devinfo_t *dp, int dev, unsigned char *buf, snd_seq_event_t *ev); 40int snd_seq_oss_synth_is_valid(struct seq_oss_devinfo *dp, int dev);
43int snd_seq_oss_synth_addr(seq_oss_devinfo_t *dp, int dev, snd_seq_event_t *ev); 41int snd_seq_oss_synth_sysex(struct seq_oss_devinfo *dp, int dev, unsigned char *buf,
44int snd_seq_oss_synth_ioctl(seq_oss_devinfo_t *dp, int dev, unsigned int cmd, unsigned long addr); 42 struct snd_seq_event *ev);
45int snd_seq_oss_synth_raw_event(seq_oss_devinfo_t *dp, int dev, unsigned char *data, snd_seq_event_t *ev); 43int snd_seq_oss_synth_addr(struct seq_oss_devinfo *dp, int dev, struct snd_seq_event *ev);
44int snd_seq_oss_synth_ioctl(struct seq_oss_devinfo *dp, int dev, unsigned int cmd,
45 unsigned long addr);
46int snd_seq_oss_synth_raw_event(struct seq_oss_devinfo *dp, int dev,
47 unsigned char *data, struct snd_seq_event *ev);
46 48
47int snd_seq_oss_synth_make_info(seq_oss_devinfo_t *dp, int dev, struct synth_info *inf); 49int snd_seq_oss_synth_make_info(struct seq_oss_devinfo *dp, int dev, struct synth_info *inf);
48 50
49#endif 51#endif
diff --git a/sound/core/seq/oss/seq_oss_timer.c b/sound/core/seq/oss/seq_oss_timer.c
index 64d594b3170f..c440fdacec93 100644
--- a/sound/core/seq/oss/seq_oss_timer.c
+++ b/sound/core/seq/oss/seq_oss_timer.c
@@ -33,18 +33,18 @@
33 33
34/* 34/*
35 */ 35 */
36static void calc_alsa_tempo(seq_oss_timer_t *timer); 36static void calc_alsa_tempo(struct seq_oss_timer *timer);
37static int send_timer_event(seq_oss_devinfo_t *dp, int type, int value); 37static int send_timer_event(struct seq_oss_devinfo *dp, int type, int value);
38 38
39 39
40/* 40/*
41 * create and register a new timer. 41 * create and register a new timer.
42 * if queue is not started yet, start it. 42 * if queue is not started yet, start it.
43 */ 43 */
44seq_oss_timer_t * 44struct seq_oss_timer *
45snd_seq_oss_timer_new(seq_oss_devinfo_t *dp) 45snd_seq_oss_timer_new(struct seq_oss_devinfo *dp)
46{ 46{
47 seq_oss_timer_t *rec; 47 struct seq_oss_timer *rec;
48 48
49 rec = kzalloc(sizeof(*rec), GFP_KERNEL); 49 rec = kzalloc(sizeof(*rec), GFP_KERNEL);
50 if (rec == NULL) 50 if (rec == NULL)
@@ -67,7 +67,7 @@ snd_seq_oss_timer_new(seq_oss_devinfo_t *dp)
67 * if no more timer exists, stop the queue. 67 * if no more timer exists, stop the queue.
68 */ 68 */
69void 69void
70snd_seq_oss_timer_delete(seq_oss_timer_t *rec) 70snd_seq_oss_timer_delete(struct seq_oss_timer *rec)
71{ 71{
72 if (rec) { 72 if (rec) {
73 snd_seq_oss_timer_stop(rec); 73 snd_seq_oss_timer_stop(rec);
@@ -82,7 +82,7 @@ snd_seq_oss_timer_delete(seq_oss_timer_t *rec)
82 * 0 : not a timer event -- enqueue this event 82 * 0 : not a timer event -- enqueue this event
83 */ 83 */
84int 84int
85snd_seq_oss_process_timer_event(seq_oss_timer_t *rec, evrec_t *ev) 85snd_seq_oss_process_timer_event(struct seq_oss_timer *rec, union evrec *ev)
86{ 86{
87 abstime_t parm = ev->t.time; 87 abstime_t parm = ev->t.time;
88 88
@@ -125,7 +125,7 @@ snd_seq_oss_process_timer_event(seq_oss_timer_t *rec, evrec_t *ev)
125 * convert tempo units 125 * convert tempo units
126 */ 126 */
127static void 127static void
128calc_alsa_tempo(seq_oss_timer_t *timer) 128calc_alsa_tempo(struct seq_oss_timer *timer)
129{ 129{
130 timer->tempo = (60 * 1000000) / timer->oss_tempo; 130 timer->tempo = (60 * 1000000) / timer->oss_tempo;
131 timer->ppq = timer->oss_timebase; 131 timer->ppq = timer->oss_timebase;
@@ -136,9 +136,9 @@ calc_alsa_tempo(seq_oss_timer_t *timer)
136 * dispatch a timer event 136 * dispatch a timer event
137 */ 137 */
138static int 138static int
139send_timer_event(seq_oss_devinfo_t *dp, int type, int value) 139send_timer_event(struct seq_oss_devinfo *dp, int type, int value)
140{ 140{
141 snd_seq_event_t ev; 141 struct snd_seq_event ev;
142 142
143 memset(&ev, 0, sizeof(ev)); 143 memset(&ev, 0, sizeof(ev));
144 ev.type = type; 144 ev.type = type;
@@ -156,10 +156,10 @@ send_timer_event(seq_oss_devinfo_t *dp, int type, int value)
156 * set queue tempo and start queue 156 * set queue tempo and start queue
157 */ 157 */
158int 158int
159snd_seq_oss_timer_start(seq_oss_timer_t *timer) 159snd_seq_oss_timer_start(struct seq_oss_timer *timer)
160{ 160{
161 seq_oss_devinfo_t *dp = timer->dp; 161 struct seq_oss_devinfo *dp = timer->dp;
162 snd_seq_queue_tempo_t tmprec; 162 struct snd_seq_queue_tempo tmprec;
163 163
164 if (timer->running) 164 if (timer->running)
165 snd_seq_oss_timer_stop(timer); 165 snd_seq_oss_timer_stop(timer);
@@ -181,7 +181,7 @@ snd_seq_oss_timer_start(seq_oss_timer_t *timer)
181 * stop queue 181 * stop queue
182 */ 182 */
183int 183int
184snd_seq_oss_timer_stop(seq_oss_timer_t *timer) 184snd_seq_oss_timer_stop(struct seq_oss_timer *timer)
185{ 185{
186 if (! timer->running) 186 if (! timer->running)
187 return 0; 187 return 0;
@@ -195,7 +195,7 @@ snd_seq_oss_timer_stop(seq_oss_timer_t *timer)
195 * continue queue 195 * continue queue
196 */ 196 */
197int 197int
198snd_seq_oss_timer_continue(seq_oss_timer_t *timer) 198snd_seq_oss_timer_continue(struct seq_oss_timer *timer)
199{ 199{
200 if (timer->running) 200 if (timer->running)
201 return 0; 201 return 0;
@@ -209,7 +209,7 @@ snd_seq_oss_timer_continue(seq_oss_timer_t *timer)
209 * change queue tempo 209 * change queue tempo
210 */ 210 */
211int 211int
212snd_seq_oss_timer_tempo(seq_oss_timer_t *timer, int value) 212snd_seq_oss_timer_tempo(struct seq_oss_timer *timer, int value)
213{ 213{
214 if (value < MIN_OSS_TEMPO) 214 if (value < MIN_OSS_TEMPO)
215 value = MIN_OSS_TEMPO; 215 value = MIN_OSS_TEMPO;
@@ -227,7 +227,7 @@ snd_seq_oss_timer_tempo(seq_oss_timer_t *timer, int value)
227 * ioctls 227 * ioctls
228 */ 228 */
229int 229int
230snd_seq_oss_timer_ioctl(seq_oss_timer_t *timer, unsigned int cmd, int __user *arg) 230snd_seq_oss_timer_ioctl(struct seq_oss_timer *timer, unsigned int cmd, int __user *arg)
231{ 231{
232 int value; 232 int value;
233 233
diff --git a/sound/core/seq/oss/seq_oss_timer.h b/sound/core/seq/oss/seq_oss_timer.h
index 6e4dbd8504c1..b995bd68ad1f 100644
--- a/sound/core/seq/oss/seq_oss_timer.h
+++ b/sound/core/seq/oss/seq_oss_timer.h
@@ -27,8 +27,8 @@
27/* 27/*
28 * timer information definition 28 * timer information definition
29 */ 29 */
30struct seq_oss_timer_t { 30struct seq_oss_timer {
31 seq_oss_devinfo_t *dp; 31 struct seq_oss_devinfo *dp;
32 reltime_t cur_tick; 32 reltime_t cur_tick;
33 int realtime; 33 int realtime;
34 int running; 34 int running;
@@ -37,22 +37,22 @@ struct seq_oss_timer_t {
37}; 37};
38 38
39 39
40seq_oss_timer_t *snd_seq_oss_timer_new(seq_oss_devinfo_t *dp); 40struct seq_oss_timer *snd_seq_oss_timer_new(struct seq_oss_devinfo *dp);
41void snd_seq_oss_timer_delete(seq_oss_timer_t *dp); 41void snd_seq_oss_timer_delete(struct seq_oss_timer *dp);
42 42
43int snd_seq_oss_timer_start(seq_oss_timer_t *timer); 43int snd_seq_oss_timer_start(struct seq_oss_timer *timer);
44int snd_seq_oss_timer_stop(seq_oss_timer_t *timer); 44int snd_seq_oss_timer_stop(struct seq_oss_timer *timer);
45int snd_seq_oss_timer_continue(seq_oss_timer_t *timer); 45int snd_seq_oss_timer_continue(struct seq_oss_timer *timer);
46int snd_seq_oss_timer_tempo(seq_oss_timer_t *timer, int value); 46int snd_seq_oss_timer_tempo(struct seq_oss_timer *timer, int value);
47#define snd_seq_oss_timer_reset snd_seq_oss_timer_start 47#define snd_seq_oss_timer_reset snd_seq_oss_timer_start
48 48
49int snd_seq_oss_timer_ioctl(seq_oss_timer_t *timer, unsigned int cmd, int __user *arg); 49int snd_seq_oss_timer_ioctl(struct seq_oss_timer *timer, unsigned int cmd, int __user *arg);
50 50
51/* 51/*
52 * get current processed time 52 * get current processed time
53 */ 53 */
54static inline abstime_t 54static inline abstime_t
55snd_seq_oss_timer_cur_tick(seq_oss_timer_t *timer) 55snd_seq_oss_timer_cur_tick(struct seq_oss_timer *timer)
56{ 56{
57 return timer->cur_tick; 57 return timer->cur_tick;
58} 58}
@@ -62,7 +62,7 @@ snd_seq_oss_timer_cur_tick(seq_oss_timer_t *timer)
62 * is realtime event? 62 * is realtime event?
63 */ 63 */
64static inline int 64static inline int
65snd_seq_oss_timer_is_realtime(seq_oss_timer_t *timer) 65snd_seq_oss_timer_is_realtime(struct seq_oss_timer *timer)
66{ 66{
67 return timer->realtime; 67 return timer->realtime;
68} 68}
diff --git a/sound/core/seq/oss/seq_oss_writeq.c b/sound/core/seq/oss/seq_oss_writeq.c
index b20378024547..5c8495601a38 100644
--- a/sound/core/seq/oss/seq_oss_writeq.c
+++ b/sound/core/seq/oss/seq_oss_writeq.c
@@ -32,11 +32,11 @@
32/* 32/*
33 * create a write queue record 33 * create a write queue record
34 */ 34 */
35seq_oss_writeq_t * 35struct seq_oss_writeq *
36snd_seq_oss_writeq_new(seq_oss_devinfo_t *dp, int maxlen) 36snd_seq_oss_writeq_new(struct seq_oss_devinfo *dp, int maxlen)
37{ 37{
38 seq_oss_writeq_t *q; 38 struct seq_oss_writeq *q;
39 snd_seq_client_pool_t pool; 39 struct snd_seq_client_pool pool;
40 40
41 if ((q = kzalloc(sizeof(*q), GFP_KERNEL)) == NULL) 41 if ((q = kzalloc(sizeof(*q), GFP_KERNEL)) == NULL)
42 return NULL; 42 return NULL;
@@ -61,7 +61,7 @@ snd_seq_oss_writeq_new(seq_oss_devinfo_t *dp, int maxlen)
61 * delete the write queue 61 * delete the write queue
62 */ 62 */
63void 63void
64snd_seq_oss_writeq_delete(seq_oss_writeq_t *q) 64snd_seq_oss_writeq_delete(struct seq_oss_writeq *q)
65{ 65{
66 snd_seq_oss_writeq_clear(q); /* to be sure */ 66 snd_seq_oss_writeq_clear(q); /* to be sure */
67 kfree(q); 67 kfree(q);
@@ -72,9 +72,9 @@ snd_seq_oss_writeq_delete(seq_oss_writeq_t *q)
72 * reset the write queue 72 * reset the write queue
73 */ 73 */
74void 74void
75snd_seq_oss_writeq_clear(seq_oss_writeq_t *q) 75snd_seq_oss_writeq_clear(struct seq_oss_writeq *q)
76{ 76{
77 snd_seq_remove_events_t reset; 77 struct snd_seq_remove_events reset;
78 78
79 memset(&reset, 0, sizeof(reset)); 79 memset(&reset, 0, sizeof(reset));
80 reset.remove_mode = SNDRV_SEQ_REMOVE_OUTPUT; /* remove all */ 80 reset.remove_mode = SNDRV_SEQ_REMOVE_OUTPUT; /* remove all */
@@ -88,9 +88,9 @@ snd_seq_oss_writeq_clear(seq_oss_writeq_t *q)
88 * wait until the write buffer has enough room 88 * wait until the write buffer has enough room
89 */ 89 */
90int 90int
91snd_seq_oss_writeq_sync(seq_oss_writeq_t *q) 91snd_seq_oss_writeq_sync(struct seq_oss_writeq *q)
92{ 92{
93 seq_oss_devinfo_t *dp = q->dp; 93 struct seq_oss_devinfo *dp = q->dp;
94 abstime_t time; 94 abstime_t time;
95 95
96 time = snd_seq_oss_timer_cur_tick(dp->timer); 96 time = snd_seq_oss_timer_cur_tick(dp->timer);
@@ -98,8 +98,8 @@ snd_seq_oss_writeq_sync(seq_oss_writeq_t *q)
98 return 0; /* already finished */ 98 return 0; /* already finished */
99 99
100 if (! q->sync_event_put) { 100 if (! q->sync_event_put) {
101 snd_seq_event_t ev; 101 struct snd_seq_event ev;
102 evrec_t *rec; 102 union evrec *rec;
103 103
104 /* put echoback event */ 104 /* put echoback event */
105 memset(&ev, 0, sizeof(ev)); 105 memset(&ev, 0, sizeof(ev));
@@ -108,7 +108,7 @@ snd_seq_oss_writeq_sync(seq_oss_writeq_t *q)
108 ev.time.tick = time; 108 ev.time.tick = time;
109 /* echo back to itself */ 109 /* echo back to itself */
110 snd_seq_oss_fill_addr(dp, &ev, dp->addr.client, dp->addr.port); 110 snd_seq_oss_fill_addr(dp, &ev, dp->addr.client, dp->addr.port);
111 rec = (evrec_t*)&ev.data; 111 rec = (union evrec *)&ev.data;
112 rec->t.code = SEQ_SYNCTIMER; 112 rec->t.code = SEQ_SYNCTIMER;
113 rec->t.time = time; 113 rec->t.time = time;
114 q->sync_event_put = 1; 114 q->sync_event_put = 1;
@@ -128,7 +128,7 @@ snd_seq_oss_writeq_sync(seq_oss_writeq_t *q)
128 * wake up sync - echo event was catched 128 * wake up sync - echo event was catched
129 */ 129 */
130void 130void
131snd_seq_oss_writeq_wakeup(seq_oss_writeq_t *q, abstime_t time) 131snd_seq_oss_writeq_wakeup(struct seq_oss_writeq *q, abstime_t time)
132{ 132{
133 unsigned long flags; 133 unsigned long flags;
134 134
@@ -146,9 +146,9 @@ snd_seq_oss_writeq_wakeup(seq_oss_writeq_t *q, abstime_t time)
146 * return the unused pool size 146 * return the unused pool size
147 */ 147 */
148int 148int
149snd_seq_oss_writeq_get_free_size(seq_oss_writeq_t *q) 149snd_seq_oss_writeq_get_free_size(struct seq_oss_writeq *q)
150{ 150{
151 snd_seq_client_pool_t pool; 151 struct snd_seq_client_pool pool;
152 pool.client = q->dp->cseq; 152 pool.client = q->dp->cseq;
153 snd_seq_oss_control(q->dp, SNDRV_SEQ_IOCTL_GET_CLIENT_POOL, &pool); 153 snd_seq_oss_control(q->dp, SNDRV_SEQ_IOCTL_GET_CLIENT_POOL, &pool);
154 return pool.output_free; 154 return pool.output_free;
@@ -159,9 +159,9 @@ snd_seq_oss_writeq_get_free_size(seq_oss_writeq_t *q)
159 * set output threshold size from ioctl 159 * set output threshold size from ioctl
160 */ 160 */
161void 161void
162snd_seq_oss_writeq_set_output(seq_oss_writeq_t *q, int val) 162snd_seq_oss_writeq_set_output(struct seq_oss_writeq *q, int val)
163{ 163{
164 snd_seq_client_pool_t pool; 164 struct snd_seq_client_pool pool;
165 pool.client = q->dp->cseq; 165 pool.client = q->dp->cseq;
166 snd_seq_oss_control(q->dp, SNDRV_SEQ_IOCTL_GET_CLIENT_POOL, &pool); 166 snd_seq_oss_control(q->dp, SNDRV_SEQ_IOCTL_GET_CLIENT_POOL, &pool);
167 pool.output_room = val; 167 pool.output_room = val;
diff --git a/sound/core/seq/oss/seq_oss_writeq.h b/sound/core/seq/oss/seq_oss_writeq.h
index 6a13c85e2399..c469d2967566 100644
--- a/sound/core/seq/oss/seq_oss_writeq.h
+++ b/sound/core/seq/oss/seq_oss_writeq.h
@@ -25,8 +25,8 @@
25#include "seq_oss_device.h" 25#include "seq_oss_device.h"
26 26
27 27
28struct seq_oss_writeq_t { 28struct seq_oss_writeq {
29 seq_oss_devinfo_t *dp; 29 struct seq_oss_devinfo *dp;
30 int maxlen; 30 int maxlen;
31 abstime_t sync_time; 31 abstime_t sync_time;
32 int sync_event_put; 32 int sync_event_put;
@@ -38,13 +38,13 @@ struct seq_oss_writeq_t {
38/* 38/*
39 * seq_oss_writeq.c 39 * seq_oss_writeq.c
40 */ 40 */
41seq_oss_writeq_t *snd_seq_oss_writeq_new(seq_oss_devinfo_t *dp, int maxlen); 41struct seq_oss_writeq *snd_seq_oss_writeq_new(struct seq_oss_devinfo *dp, int maxlen);
42void snd_seq_oss_writeq_delete(seq_oss_writeq_t *q); 42void snd_seq_oss_writeq_delete(struct seq_oss_writeq *q);
43void snd_seq_oss_writeq_clear(seq_oss_writeq_t *q); 43void snd_seq_oss_writeq_clear(struct seq_oss_writeq *q);
44int snd_seq_oss_writeq_sync(seq_oss_writeq_t *q); 44int snd_seq_oss_writeq_sync(struct seq_oss_writeq *q);
45void snd_seq_oss_writeq_wakeup(seq_oss_writeq_t *q, abstime_t time); 45void snd_seq_oss_writeq_wakeup(struct seq_oss_writeq *q, abstime_t time);
46int snd_seq_oss_writeq_get_free_size(seq_oss_writeq_t *q); 46int snd_seq_oss_writeq_get_free_size(struct seq_oss_writeq *q);
47void snd_seq_oss_writeq_set_output(seq_oss_writeq_t *q, int size); 47void snd_seq_oss_writeq_set_output(struct seq_oss_writeq *q, int size);
48 48
49 49
50#endif 50#endif