Commit 8feda7dd authored by Takashi Sakamoto's avatar Takashi Sakamoto Committed by Takashi Iwai

ALSA: dice: add cache of stream formats

A previous commit 6f688268 ('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: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 6a300dc9
...@@ -63,6 +63,13 @@ ...@@ -63,6 +63,13 @@
*/ */
#define MAX_STREAMS 2 #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_dice {
struct snd_card *card; struct snd_card *card;
struct fw_unit *unit; struct fw_unit *unit;
...@@ -80,6 +87,10 @@ struct snd_dice { ...@@ -80,6 +87,10 @@ struct snd_dice {
unsigned int rsrv_offset; unsigned int rsrv_offset;
unsigned int clock_caps; 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; struct fw_address_handler notification_handler;
int owner_generation; int owner_generation;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment