Lines Matching +full:0 +full:x220
31 static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; /* Index 0-MAX */
34 static long port[SNDRV_CARDS] = SNDRV_DEFAULT_PORT; /* 0x220,0x240,0x260 */
35 static long gf1_port[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS) - 1] = -1}; /* 0x210,0x220,0x230,0x240,0x250,0x260,0x270 */
36 static long mpu_port[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS) - 1] = -1}; /* 0x300,0x310,0x320 */
40 static int dma8[SNDRV_CARDS] = SNDRV_DEFAULT_DMA; /* 0,1,3 */
42 static int joystick_dac[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS - 1)] = 29};
43 /* 0 to 31, (0.59V-4.52V or 0.389V-2.98V) */
44 static int channels[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS - 1)] = 24};
45 static int pcm_channels[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS - 1)] = 2};
85 static const long possible_ports[] = {0x220, 0x240, 0x260};
87 static const int possible_dmas[] = {1, 3, 0, -1};
93 if (irq[n] < 0) {
100 if (dma8[n] < 0) {
110 i = 0;
115 } while (error < 0 && ++i < ARRAY_SIZE(possible_ports));
129 if (gf1_irq[n] < 0) {
136 if (dma1[n] < 0) {
142 0, channels[n], pcm_channels[n], 0, rgus);
153 * ES1688 chip in another place than 0x220.
158 * 0x230 = 0,2,3
159 * 0x240 = 2,0,1
160 * 0x250 = 2,0,3
161 * 0x260 = 2,2,1
165 snd_es1688_mixer_write(es1688, 0x40, 0x0b); /* don't change!!! */
169 outb(gus->gf1.port & 0x040 ? 2 : 0, ES1688P(es1688, INIT1));
170 outb(0, 0x201);
171 outb(gus->gf1.port & 0x020 ? 2 : 0, ES1688P(es1688, INIT1));
172 outb(0, 0x201);
173 outb(gus->gf1.port & 0x010 ? 3 : 1, ES1688P(es1688, INIT1));
178 snd_gf1_i_write8(gus, SNDRV_GF1_GB_RESET, 0); /* reset GF1 */
180 if ((d & 0x07) != 0) {
181 dev_dbg(gus->card->dev, "[0x%lx] check 1 failed - 0x%x\n", gus->gf1.port, d);
188 if ((d & 0x07) != 1) {
189 dev_dbg(gus->card->dev, "[0x%lx] check 2 failed - 0x%x\n", gus->gf1.port, d);
193 return 0;
201 memset(&id1, 0, sizeof(id1));
202 memset(&id2, 0, sizeof(id2));
209 if (error < 0)
216 if (error < 0)
219 return 0;
232 if (error < 0)
238 mpu_port[n] = 0;
244 if (error < 0)
247 if (gf1_port[n] < 0)
248 gf1_port[n] = es1688->port + 0x20;
251 if (error < 0)
255 if (error < 0)
261 if (error < 0)
267 "detected at 0x%lx\n", gus->gf1.port);
272 error = snd_es1688_pcm(card, es1688, 0);
273 if (error < 0)
277 if (error < 0)
282 if (pcm_channels[n] > 0) {
284 if (error < 0)
289 if (error < 0)
293 if (error < 0)
297 OPL3_HW_OPL3, 0, &opl3) < 0)
298 dev_warn(dev, "opl3 not detected at 0x%lx\n", es1688->port);
300 error = snd_opl3_hwdep_new(opl3, 0, 2, NULL);
301 if (error < 0)
305 if (es1688->mpu_port >= 0x300) {
306 error = snd_mpu401_uart_new(card, 0, MPU401_HW_ES1688,
307 es1688->mpu_port, 0, mpu_irq[n], NULL);
308 if (error < 0)
312 sprintf(card->longname, "Gravis UltraSound Extreme at 0x%lx, "
317 if (error < 0)
321 return 0;
327 #if 0 /* FIXME */