• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/sound/isa/gus/

Lines Matching defs:gus

26 #include <sound/gus.h>
37 struct snd_gus_card *gus;
39 gus = snd_timer_chip(timer);
40 spin_lock_irqsave(&gus->reg_lock, flags);
42 tmp = (gus->gf1.timer_enabled |= 4);
43 snd_gf1_write8(gus, SNDRV_GF1_GB_ADLIB_TIMER_1, 256 - ticks); /* timer 1 count */
44 snd_gf1_write8(gus, SNDRV_GF1_GB_SOUND_BLASTER_CONTROL, tmp); /* enable timer 1 IRQ */
45 snd_gf1_adlib_write(gus, 0x04, tmp >> 2); /* timer 2 start */
46 spin_unlock_irqrestore(&gus->reg_lock, flags);
54 struct snd_gus_card *gus;
56 gus = snd_timer_chip(timer);
57 spin_lock_irqsave(&gus->reg_lock, flags);
58 tmp = (gus->gf1.timer_enabled &= ~4);
59 snd_gf1_write8(gus, SNDRV_GF1_GB_SOUND_BLASTER_CONTROL, tmp); /* disable timer #1 */
60 spin_unlock_irqrestore(&gus->reg_lock, flags);
73 struct snd_gus_card *gus;
75 gus = snd_timer_chip(timer);
76 spin_lock_irqsave(&gus->reg_lock, flags);
78 tmp = (gus->gf1.timer_enabled |= 8);
79 snd_gf1_write8(gus, SNDRV_GF1_GB_ADLIB_TIMER_2, 256 - ticks); /* timer 2 count */
80 snd_gf1_write8(gus, SNDRV_GF1_GB_SOUND_BLASTER_CONTROL, tmp); /* enable timer 2 IRQ */
81 snd_gf1_adlib_write(gus, 0x04, tmp >> 2); /* timer 2 start */
82 spin_unlock_irqrestore(&gus->reg_lock, flags);
90 struct snd_gus_card *gus;
92 gus = snd_timer_chip(timer);
93 spin_lock_irqsave(&gus->reg_lock, flags);
94 tmp = (gus->gf1.timer_enabled &= ~8);
95 snd_gf1_write8(gus, SNDRV_GF1_GB_SOUND_BLASTER_CONTROL, tmp); /* disable timer #1 */
96 spin_unlock_irqrestore(&gus->reg_lock, flags);
104 static void snd_gf1_interrupt_timer1(struct snd_gus_card * gus)
106 struct snd_timer *timer = gus->gf1.timer1;
113 static void snd_gf1_interrupt_timer2(struct snd_gus_card * gus)
115 struct snd_timer *timer = gus->gf1.timer2;
146 struct snd_gus_card *gus = timer->private_data;
147 gus->gf1.timer1 = NULL;
152 struct snd_gus_card *gus = timer->private_data;
153 gus->gf1.timer2 = NULL;
156 void snd_gf1_timers_init(struct snd_gus_card * gus)
161 if (gus->gf1.timer1 != NULL || gus->gf1.timer2 != NULL)
164 gus->gf1.interrupt_handler_timer1 = snd_gf1_interrupt_timer1;
165 gus->gf1.interrupt_handler_timer2 = snd_gf1_interrupt_timer2;
169 tid.card = gus->card->number;
170 tid.device = gus->timer_dev;
173 if (snd_timer_new(gus->card, "GF1 timer", &tid, &timer) >= 0) {
175 timer->private_data = gus;
179 gus->gf1.timer1 = timer;
183 if (snd_timer_new(gus->card, "GF1 timer", &tid, &timer) >= 0) {
185 timer->private_data = gus;
189 gus->gf1.timer2 = timer;
192 void snd_gf1_timers_done(struct snd_gus_card * gus)
194 snd_gf1_set_default_handlers(gus, SNDRV_GF1_HANDLER_TIMER1 | SNDRV_GF1_HANDLER_TIMER2);
195 if (gus->gf1.timer1) {
196 snd_device_free(gus->card, gus->gf1.timer1);
197 gus->gf1.timer1 = NULL;
199 if (gus->gf1.timer2) {
200 snd_device_free(gus->card, gus->gf1.timer2);
201 gus->gf1.timer2 = NULL;