--dice->substreams_counter;
snd_dice_stream_stop_duplex(dice);
- snd_dice_stream_release_duplex(dice);
mutex_unlock(&dice->mutex);
--dice->substreams_counter;
snd_dice_stream_stop_duplex(dice);
- snd_dice_stream_release_duplex(dice);
mutex_unlock(&dice->mutex);
return err;
}
-void snd_dice_stream_release_duplex(struct snd_dice *dice)
-{
- if (dice->substreams_counter == 0)
- release_resources(dice);
-}
-
static int start_streams(struct snd_dice *dice, enum amdtp_stream_direction dir,
unsigned int rate, struct reg_params *params)
{
if (dice->substreams_counter == 0) {
if (get_register_params(dice, &tx_params, &rx_params) >= 0)
finish_session(dice, &tx_params, &rx_params);
+
+ release_resources(dice);
}
}
int snd_dice_stream_init_duplex(struct snd_dice *dice);
void snd_dice_stream_destroy_duplex(struct snd_dice *dice);
int snd_dice_stream_reserve_duplex(struct snd_dice *dice, unsigned int rate);
-void snd_dice_stream_release_duplex(struct snd_dice *dice);
void snd_dice_stream_update_duplex(struct snd_dice *dice);
int snd_dice_stream_detect_current_formats(struct snd_dice *dice);