summaryrefslogtreecommitdiffstats
path: root/sound/firewire/dice/dice.h
diff options
context:
space:
mode:
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>2018-05-02 19:16:39 +0900
committerTakashi Iwai <tiwai@suse.de>2018-05-02 16:01:50 +0200
commit8feda7ddb6a3047609060840a4631b70623b0131 (patch)
treef4e681dbc6c2f03d372fadd720f9699def2403ff /sound/firewire/dice/dice.h
parent6a300dc95e855d60a4c123a4a81becc938f6360a (diff)
downloadlinux-8feda7ddb6a3047609060840a4631b70623b0131.tar.bz2
ALSA: dice: add cache of stream formats
A previous commit 6f688268b3f4 ('ALSA: dice: purge generating channel cache') purged cache of stream formats. DICE interface originally has no feature to assist drivers to retrieve available formats for all of supported sampling transmission frequencies, without changing the frequency actually. For later release of Dice ASICs such as TCD2210, Dice interface has extended protocol and can support the feature. This assists drivers to retrieve available stream formats. This commit is a first step to regain the cache to generate PCM rules for all of supported sampling transmission frequencies. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/firewire/dice/dice.h')
-rw-r--r--sound/firewire/dice/dice.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/firewire/dice/dice.h b/sound/firewire/dice/dice.h
index da00e75e09d4..8f68976930c5 100644
--- a/sound/firewire/dice/dice.h
+++ b/sound/firewire/dice/dice.h
@@ -63,6 +63,13 @@
*/
#define MAX_STREAMS 2
+enum snd_dice_rate_mode {
+ SND_DICE_RATE_MODE_LOW = 0,
+ SND_DICE_RATE_MODE_MIDDLE,
+ SND_DICE_RATE_MODE_HIGH,
+ SND_DICE_RATE_MODE_COUNT,
+};
+
struct snd_dice {
struct snd_card *card;
struct fw_unit *unit;
@@ -80,6 +87,10 @@ struct snd_dice {
unsigned int rsrv_offset;
unsigned int clock_caps;
+ unsigned int tx_pcm_chs[MAX_STREAMS][SND_DICE_RATE_MODE_COUNT];
+ unsigned int rx_pcm_chs[MAX_STREAMS][SND_DICE_RATE_MODE_COUNT];
+ unsigned int tx_midi_ports[MAX_STREAMS];
+ unsigned int rx_midi_ports[MAX_STREAMS];
struct fw_address_handler notification_handler;
int owner_generation;