| 1 |
// SPDX-License-Identifier: GPL-2.0-only |
| 2 |
/* |
| 3 |
* bebob.c - a part of driver for BeBoB based devices |
| 4 |
* |
| 5 |
* Copyright (c) 2013-2014 Takashi Sakamoto |
| 6 |
*/ |
| 7 |
|
| 8 |
/* |
| 9 |
* BeBoB is 'BridgeCo enhanced Breakout Box'. This is installed to firewire |
| 10 |
* devices with DM1000/DM1100/DM1500 chipset. It gives common way for host |
| 11 |
* system to handle BeBoB based devices. |
| 12 |
*/ |
| 13 |
|
| 14 |
#include "bebob.h" |
| 15 |
|
| 16 |
MODULE_DESCRIPTION("BridgeCo BeBoB driver"); |
| 17 |
MODULE_AUTHOR("Takashi Sakamoto <[email protected]>"); |
| 18 |
MODULE_LICENSE("GPL"); |
| 19 |
|
| 20 |
static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; |
| 21 |
static char *id[SNDRV_CARDS] = SNDRV_DEFAULT_STR; |
| 22 |
static bool enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE_PNP; |
| 23 |
|
| 24 |
module_param_array(index, int, NULL, 0444); |
| 25 |
MODULE_PARM_DESC(index, "card index"); |
| 26 |
module_param_array(id, charp, NULL, 0444); |
| 27 |
MODULE_PARM_DESC(id, "ID string"); |
| 28 |
module_param_array(enable, bool, NULL, 0444); |
| 29 |
MODULE_PARM_DESC(enable, "enable BeBoB sound card"); |
| 30 |
|
| 31 |
static DEFINE_MUTEX(devices_mutex); |
| 32 |
static DECLARE_BITMAP(devices_used, SNDRV_CARDS); |
| 33 |
|
| 34 |
/* Offsets from information register. */ |
| 35 |
#define INFO_OFFSET_BEBOB_VERSION 0x08 |
| 36 |
#define INFO_OFFSET_GUID 0x10 |
| 37 |
#define INFO_OFFSET_HW_MODEL_ID 0x18 |
| 38 |
#define INFO_OFFSET_HW_MODEL_REVISION 0x1c |
| 39 |
|
| 40 |
#define VEN_EDIROL 0x000040ab |
| 41 |
#define VEN_PRESONUS 0x00000a92 |
| 42 |
#define VEN_BRIDGECO 0x000007f5 |
| 43 |
#define VEN_MACKIE 0x00000ff2 |
| 44 |
#define VEN_STANTON 0x00001260 |
| 45 |
#define VEN_TASCAM 0x0000022e |
| 46 |
#define VEN_BEHRINGER 0x00001564 |
| 47 |
#define VEN_APOGEE 0x000003db |
| 48 |
#define VEN_ESI 0x00000f1b |
| 49 |
#define VEN_CME 0x0000000a |
| 50 |
#define VEN_PHONIC 0x00001496 |
| 51 |
#define VEN_LYNX 0x000019e5 |
| 52 |
#define VEN_ICON 0x00001a9e |
| 53 |
#define VEN_PRISMSOUND 0x00001198 |
| 54 |
#define VEN_TERRATEC 0x00000aac |
| 55 |
#define VEN_YAMAHA 0x0000a0de |
| 56 |
#define VEN_FOCUSRITE 0x0000130e |
| 57 |
#define VEN_MAUDIO 0x00000d6c |
| 58 |
#define VEN_DIGIDESIGN 0x00a07e |
| 59 |
#define OUI_SHOUYO 0x002327 |
| 60 |
|
| 61 |
#define MODEL_FOCUSRITE_SAFFIRE_BOTH 0x00000000 |
| 62 |
#define MODEL_MAUDIO_AUDIOPHILE_BOTH 0x00010060 |
| 63 |
#define MODEL_MAUDIO_FW1814 0x00010071 |
| 64 |
#define MODEL_MAUDIO_PROJECTMIX 0x00010091 |
| 65 |
#define MODEL_MAUDIO_PROFIRELIGHTBRIDGE 0x000100a1 |
| 66 |
|
| 67 |
static int |
| 68 |
name_device(struct snd_bebob *bebob) |
| 69 |
{ |
| 70 |
struct fw_device *fw_dev = fw_parent_device(bebob->unit); |
| 71 |
char vendor[24] = {0}; |
| 72 |
char model[32] = {0}; |
| 73 |
u32 hw_id; |
| 74 |
u32 data[2] = {0}; |
| 75 |
u32 revision; |
| 76 |
int err; |
| 77 |
|
| 78 |
/* get vendor name from root directory */ |
| 79 |
err = fw_csr_string(fw_dev->config_rom + 5, CSR_VENDOR, |
| 80 |
vendor, sizeof(vendor)); |
| 81 |
if (err < 0) |
| 82 |
goto end; |
| 83 |
|
| 84 |
/* get model name from unit directory */ |
| 85 |
err = fw_csr_string(bebob->unit->directory, CSR_MODEL, |
| 86 |
model, sizeof(model)); |
| 87 |
if (err < 0) |
| 88 |
goto end; |
| 89 |
|
| 90 |
/* get hardware id */ |
| 91 |
err = snd_bebob_read_quad(bebob->unit, INFO_OFFSET_HW_MODEL_ID, |
| 92 |
&hw_id); |
| 93 |
if (err < 0) |
| 94 |
goto end; |
| 95 |
|
| 96 |
/* get hardware revision */ |
| 97 |
err = snd_bebob_read_quad(bebob->unit, INFO_OFFSET_HW_MODEL_REVISION, |
| 98 |
&revision); |
| 99 |
if (err < 0) |
| 100 |
goto end; |
| 101 |
|
| 102 |
/* get GUID */ |
| 103 |
err = snd_bebob_read_block(bebob->unit, INFO_OFFSET_GUID, |
| 104 |
data, sizeof(data)); |
| 105 |
if (err < 0) |
| 106 |
goto end; |
| 107 |
|
| 108 |
strscpy(bebob->card->driver, "BeBoB"); |
| 109 |
strscpy(bebob->card->shortname, model); |
| 110 |
strscpy(bebob->card->mixername, model); |
| 111 |
snprintf(bebob->card->longname, sizeof(bebob->card->longname), |
| 112 |
"%s %s (id:%d, rev:%d), GUID %08x%08x at %s, S%d", |
| 113 |
vendor, model, hw_id, revision, |
| 114 |
data[0], data[1], dev_name(&bebob->unit->device), |
| 115 |
100 << fw_dev->max_speed); |
| 116 |
end: |
| 117 |
return err; |
| 118 |
} |
| 119 |
|
| 120 |
static void |
| 121 |
bebob_card_free(struct snd_card *card) |
| 122 |
{ |
| 123 |
struct snd_bebob *bebob = card->private_data; |
| 124 |
|
| 125 |
scoped_guard(mutex, &devices_mutex) { |
| 126 |
clear_bit(bebob->card_index, devices_used); |
| 127 |
} |
| 128 |
|
| 129 |
snd_bebob_stream_destroy_duplex(bebob); |
| 130 |
|
| 131 |
mutex_destroy(&bebob->mutex); |
| 132 |
fw_unit_put(bebob->unit); |
| 133 |
} |
| 134 |
|
| 135 |
static const struct snd_bebob_spec * |
| 136 |
get_saffire_spec(struct fw_unit *unit) |
| 137 |
{ |
| 138 |
char name[24] = {0}; |
| 139 |
|
| 140 |
if (fw_csr_string(unit->directory, CSR_MODEL, name, sizeof(name)) < 0) |
| 141 |
return NULL; |
| 142 |
|
| 143 |
if (strcmp(name, "SaffireLE") == 0) |
| 144 |
return &saffire_le_spec; |
| 145 |
else |
| 146 |
return &saffire_spec; |
| 147 |
} |
| 148 |
|
| 149 |
static bool |
| 150 |
check_audiophile_booted(struct fw_unit *unit) |
| 151 |
{ |
| 152 |
char name[28] = {0}; |
| 153 |
|
| 154 |
if (fw_csr_string(unit->directory, CSR_MODEL, name, sizeof(name)) < 0) |
| 155 |
return false; |
| 156 |
|
| 157 |
return strncmp(name, "FW Audiophile Bootloader", 24) != 0; |
| 158 |
} |
| 159 |
|
| 160 |
static int detect_quirks(struct snd_bebob *bebob, const struct ieee1394_device_id *entry) |
| 161 |
{ |
| 162 |
if (entry->vendor_id == VEN_MAUDIO) { |
| 163 |
switch (entry->model_id) { |
| 164 |
case MODEL_MAUDIO_PROFIRELIGHTBRIDGE: |
| 165 |
// M-Audio ProFire Lightbridge has a quirk to transfer packets with |
| 166 |
// discontinuous cycle or data block counter in early stage of packet |
| 167 |
// streaming. The cycle span from the first packet with event is variable. |
| 168 |
bebob->quirks |= SND_BEBOB_QUIRK_INITIAL_DISCONTINUOUS_DBC; |
| 169 |
break; |
| 170 |
case MODEL_MAUDIO_FW1814: |
| 171 |
case MODEL_MAUDIO_PROJECTMIX: |
| 172 |
// At high sampling rate, M-Audio special firmware transmits empty packet |
| 173 |
// with the value of dbc incremented by 8. |
| 174 |
bebob->quirks |= SND_BEBOB_QUIRK_WRONG_DBC; |
| 175 |
break; |
| 176 |
default: |
| 177 |
break; |
| 178 |
} |
| 179 |
} |
| 180 |
|
| 181 |
return 0; |
| 182 |
} |
| 183 |
|
| 184 |
static int bebob_probe(struct fw_unit *unit, const struct ieee1394_device_id *entry) |
| 185 |
{ |
| 186 |
unsigned int card_index; |
| 187 |
struct snd_card *card; |
| 188 |
struct snd_bebob *bebob; |
| 189 |
const struct snd_bebob_spec *spec; |
| 190 |
int err; |
| 191 |
|
| 192 |
if (entry->vendor_id == VEN_FOCUSRITE && |
| 193 |
entry->model_id == MODEL_FOCUSRITE_SAFFIRE_BOTH) |
| 194 |
spec = get_saffire_spec(unit); |
| 195 |
else if (entry->vendor_id == VEN_MAUDIO && |
| 196 |
entry->model_id == MODEL_MAUDIO_AUDIOPHILE_BOTH && |
| 197 |
!check_audiophile_booted(unit)) |
| 198 |
spec = NULL; |
| 199 |
else |
| 200 |
spec = (const struct snd_bebob_spec *)entry->driver_data; |
| 201 |
|
| 202 |
if (spec == NULL) { |
| 203 |
// To boot up M-Audio models. |
| 204 |
if (entry->vendor_id == VEN_MAUDIO || entry->vendor_id == VEN_BRIDGECO) |
| 205 |
return snd_bebob_maudio_load_firmware(unit); |
| 206 |
else |
| 207 |
return -ENODEV; |
| 208 |
} |
| 209 |
|
| 210 |
scoped_guard(mutex, &devices_mutex) { |
| 211 |
for (card_index = 0; card_index < SNDRV_CARDS; card_index++) { |
| 212 |
if (!test_bit(card_index, devices_used) && enable[card_index]) |
| 213 |
break; |
| 214 |
} |
| 215 |
if (card_index >= SNDRV_CARDS) |
| 216 |
return -ENOENT; |
| 217 |
|
| 218 |
err = snd_card_new(&unit->device, index[card_index], id[card_index], THIS_MODULE, |
| 219 |
sizeof(*bebob), &card); |
| 220 |
if (err < 0) |
| 221 |
return err; |
| 222 |
card->private_free = bebob_card_free; |
| 223 |
set_bit(card_index, devices_used); |
| 224 |
} |
| 225 |
|
| 226 |
bebob = card->private_data; |
| 227 |
bebob->unit = fw_unit_get(unit); |
| 228 |
dev_set_drvdata(&unit->device, bebob); |
| 229 |
bebob->card = card; |
| 230 |
bebob->card_index = card_index; |
| 231 |
|
| 232 |
bebob->spec = spec; |
| 233 |
mutex_init(&bebob->mutex); |
| 234 |
spin_lock_init(&bebob->lock); |
| 235 |
init_waitqueue_head(&bebob->hwdep_wait); |
| 236 |
|
| 237 |
err = name_device(bebob); |
| 238 |
if (err < 0) |
| 239 |
goto error; |
| 240 |
|
| 241 |
err = detect_quirks(bebob, entry); |
| 242 |
if (err < 0) |
| 243 |
goto error; |
| 244 |
|
| 245 |
if (bebob->spec == &maudio_special_spec) { |
| 246 |
if (entry->model_id == MODEL_MAUDIO_FW1814) |
| 247 |
err = snd_bebob_maudio_special_discover(bebob, true); |
| 248 |
else |
| 249 |
err = snd_bebob_maudio_special_discover(bebob, false); |
| 250 |
} else { |
| 251 |
err = snd_bebob_stream_discover(bebob); |
| 252 |
} |
| 253 |
if (err < 0) |
| 254 |
goto error; |
| 255 |
|
| 256 |
err = snd_bebob_stream_init_duplex(bebob); |
| 257 |
if (err < 0) |
| 258 |
goto error; |
| 259 |
|
| 260 |
snd_bebob_proc_init(bebob); |
| 261 |
|
| 262 |
if (bebob->midi_input_ports > 0 || bebob->midi_output_ports > 0) { |
| 263 |
err = snd_bebob_create_midi_devices(bebob); |
| 264 |
if (err < 0) |
| 265 |
goto error; |
| 266 |
} |
| 267 |
|
| 268 |
err = snd_bebob_create_pcm_devices(bebob); |
| 269 |
if (err < 0) |
| 270 |
goto error; |
| 271 |
|
| 272 |
err = snd_bebob_create_hwdep_device(bebob); |
| 273 |
if (err < 0) |
| 274 |
goto error; |
| 275 |
|
| 276 |
err = snd_card_register(card); |
| 277 |
if (err < 0) |
| 278 |
goto error; |
| 279 |
|
| 280 |
if (entry->vendor_id == VEN_MAUDIO && |
| 281 |
(entry->model_id == MODEL_MAUDIO_FW1814 || entry->model_id == MODEL_MAUDIO_PROJECTMIX)) { |
| 282 |
// This is a workaround. This bus reset seems to have an effect to make devices |
| 283 |
// correctly handling transactions. Without this, the devices have gap_count |
| 284 |
// mismatch. This causes much failure of transaction. |
| 285 |
// |
| 286 |
// Just after registration, user-land application receive signals from dbus and |
| 287 |
// starts I/Os. To avoid I/Os till the future bus reset, registration is done in |
| 288 |
// next update(). |
| 289 |
fw_schedule_bus_reset(fw_parent_device(bebob->unit)->card, false, true); |
| 290 |
} |
| 291 |
|
| 292 |
return 0; |
| 293 |
error: |
| 294 |
snd_card_free(card); |
| 295 |
return err; |
| 296 |
} |
| 297 |
|
| 298 |
/* |
| 299 |
* This driver doesn't update streams in bus reset handler. |
| 300 |
* |
| 301 |
* DM1000/ DM1100/DM1500 chipsets with BeBoB firmware transfer packets with |
| 302 |
* discontinued counter at bus reset. This discontinuity is immediately |
| 303 |
* detected in packet streaming layer, then it sets XRUN to PCM substream. |
| 304 |
* |
| 305 |
* ALSA PCM applications can know the XRUN by getting -EPIPE from PCM operation. |
| 306 |
* Then, they can recover the PCM substream by executing ioctl(2) with |
| 307 |
* SNDRV_PCM_IOCTL_PREPARE. 'struct snd_pcm_ops.prepare' is called and drivers |
| 308 |
* restart packet streaming. |
| 309 |
* |
| 310 |
* The above processing may be executed before this bus-reset handler is |
| 311 |
* executed. When this handler updates streams with current isochronous |
| 312 |
* channels, the streams already have the current ones. |
| 313 |
*/ |
| 314 |
static void |
| 315 |
bebob_update(struct fw_unit *unit) |
| 316 |
{ |
| 317 |
struct snd_bebob *bebob = dev_get_drvdata(&unit->device); |
| 318 |
|
| 319 |
if (bebob == NULL) |
| 320 |
return; |
| 321 |
|
| 322 |
fcp_bus_reset(bebob->unit); |
| 323 |
} |
| 324 |
|
| 325 |
static void bebob_remove(struct fw_unit *unit) |
| 326 |
{ |
| 327 |
struct snd_bebob *bebob = dev_get_drvdata(&unit->device); |
| 328 |
|
| 329 |
if (bebob == NULL) |
| 330 |
return; |
| 331 |
|
| 332 |
// Block till all of ALSA character devices are released. |
| 333 |
snd_card_free(bebob->card); |
| 334 |
} |
| 335 |
|
| 336 |
static const struct snd_bebob_rate_spec normal_rate_spec = { |
| 337 |
.get = &snd_bebob_stream_get_rate, |
| 338 |
.set = &snd_bebob_stream_set_rate |
| 339 |
}; |
| 340 |
static const struct snd_bebob_spec spec_normal = { |
| 341 |
.clock = NULL, |
| 342 |
.rate = &normal_rate_spec, |
| 343 |
.meter = NULL |
| 344 |
}; |
| 345 |
|
| 346 |
#define SPECIFIER_1394TA 0x00a02d |
| 347 |
|
| 348 |
// The immediate entry for version in unit directory differs depending on models: |
| 349 |
// * 0x010001 |
| 350 |
// * 0x014001 |
| 351 |
#define SND_BEBOB_DEV_ENTRY(vendor, model, data) \ |
| 352 |
{ \ |
| 353 |
.match_flags = IEEE1394_MATCH_VENDOR_ID | \ |
| 354 |
IEEE1394_MATCH_MODEL_ID | \ |
| 355 |
IEEE1394_MATCH_SPECIFIER_ID, \ |
| 356 |
.vendor_id = vendor, \ |
| 357 |
.model_id = model, \ |
| 358 |
.specifier_id = SPECIFIER_1394TA, \ |
| 359 |
.driver_data = (kernel_ulong_t)data \ |
| 360 |
} |
| 361 |
|
| 362 |
static const struct ieee1394_device_id bebob_id_table[] = { |
| 363 |
/* Edirol, FA-66 */ |
| 364 |
SND_BEBOB_DEV_ENTRY(VEN_EDIROL, 0x00010049, &spec_normal), |
| 365 |
/* Edirol, FA-101 */ |
| 366 |
SND_BEBOB_DEV_ENTRY(VEN_EDIROL, 0x00010048, &spec_normal), |
| 367 |
/* Presonus, FIREBOX */ |
| 368 |
SND_BEBOB_DEV_ENTRY(VEN_PRESONUS, 0x00010000, &spec_normal), |
| 369 |
/* PreSonus, FIREPOD/FP10 */ |
| 370 |
SND_BEBOB_DEV_ENTRY(VEN_PRESONUS, 0x00010066, &spec_normal), |
| 371 |
/* PreSonus, Inspire1394 */ |
| 372 |
SND_BEBOB_DEV_ENTRY(VEN_PRESONUS, 0x00010001, &spec_normal), |
| 373 |
/* BridgeCo, RDAudio1 */ |
| 374 |
SND_BEBOB_DEV_ENTRY(VEN_BRIDGECO, 0x00010048, &spec_normal), |
| 375 |
/* BridgeCo, Audio5 */ |
| 376 |
SND_BEBOB_DEV_ENTRY(VEN_BRIDGECO, 0x00010049, &spec_normal), |
| 377 |
/* Mackie, Onyx 1220/1620/1640 (Firewire I/O Card) */ |
| 378 |
SND_BEBOB_DEV_ENTRY(VEN_MACKIE, 0x00010065, &spec_normal), |
| 379 |
// Mackie, d.2 (optional Firewire card with DM1000). |
| 380 |
SND_BEBOB_DEV_ENTRY(VEN_MACKIE, 0x00010067, &spec_normal), |
| 381 |
/* Stanton, ScratchAmp */ |
| 382 |
SND_BEBOB_DEV_ENTRY(VEN_STANTON, 0x00000001, &spec_normal), |
| 383 |
/* Tascam, IF-FW DM */ |
| 384 |
SND_BEBOB_DEV_ENTRY(VEN_TASCAM, 0x00010067, &spec_normal), |
| 385 |
/* Behringer, XENIX UFX 1204 */ |
| 386 |
SND_BEBOB_DEV_ENTRY(VEN_BEHRINGER, 0x00001204, &spec_normal), |
| 387 |
/* Behringer, XENIX UFX 1604 */ |
| 388 |
SND_BEBOB_DEV_ENTRY(VEN_BEHRINGER, 0x00001604, &spec_normal), |
| 389 |
/* Behringer, Digital Mixer X32 series (X-UF Card) */ |
| 390 |
SND_BEBOB_DEV_ENTRY(VEN_BEHRINGER, 0x00000006, &spec_normal), |
| 391 |
/* Behringer, F-Control Audio 1616 */ |
| 392 |
SND_BEBOB_DEV_ENTRY(VEN_BEHRINGER, 0x001616, &spec_normal), |
| 393 |
/* Behringer, F-Control Audio 610 */ |
| 394 |
SND_BEBOB_DEV_ENTRY(VEN_BEHRINGER, 0x000610, &spec_normal), |
| 395 |
/* Apogee Electronics, Rosetta 200/400 (X-FireWire card) */ |
| 396 |
/* Apogee Electronics, DA/AD/DD-16X (X-FireWire card) */ |
| 397 |
SND_BEBOB_DEV_ENTRY(VEN_APOGEE, 0x00010048, &spec_normal), |
| 398 |
/* Apogee Electronics, Ensemble */ |
| 399 |
SND_BEBOB_DEV_ENTRY(VEN_APOGEE, 0x01eeee, &spec_normal), |
| 400 |
/* ESI, Quatafire610 */ |
| 401 |
SND_BEBOB_DEV_ENTRY(VEN_ESI, 0x00010064, &spec_normal), |
| 402 |
/* CME, MatrixKFW */ |
| 403 |
SND_BEBOB_DEV_ENTRY(VEN_CME, 0x00030000, &spec_normal), |
| 404 |
// Phonic Helix Board 12 FireWire MkII. |
| 405 |
SND_BEBOB_DEV_ENTRY(VEN_PHONIC, 0x00050000, &spec_normal), |
| 406 |
// Phonic Helix Board 18 FireWire MkII. |
| 407 |
SND_BEBOB_DEV_ENTRY(VEN_PHONIC, 0x00060000, &spec_normal), |
| 408 |
// Phonic Helix Board 24 FireWire MkII. |
| 409 |
SND_BEBOB_DEV_ENTRY(VEN_PHONIC, 0x00070000, &spec_normal), |
| 410 |
// Phonic FireFly 808 FireWire. |
| 411 |
SND_BEBOB_DEV_ENTRY(VEN_PHONIC, 0x00080000, &spec_normal), |
| 412 |
// Phonic FireFly 202, 302, 808 Universal. |
| 413 |
// Phinic Helix Board 12/18/24 FireWire, 12/18/24 Universal |
| 414 |
SND_BEBOB_DEV_ENTRY(VEN_PHONIC, 0x00000000, &spec_normal), |
| 415 |
/* Lynx, Aurora 8/16 (LT-FW) */ |
| 416 |
SND_BEBOB_DEV_ENTRY(VEN_LYNX, 0x00000001, &spec_normal), |
| 417 |
/* ICON, FireXon */ |
| 418 |
SND_BEBOB_DEV_ENTRY(VEN_ICON, 0x00000001, &spec_normal), |
| 419 |
/* PrismSound, Orpheus */ |
| 420 |
SND_BEBOB_DEV_ENTRY(VEN_PRISMSOUND, 0x00010048, &spec_normal), |
| 421 |
/* PrismSound, ADA-8XR */ |
| 422 |
SND_BEBOB_DEV_ENTRY(VEN_PRISMSOUND, 0x0000ada8, &spec_normal), |
| 423 |
/* TerraTec Electronic GmbH, PHASE 88 Rack FW */ |
| 424 |
SND_BEBOB_DEV_ENTRY(VEN_TERRATEC, 0x00000003, &phase88_rack_spec), |
| 425 |
/* TerraTec Electronic GmbH, PHASE 24 FW */ |
| 426 |
SND_BEBOB_DEV_ENTRY(VEN_TERRATEC, 0x00000004, &yamaha_terratec_spec), |
| 427 |
/* TerraTec Electronic GmbH, Phase X24 FW */ |
| 428 |
SND_BEBOB_DEV_ENTRY(VEN_TERRATEC, 0x00000007, &yamaha_terratec_spec), |
| 429 |
/* TerraTec Electronic GmbH, EWS MIC2/MIC8 */ |
| 430 |
SND_BEBOB_DEV_ENTRY(VEN_TERRATEC, 0x00000005, &spec_normal), |
| 431 |
// Terratec Electronic GmbH, Aureon 7.1 Firewire. |
| 432 |
// AcousticReality, eAR Master One, Eroica, Figaro, and Ciaccona. Perhaps Terratec OEM. |
| 433 |
SND_BEBOB_DEV_ENTRY(VEN_TERRATEC, 0x00000002, &spec_normal), |
| 434 |
/* Yamaha, GO44 */ |
| 435 |
SND_BEBOB_DEV_ENTRY(VEN_YAMAHA, 0x0010000b, &yamaha_terratec_spec), |
| 436 |
/* YAMAHA, GO46 */ |
| 437 |
SND_BEBOB_DEV_ENTRY(VEN_YAMAHA, 0x0010000c, &yamaha_terratec_spec), |
| 438 |
/* Focusrite, SaffirePro 26 I/O */ |
| 439 |
SND_BEBOB_DEV_ENTRY(VEN_FOCUSRITE, 0x00000003, &saffirepro_26_spec), |
| 440 |
/* Focusrite, SaffirePro 10 I/O */ |
| 441 |
SND_BEBOB_DEV_ENTRY(VEN_FOCUSRITE, 0x000006, &saffirepro_10_spec), |
| 442 |
/* Focusrite, Saffire(no label and LE) */ |
| 443 |
SND_BEBOB_DEV_ENTRY(VEN_FOCUSRITE, MODEL_FOCUSRITE_SAFFIRE_BOTH, |
| 444 |
&saffire_spec), |
| 445 |
// M-Audio, Firewire 410. The vendor field is left as BridgeCo. AG. |
| 446 |
SND_BEBOB_DEV_ENTRY(VEN_BRIDGECO, 0x00010058, NULL), |
| 447 |
SND_BEBOB_DEV_ENTRY(VEN_BRIDGECO, 0x00010046, &maudio_fw410_spec), |
| 448 |
/* M-Audio, Firewire Audiophile */ |
| 449 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, MODEL_MAUDIO_AUDIOPHILE_BOTH, |
| 450 |
&maudio_audiophile_spec), |
| 451 |
/* M-Audio, Firewire Solo */ |
| 452 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, 0x00010062, &maudio_solo_spec), |
| 453 |
/* M-Audio, Ozonic */ |
| 454 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, 0x0000000a, &maudio_ozonic_spec), |
| 455 |
/* M-Audio NRV10 */ |
| 456 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, 0x00010081, &maudio_nrv10_spec), |
| 457 |
/* M-Audio, ProFireLightbridge */ |
| 458 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, MODEL_MAUDIO_PROFIRELIGHTBRIDGE, &spec_normal), |
| 459 |
/* Firewire 1814 */ |
| 460 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, 0x00010070, NULL), /* bootloader */ |
| 461 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, MODEL_MAUDIO_FW1814, |
| 462 |
&maudio_special_spec), |
| 463 |
/* M-Audio ProjectMix */ |
| 464 |
SND_BEBOB_DEV_ENTRY(VEN_MAUDIO, MODEL_MAUDIO_PROJECTMIX, |
| 465 |
&maudio_special_spec), |
| 466 |
/* Digidesign Mbox 2 Pro */ |
| 467 |
SND_BEBOB_DEV_ENTRY(VEN_DIGIDESIGN, 0x0000a9, &spec_normal), |
| 468 |
// Toneweal FW66. |
| 469 |
SND_BEBOB_DEV_ENTRY(OUI_SHOUYO, 0x020002, &spec_normal), |
| 470 |
/* IDs are unknown but able to be supported */ |
| 471 |
/* Apogee, Mini-ME Firewire */ |
| 472 |
/* Apogee, Mini-DAC Firewire */ |
| 473 |
/* Cakawalk, Sonar Power Studio 66 */ |
| 474 |
/* CME, UF400e */ |
| 475 |
/* ESI, Quotafire XL */ |
| 476 |
/* Infrasonic, DewX */ |
| 477 |
/* Infrasonic, Windy6 */ |
| 478 |
/* Mackie, Digital X Bus x.200 */ |
| 479 |
/* Mackie, Digital X Bus x.400 */ |
| 480 |
/* Rolf Spuler, Firewire Guitar */ |
| 481 |
{} |
| 482 |
}; |
| 483 |
MODULE_DEVICE_TABLE(ieee1394, bebob_id_table); |
| 484 |
|
| 485 |
static struct fw_driver bebob_driver = { |
| 486 |
.driver = { |
| 487 |
.owner = THIS_MODULE, |
| 488 |
.name = KBUILD_MODNAME, |
| 489 |
.bus = &fw_bus_type, |
| 490 |
}, |
| 491 |
.probe = bebob_probe, |
| 492 |
.update = bebob_update, |
| 493 |
.remove = bebob_remove, |
| 494 |
.id_table = bebob_id_table, |
| 495 |
}; |
| 496 |
|
| 497 |
static int __init |
| 498 |
snd_bebob_init(void) |
| 499 |
{ |
| 500 |
return driver_register(&bebob_driver.driver); |
| 501 |
} |
| 502 |
|
| 503 |
static void __exit |
| 504 |
snd_bebob_exit(void) |
| 505 |
{ |
| 506 |
driver_unregister(&bebob_driver.driver); |
| 507 |
} |
| 508 |
|
| 509 |
module_init(snd_bebob_init); |
| 510 |
module_exit(snd_bebob_exit); |