aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/ctxfi/ctatc.h
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2009-06-05 10:11:07 -0400
committerTakashi Iwai <tiwai@suse.de>2009-06-05 10:44:13 -0400
commitb7bbf876087e0e2c0ba723a8398083c9a9ac1dfd (patch)
tree69a3e70658fc751ffc99eef5a6f047b19f61a4a2 /sound/pci/ctxfi/ctatc.h
parent6bc5874a1ddf98ac0fe6c4eab7d286c11cb1c748 (diff)
ALSA: ctxfi - Use native timer interrupt on emu20k1
emu20k1 has a native timer interrupt based on the audio clock, which is more accurate than the system timer (from the synchronization POV). This patch adds the code to handle this with multiple streams. The system timer is still used on emu20k2, and can be used also for emu20k1 easily by changing USE_SYSTEM_TIMER to 1 in cttimer.c. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/ctxfi/ctatc.h')
-rw-r--r--sound/pci/ctxfi/ctatc.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/sound/pci/ctxfi/ctatc.h b/sound/pci/ctxfi/ctatc.h
index b86d12cd4a19..a3f9b1bc7dcc 100644
--- a/sound/pci/ctxfi/ctatc.h
+++ b/sound/pci/ctxfi/ctatc.h
@@ -59,16 +59,15 @@ struct ct_atc_chip_details {
59}; 59};
60 60
61struct ct_atc; 61struct ct_atc;
62struct ct_timer;
63struct ct_timer_instance;
62 64
63/* alsa pcm stream descriptor */ 65/* alsa pcm stream descriptor */
64struct ct_atc_pcm { 66struct ct_atc_pcm {
65 struct snd_pcm_substream *substream; 67 struct snd_pcm_substream *substream;
66 void (*interrupt)(struct ct_atc_pcm *apcm); 68 void (*interrupt)(struct ct_atc_pcm *apcm);
69 struct ct_timer_instance *timer;
67 unsigned int started:1; 70 unsigned int started:1;
68 unsigned int stop_timer:1;
69 struct timer_list timer;
70 spinlock_t timer_lock;
71 unsigned int position;
72 71
73 /* Only mono and interleaved modes are supported now. */ 72 /* Only mono and interleaved modes are supported now. */
74 struct ct_vm_block *vm_block; 73 struct ct_vm_block *vm_block;
@@ -144,6 +143,8 @@ struct ct_atc {
144 unsigned char n_src; 143 unsigned char n_src;
145 unsigned char n_srcimp; 144 unsigned char n_srcimp;
146 unsigned char n_pcm; 145 unsigned char n_pcm;
146
147 struct ct_timer *timer;
147}; 148};
148 149
149 150