summaryrefslogtreecommitdiff
path: root/sound/firewire/motu/motu.h
diff options
context:
space:
mode:
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>2017-03-22 21:30:13 +0900
committerTakashi Iwai <tiwai@suse.de>2017-03-28 12:33:21 +0200
commit5e03c33e3d8973e2c10abbf13f8f24779babafeb (patch)
treed602a86eba185bd1154615004407bb71a2b3d6a7 /sound/firewire/motu/motu.h
parent8865a31e0fd8beb157b99e78cdf1f0241a67bd54 (diff)
ALSA: firewire-motu: add a structure for model-dependent parameters.
MOTU FireWire series doesn't tell drivers their capabilities, thus the drivers should have and apply model-dependent parameters to detected models. This commit adds a structure to represent such parameters. Capabilities are represented by enumeration except for the number of analog line in/out. Identification name also be in the structure because the units has no registers for this purpose. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/firewire/motu/motu.h')
-rw-r--r--sound/firewire/motu/motu.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/sound/firewire/motu/motu.h b/sound/firewire/motu/motu.h
index eb0ffd56c835..cb7324d0d558 100644
--- a/sound/firewire/motu/motu.h
+++ b/sound/firewire/motu/motu.h
@@ -29,6 +29,29 @@ struct snd_motu {
bool registered;
struct delayed_work dwork;
+
+ /* Model dependent information. */
+ const struct snd_motu_spec *spec;
+};
+
+enum snd_motu_spec_flags {
+ SND_MOTU_SPEC_SUPPORT_CLOCK_X2 = 0x0001,
+ SND_MOTU_SPEC_SUPPORT_CLOCK_X4 = 0x0002,
+ SND_MOTU_SPEC_TX_MICINST_CHUNK = 0x0004,
+ SND_MOTU_SPEC_TX_RETURN_CHUNK = 0x0008,
+ SND_MOTU_SPEC_TX_REVERB_CHUNK = 0x0010,
+ SND_MOTU_SPEC_TX_AESEBU_CHUNK = 0x0020,
+ SND_MOTU_SPEC_HAS_OPT_IFACE_A = 0x0040,
+ SND_MOTU_SPEC_HAS_OPT_IFACE_B = 0x0080,
+ SND_MOTU_SPEC_HAS_MIDI = 0x0100,
+};
+
+struct snd_motu_spec {
+ const char *const name;
+ enum snd_motu_spec_flags flags;
+
+ unsigned char analog_in_ports;
+ unsigned char analog_out_ports;
};
#endif