diff options
Diffstat (limited to 'include/sound/emu10k1.h')
-rw-r--r-- | include/sound/emu10k1.h | 231 |
1 files changed, 230 insertions, 1 deletions
diff --git a/include/sound/emu10k1.h b/include/sound/emu10k1.h index 441aa06dcd6f..7b7b9b13b4dd 100644 --- a/include/sound/emu10k1.h +++ b/include/sound/emu10k1.h | |||
@@ -1120,6 +1120,99 @@ | |||
1120 | /************************************************************************************************/ | 1120 | /************************************************************************************************/ |
1121 | /* EMU1010m HANA Destinations */ | 1121 | /* EMU1010m HANA Destinations */ |
1122 | /************************************************************************************************/ | 1122 | /************************************************************************************************/ |
1123 | /* Hana, original 1010,1212,1820 using Alice2 | ||
1124 | * Destiniations for SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1125 | * 0x00, 0x00-0x0f: 16 EMU32 channels to Alice2 | ||
1126 | * 0x01, 0x10-0x1f: 32 Elink channels to Audio Dock | ||
1127 | * 0x01, 0x00: Dock DAC 1 Left | ||
1128 | * 0x01, 0x04: Dock DAC 1 Right | ||
1129 | * 0x01, 0x08: Dock DAC 2 Left | ||
1130 | * 0x01, 0x0c: Dock DAC 2 Right | ||
1131 | * 0x01, 0x10: Dock DAC 3 Left | ||
1132 | * 0x01, 0x12: PHONES Left | ||
1133 | * 0x01, 0x14: Dock DAC 3 Right | ||
1134 | * 0x01, 0x16: PHONES Right | ||
1135 | * 0x01, 0x18: Dock DAC 4 Left | ||
1136 | * 0x01, 0x1a: S/PDIF Left | ||
1137 | * 0x01, 0x1c: Dock DAC 4 Right | ||
1138 | * 0x01, 0x1e: S/PDIF Right | ||
1139 | * 0x02, 0x00: Hana S/PDIF Left | ||
1140 | * 0x02, 0x01: Hana S/PDIF Right | ||
1141 | * 0x03, 0x00: Hanoa DAC Left | ||
1142 | * 0x03, 0x01: Hanoa DAC Right | ||
1143 | * 0x04, 0x00-0x07: Hana ADAT | ||
1144 | * 0x05, 0x00: I2S0 Left to Alice2 | ||
1145 | * 0x05, 0x01: I2S0 Right to Alice2 | ||
1146 | * 0x06, 0x00: I2S0 Left to Alice2 | ||
1147 | * 0x06, 0x01: I2S0 Right to Alice2 | ||
1148 | * 0x07, 0x00: I2S0 Left to Alice2 | ||
1149 | * 0x07, 0x01: I2S0 Right to Alice2 | ||
1150 | * | ||
1151 | * Hana2 never released, but used Tina | ||
1152 | * Not needed. | ||
1153 | * | ||
1154 | * Hana3, rev2 1010,1212,1616 using Tina | ||
1155 | * Destinations for SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1156 | * 0x00, 0x00-0x0f: 16 EMU32A channels to Tina | ||
1157 | * 0x01, 0x10-0x1f: 32 EDI channels to Micro Dock | ||
1158 | * 0x01, 0x00: Dock DAC 1 Left | ||
1159 | * 0x01, 0x04: Dock DAC 1 Right | ||
1160 | * 0x01, 0x08: Dock DAC 2 Left | ||
1161 | * 0x01, 0x0c: Dock DAC 2 Right | ||
1162 | * 0x01, 0x10: Dock DAC 3 Left | ||
1163 | * 0x01, 0x12: Dock S/PDIF Left | ||
1164 | * 0x01, 0x14: Dock DAC 3 Right | ||
1165 | * 0x01, 0x16: Dock S/PDIF Right | ||
1166 | * 0x01, 0x18-0x1f: Dock ADAT 0-7 | ||
1167 | * 0x02, 0x00: Hana3 S/PDIF Left | ||
1168 | * 0x02, 0x01: Hana3 S/PDIF Right | ||
1169 | * 0x03, 0x00: Hanoa DAC Left | ||
1170 | * 0x03, 0x01: Hanoa DAC Right | ||
1171 | * 0x04, 0x00-0x07: Hana3 ADAT 0-7 | ||
1172 | * 0x05, 0x00-0x0f: 16 EMU32B channels to Tina | ||
1173 | * 0x06-0x07: Not used | ||
1174 | * | ||
1175 | * HanaLite, rev1 0404 using Alice2 | ||
1176 | * Destiniations for SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1177 | * 0x00, 0x00-0x0f: 16 EMU32 channels to Alice2 | ||
1178 | * 0x01: Not used | ||
1179 | * 0x02, 0x00: S/PDIF Left | ||
1180 | * 0x02, 0x01: S/PDIF Right | ||
1181 | * 0x03, 0x00: DAC Left | ||
1182 | * 0x03, 0x01: DAC Right | ||
1183 | * 0x04-0x07: Not used | ||
1184 | * | ||
1185 | * HanaLiteLite, rev2 0404 using Alice2 | ||
1186 | * Destiniations for SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1187 | * 0x00, 0x00-0x0f: 16 EMU32 channels to Alice2 | ||
1188 | * 0x01: Not used | ||
1189 | * 0x02, 0x00: S/PDIF Left | ||
1190 | * 0x02, 0x01: S/PDIF Right | ||
1191 | * 0x03, 0x00: DAC Left | ||
1192 | * 0x03, 0x01: DAC Right | ||
1193 | * 0x04-0x07: Not used | ||
1194 | * | ||
1195 | * Mana, Cardbus 1616 using Tina2 | ||
1196 | * Destinations for SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1197 | * 0x00, 0x00-0x0f: 16 EMU32A channels to Tina2 | ||
1198 | * 0x01, 0x10-0x1f: 32 EDI channels to Micro Dock | ||
1199 | * 0x01, 0x00: Dock DAC 1 Left | ||
1200 | * 0x01, 0x04: Dock DAC 1 Right | ||
1201 | * 0x01, 0x08: Dock DAC 2 Left | ||
1202 | * 0x01, 0x0c: Dock DAC 2 Right | ||
1203 | * 0x01, 0x10: Dock DAC 3 Left | ||
1204 | * 0x01, 0x12: Dock S/PDIF Left | ||
1205 | * 0x01, 0x14: Dock DAC 3 Right | ||
1206 | * 0x01, 0x16: Dock S/PDIF Right | ||
1207 | * 0x01, 0x18-0x1f: Dock ADAT 0-7 | ||
1208 | * 0x02: Not used | ||
1209 | * 0x03, 0x00: Mana DAC Left | ||
1210 | * 0x03, 0x01: Mana DAC Right | ||
1211 | * 0x04, 0x00-0x0f: 16 EMU32B channels to Tina2 | ||
1212 | * 0x05-0x07: Not used | ||
1213 | * | ||
1214 | * | ||
1215 | */ | ||
1123 | /* 32-bit destinations of signal in the Hana FPGA. Destinations are either | 1216 | /* 32-bit destinations of signal in the Hana FPGA. Destinations are either |
1124 | * physical outputs of Hana, or outputs going to Alice2 (audigy) for capture | 1217 | * physical outputs of Hana, or outputs going to Alice2 (audigy) for capture |
1125 | * - 16 x EMU_DST_ALICE2_EMU32_X. | 1218 | * - 16 x EMU_DST_ALICE2_EMU32_X. |
@@ -1206,9 +1299,122 @@ | |||
1206 | #define EMU_DST_ALICE_I2S2_LEFT 0x0700 /* Alice2 I2S2 Left */ | 1299 | #define EMU_DST_ALICE_I2S2_LEFT 0x0700 /* Alice2 I2S2 Left */ |
1207 | #define EMU_DST_ALICE_I2S2_RIGHT 0x0701 /* Alice2 I2S2 Right */ | 1300 | #define EMU_DST_ALICE_I2S2_RIGHT 0x0701 /* Alice2 I2S2 Right */ |
1208 | 1301 | ||
1302 | /* Additional destinations for 1616(M)/Microdock */ | ||
1303 | /* Microdock S/PDIF OUT Left, 1st or 48kHz only */ | ||
1304 | #define EMU_DST_MDOCK_SPDIF_LEFT1 0x0112 | ||
1305 | /* Microdock S/PDIF OUT Left, 2nd or 96kHz */ | ||
1306 | #define EMU_DST_MDOCK_SPDIF_LEFT2 0x0113 | ||
1307 | /* Microdock S/PDIF OUT Right, 1st or 48kHz only */ | ||
1308 | #define EMU_DST_MDOCK_SPDIF_RIGHT1 0x0116 | ||
1309 | /* Microdock S/PDIF OUT Right, 2nd or 96kHz */ | ||
1310 | #define EMU_DST_MDOCK_SPDIF_RIGHT2 0x0117 | ||
1311 | /* Microdock S/PDIF ADAT 8 channel out +8 to +f */ | ||
1312 | #define EMU_DST_MDOCK_ADAT 0x0118 | ||
1313 | |||
1314 | /* Headphone jack on 1010 cardbus? 44.1/48kHz only? */ | ||
1315 | #define EMU_DST_MANA_DAC_LEFT 0x0300 | ||
1316 | /* Headphone jack on 1010 cardbus? 44.1/48kHz only? */ | ||
1317 | #define EMU_DST_MANA_DAC_RIGHT 0x0301 | ||
1318 | |||
1209 | /************************************************************************************************/ | 1319 | /************************************************************************************************/ |
1210 | /* EMU1010m HANA Sources */ | 1320 | /* EMU1010m HANA Sources */ |
1211 | /************************************************************************************************/ | 1321 | /************************************************************************************************/ |
1322 | /* Hana, original 1010,1212,1820 using Alice2 | ||
1323 | * Sources SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1324 | * 0x00,0x00-0x1f: Silence | ||
1325 | * 0x01, 0x10-0x1f: 32 Elink channels from Audio Dock | ||
1326 | * 0x01, 0x00: Dock Mic A | ||
1327 | * 0x01, 0x04: Dock Mic B | ||
1328 | * 0x01, 0x08: Dock ADC 1 Left | ||
1329 | * 0x01, 0x0c: Dock ADC 1 Right | ||
1330 | * 0x01, 0x10: Dock ADC 2 Left | ||
1331 | * 0x01, 0x14: Dock ADC 2 Right | ||
1332 | * 0x01, 0x18: Dock ADC 3 Left | ||
1333 | * 0x01, 0x1c: Dock ADC 3 Right | ||
1334 | * 0x02, 0x00: Hana ADC Left | ||
1335 | * 0x02, 0x01: Hana ADC Right | ||
1336 | * 0x03, 0x00-0x0f: 16 inputs from Alice2 Emu32A output | ||
1337 | * 0x03, 0x10-0x1f: 16 inputs from Alice2 Emu32B output | ||
1338 | * 0x04, 0x00-0x07: Hana ADAT | ||
1339 | * 0x05, 0x00: Hana S/PDIF Left | ||
1340 | * 0x05, 0x01: Hana S/PDIF Right | ||
1341 | * 0x06-0x07: Not used | ||
1342 | * | ||
1343 | * Hana2 never released, but used Tina | ||
1344 | * Not needed. | ||
1345 | * | ||
1346 | * Hana3, rev2 1010,1212,1616 using Tina | ||
1347 | * Sources SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1348 | * 0x00,0x00-0x1f: Silence | ||
1349 | * 0x01, 0x10-0x1f: 32 Elink channels from Audio Dock | ||
1350 | * 0x01, 0x00: Dock Mic A | ||
1351 | * 0x01, 0x04: Dock Mic B | ||
1352 | * 0x01, 0x08: Dock ADC 1 Left | ||
1353 | * 0x01, 0x0c: Dock ADC 1 Right | ||
1354 | * 0x01, 0x10: Dock ADC 2 Left | ||
1355 | * 0x01, 0x12: Dock S/PDIF Left | ||
1356 | * 0x01, 0x14: Dock ADC 2 Right | ||
1357 | * 0x01, 0x16: Dock S/PDIF Right | ||
1358 | * 0x01, 0x18-0x1f: Dock ADAT 0-7 | ||
1359 | * 0x01, 0x18: Dock ADC 3 Left | ||
1360 | * 0x01, 0x1c: Dock ADC 3 Right | ||
1361 | * 0x02, 0x00: Hanoa ADC Left | ||
1362 | * 0x02, 0x01: Hanoa ADC Right | ||
1363 | * 0x03, 0x00-0x0f: 16 inputs from Tina Emu32A output | ||
1364 | * 0x03, 0x10-0x1f: 16 inputs from Tina Emu32B output | ||
1365 | * 0x04, 0x00-0x07: Hana3 ADAT | ||
1366 | * 0x05, 0x00: Hana3 S/PDIF Left | ||
1367 | * 0x05, 0x01: Hana3 S/PDIF Right | ||
1368 | * 0x06-0x07: Not used | ||
1369 | * | ||
1370 | * HanaLite, rev1 0404 using Alice2 | ||
1371 | * Sources SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1372 | * 0x00,0x00-0x1f: Silence | ||
1373 | * 0x01: Not used | ||
1374 | * 0x02, 0x00: ADC Left | ||
1375 | * 0x02, 0x01: ADC Right | ||
1376 | * 0x03, 0x00-0x0f: 16 inputs from Alice2 Emu32A output | ||
1377 | * 0x03, 0x10-0x1f: 16 inputs from Alice2 Emu32B output | ||
1378 | * 0x04: Not used | ||
1379 | * 0x05, 0x00: S/PDIF Left | ||
1380 | * 0x05, 0x01: S/PDIF Right | ||
1381 | * 0x06-0x07: Not used | ||
1382 | * | ||
1383 | * HanaLiteLite, rev2 0404 using Alice2 | ||
1384 | * Sources SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1385 | * 0x00,0x00-0x1f: Silence | ||
1386 | * 0x01: Not used | ||
1387 | * 0x02, 0x00: ADC Left | ||
1388 | * 0x02, 0x01: ADC Right | ||
1389 | * 0x03, 0x00-0x0f: 16 inputs from Alice2 Emu32A output | ||
1390 | * 0x03, 0x10-0x1f: 16 inputs from Alice2 Emu32B output | ||
1391 | * 0x04: Not used | ||
1392 | * 0x05, 0x00: S/PDIF Left | ||
1393 | * 0x05, 0x01: S/PDIF Right | ||
1394 | * 0x06-0x07: Not used | ||
1395 | * | ||
1396 | * Mana, Cardbus 1616 using Tina2 | ||
1397 | * Sources SRATEX = 1X rates: 44.1 kHz or 48 kHz | ||
1398 | * 0x00,0x00-0x1f: Silence | ||
1399 | * 0x01, 0x10-0x1f: 32 Elink channels from Audio Dock | ||
1400 | * 0x01, 0x00: Dock Mic A | ||
1401 | * 0x01, 0x04: Dock Mic B | ||
1402 | * 0x01, 0x08: Dock ADC 1 Left | ||
1403 | * 0x01, 0x0c: Dock ADC 1 Right | ||
1404 | * 0x01, 0x10: Dock ADC 2 Left | ||
1405 | * 0x01, 0x12: Dock S/PDIF Left | ||
1406 | * 0x01, 0x14: Dock ADC 2 Right | ||
1407 | * 0x01, 0x16: Dock S/PDIF Right | ||
1408 | * 0x01, 0x18-0x1f: Dock ADAT 0-7 | ||
1409 | * 0x01, 0x18: Dock ADC 3 Left | ||
1410 | * 0x01, 0x1c: Dock ADC 3 Right | ||
1411 | * 0x02: Not used | ||
1412 | * 0x03, 0x00-0x0f: 16 inputs from Tina Emu32A output | ||
1413 | * 0x03, 0x10-0x1f: 16 inputs from Tina Emu32B output | ||
1414 | * 0x04-0x07: Not used | ||
1415 | * | ||
1416 | */ | ||
1417 | |||
1212 | /* 32-bit sources of signal in the Hana FPGA. The sources are routed to | 1418 | /* 32-bit sources of signal in the Hana FPGA. The sources are routed to |
1213 | * destinations using mixer control for each destination - see emumixer.c | 1419 | * destinations using mixer control for each destination - see emumixer.c |
1214 | * Sources are either physical inputs of FPGA, | 1420 | * Sources are either physical inputs of FPGA, |
@@ -1263,6 +1469,19 @@ | |||
1263 | #define EMU_SRC_HANA_SPDIF_LEFT2 0x0502 /* Hana SPDIF Left, 2nd or 96kHz */ | 1469 | #define EMU_SRC_HANA_SPDIF_LEFT2 0x0502 /* Hana SPDIF Left, 2nd or 96kHz */ |
1264 | #define EMU_SRC_HANA_SPDIF_RIGHT1 0x0501 /* Hana SPDIF Right, 1st or 48kHz only */ | 1470 | #define EMU_SRC_HANA_SPDIF_RIGHT1 0x0501 /* Hana SPDIF Right, 1st or 48kHz only */ |
1265 | #define EMU_SRC_HANA_SPDIF_RIGHT2 0x0503 /* Hana SPDIF Right, 2nd or 96kHz */ | 1471 | #define EMU_SRC_HANA_SPDIF_RIGHT2 0x0503 /* Hana SPDIF Right, 2nd or 96kHz */ |
1472 | |||
1473 | /* Additional inputs for 1616(M)/Microdock */ | ||
1474 | /* Microdock S/PDIF Left, 1st or 48kHz only */ | ||
1475 | #define EMU_SRC_MDOCK_SPDIF_LEFT1 0x0112 | ||
1476 | /* Microdock S/PDIF Left, 2nd or 96kHz */ | ||
1477 | #define EMU_SRC_MDOCK_SPDIF_LEFT2 0x0113 | ||
1478 | /* Microdock S/PDIF Right, 1st or 48kHz only */ | ||
1479 | #define EMU_SRC_MDOCK_SPDIF_RIGHT1 0x0116 | ||
1480 | /* Microdock S/PDIF Right, 2nd or 96kHz */ | ||
1481 | #define EMU_SRC_MDOCK_SPDIF_RIGHT2 0x0117 | ||
1482 | /* Microdock ADAT 8 channel in +8 to +f */ | ||
1483 | #define EMU_SRC_MDOCK_ADAT 0x0118 | ||
1484 | |||
1266 | /* 0x600 and 0x700 no used */ | 1485 | /* 0x600 and 0x700 no used */ |
1267 | 1486 | ||
1268 | /* ------------------- STRUCTURES -------------------- */ | 1487 | /* ------------------- STRUCTURES -------------------- */ |
@@ -1423,6 +1642,14 @@ struct snd_emu10k1_midi { | |||
1423 | void (*interrupt)(struct snd_emu10k1 *emu, unsigned int status); | 1642 | void (*interrupt)(struct snd_emu10k1 *emu, unsigned int status); |
1424 | }; | 1643 | }; |
1425 | 1644 | ||
1645 | enum { | ||
1646 | EMU_MODEL_SB, | ||
1647 | EMU_MODEL_EMU1010, | ||
1648 | EMU_MODEL_EMU1010B, | ||
1649 | EMU_MODEL_EMU1616, | ||
1650 | EMU_MODEL_EMU0404, | ||
1651 | }; | ||
1652 | |||
1426 | struct snd_emu_chip_details { | 1653 | struct snd_emu_chip_details { |
1427 | u32 vendor; | 1654 | u32 vendor; |
1428 | u32 device; | 1655 | u32 device; |
@@ -1439,7 +1666,7 @@ struct snd_emu_chip_details { | |||
1439 | unsigned char spdif_bug; /* Has Spdif phasing bug */ | 1666 | unsigned char spdif_bug; /* Has Spdif phasing bug */ |
1440 | unsigned char ac97_chip; /* Has an AC97 chip: 1 = mandatory, 2 = optional */ | 1667 | unsigned char ac97_chip; /* Has an AC97 chip: 1 = mandatory, 2 = optional */ |
1441 | unsigned char ecard; /* APS EEPROM */ | 1668 | unsigned char ecard; /* APS EEPROM */ |
1442 | unsigned char emu1010; /* EMU 1010m card */ | 1669 | unsigned char emu_model; /* EMU model type */ |
1443 | unsigned char spi_dac; /* SPI interface for DAC */ | 1670 | unsigned char spi_dac; /* SPI interface for DAC */ |
1444 | unsigned char i2c_adc; /* I2C interface for ADC */ | 1671 | unsigned char i2c_adc; /* I2C interface for ADC */ |
1445 | unsigned char adc_1361t; /* Use Philips 1361T ADC */ | 1672 | unsigned char adc_1361t; /* Use Philips 1361T ADC */ |
@@ -1515,6 +1742,8 @@ struct snd_emu10k1 { | |||
1515 | spinlock_t reg_lock; | 1742 | spinlock_t reg_lock; |
1516 | spinlock_t emu_lock; | 1743 | spinlock_t emu_lock; |
1517 | spinlock_t voice_lock; | 1744 | spinlock_t voice_lock; |
1745 | spinlock_t spi_lock; /* serialises access to spi port */ | ||
1746 | spinlock_t i2c_lock; /* serialises access to i2c port */ | ||
1518 | 1747 | ||
1519 | struct snd_emu10k1_voice voices[NUM_G]; | 1748 | struct snd_emu10k1_voice voices[NUM_G]; |
1520 | struct snd_emu10k1_voice p16v_voices[4]; | 1749 | struct snd_emu10k1_voice p16v_voices[4]; |