|
@@ -209,11 +209,11 @@ static int oxygen_open(struct snd_pcm_substream *substream,
|
|
chip->pcm_active |= 1 << channel;
|
|
chip->pcm_active |= 1 << channel;
|
|
if (channel == PCM_SPDIF) {
|
|
if (channel == PCM_SPDIF) {
|
|
chip->spdif_pcm_bits = chip->spdif_bits;
|
|
chip->spdif_pcm_bits = chip->spdif_bits;
|
|
- chip->spdif_pcm_ctl->vd[0].access &=
|
|
|
|
|
|
+ chip->controls[CONTROL_SPDIF_PCM]->vd[0].access &=
|
|
~SNDRV_CTL_ELEM_ACCESS_INACTIVE;
|
|
~SNDRV_CTL_ELEM_ACCESS_INACTIVE;
|
|
snd_ctl_notify(chip->card, SNDRV_CTL_EVENT_MASK_VALUE |
|
|
snd_ctl_notify(chip->card, SNDRV_CTL_EVENT_MASK_VALUE |
|
|
SNDRV_CTL_EVENT_MASK_INFO,
|
|
SNDRV_CTL_EVENT_MASK_INFO,
|
|
- &chip->spdif_pcm_ctl->id);
|
|
|
|
|
|
+ &chip->controls[CONTROL_SPDIF_PCM]->id);
|
|
}
|
|
}
|
|
mutex_unlock(&chip->mutex);
|
|
mutex_unlock(&chip->mutex);
|
|
|
|
|
|
@@ -258,11 +258,11 @@ static int oxygen_close(struct snd_pcm_substream *substream)
|
|
mutex_lock(&chip->mutex);
|
|
mutex_lock(&chip->mutex);
|
|
chip->pcm_active &= ~(1 << channel);
|
|
chip->pcm_active &= ~(1 << channel);
|
|
if (channel == PCM_SPDIF) {
|
|
if (channel == PCM_SPDIF) {
|
|
- chip->spdif_pcm_ctl->vd[0].access |=
|
|
|
|
|
|
+ chip->controls[CONTROL_SPDIF_PCM]->vd[0].access |=
|
|
SNDRV_CTL_ELEM_ACCESS_INACTIVE;
|
|
SNDRV_CTL_ELEM_ACCESS_INACTIVE;
|
|
snd_ctl_notify(chip->card, SNDRV_CTL_EVENT_MASK_VALUE |
|
|
snd_ctl_notify(chip->card, SNDRV_CTL_EVENT_MASK_VALUE |
|
|
SNDRV_CTL_EVENT_MASK_INFO,
|
|
SNDRV_CTL_EVENT_MASK_INFO,
|
|
- &chip->spdif_pcm_ctl->id);
|
|
|
|
|
|
+ &chip->controls[CONTROL_SPDIF_PCM]->id);
|
|
}
|
|
}
|
|
if (channel == PCM_SPDIF || channel == PCM_MULTICH)
|
|
if (channel == PCM_SPDIF || channel == PCM_MULTICH)
|
|
oxygen_update_spdif_source(chip);
|
|
oxygen_update_spdif_source(chip);
|