summaryrefslogtreecommitdiff
path: root/sound/firewire/fireface/ff-protocol-latter.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/firewire/fireface/ff-protocol-latter.c')
-rw-r--r--sound/firewire/fireface/ff-protocol-latter.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/firewire/fireface/ff-protocol-latter.c b/sound/firewire/fireface/ff-protocol-latter.c
index 3d12ba5b2a9b..8d6ebb638e93 100644
--- a/sound/firewire/fireface/ff-protocol-latter.c
+++ b/sound/firewire/fireface/ff-protocol-latter.c
@@ -175,6 +175,7 @@ static int latter_allocate_resources(struct snd_ff *ff, unsigned int rate)
static int latter_begin_session(struct snd_ff *ff, unsigned int rate)
{
+ unsigned int generation = ff->rx_resources.generation;
unsigned int flag;
u32 data;
__le32 reg;
@@ -189,6 +190,16 @@ static int latter_begin_session(struct snd_ff *ff, unsigned int rate)
else
return -EINVAL;
+ if (generation != fw_parent_device(ff->unit)->card->generation) {
+ err = fw_iso_resources_update(&ff->tx_resources);
+ if (err < 0)
+ return err;
+
+ err = fw_iso_resources_update(&ff->rx_resources);
+ if (err < 0)
+ return err;
+ }
+
data = (ff->tx_resources.channel << 8) | ff->rx_resources.channel;
reg = cpu_to_le32(data);
err = snd_fw_transaction(ff->unit, TCODE_WRITE_QUADLET_REQUEST,