Lines Matching refs:cidx
159 static unsigned char get_slot_reg(struct ac97_pcm *pcm, unsigned short cidx, in get_slot_reg() argument
169 return rate_reg_tables[dbl][pcm->r[dbl].rate_table[cidx]][slot - 3]; in get_slot_reg()
408 static unsigned int get_rates(struct ac97_pcm *pcm, unsigned int cidx, unsigned short slots, int db… in get_rates() argument
417 reg = get_slot_reg(pcm, cidx, i, dbl); in get_rates()
426 rates &= pcm->r[dbl].codec[cidx]->rates[idx]; in get_rates()
574 int i, cidx, r, ok_flag; in snd_ac97_pcm_open() local
582 for (cidx = 0; cidx < 4; cidx++) in snd_ac97_pcm_open()
583 if (bus->codec[cidx] && (bus->codec[cidx]->ext_id & AC97_EI_SPDIF)) { in snd_ac97_pcm_open()
584 err = set_spdif_rate(bus->codec[cidx], rate); in snd_ac97_pcm_open()
594 for (cidx = 0; cidx < 4; cidx++) { in snd_ac97_pcm_open()
595 if (bus->used_slots[pcm->stream][cidx] & (1 << i)) { in snd_ac97_pcm_open()
600 if (pcm->r[r].rslots[cidx] & (1 << i)) { in snd_ac97_pcm_open()
601 bus->used_slots[pcm->stream][cidx] |= (1 << i); in snd_ac97_pcm_open()
617 for (cidx = 0; cidx < 4; cidx++) { in snd_ac97_pcm_open()
618 if (pcm->r[r].rslots[cidx] & (1 << i)) { in snd_ac97_pcm_open()
619 reg = get_slot_reg(pcm, cidx, i, r); in snd_ac97_pcm_open()
624 if (reg_ok[cidx] & (1 << (reg - AC97_PCM_FRONT_DAC_RATE))) in snd_ac97_pcm_open()
627 err = snd_ac97_set_rate(pcm->r[r].codec[cidx], reg, rate); in snd_ac97_pcm_open()
629 …snd_printk(KERN_ERR "error in snd_ac97_set_rate: cidx=%d, reg=0x%x, rate=%d, err=%d\n", cidx, reg,… in snd_ac97_pcm_open()
631 reg_ok[cidx] |= (1 << (reg - AC97_PCM_FRONT_DAC_RATE)); in snd_ac97_pcm_open()
658 int i, cidx; in snd_ac97_pcm_close() local
665 for (cidx = 0; cidx < 4; cidx++) { in snd_ac97_pcm_close()
666 if (pcm->r[r].rslots[cidx] & (1 << i)) { in snd_ac97_pcm_close()
667 int reg = get_slot_reg(pcm, cidx, i, r); in snd_ac97_pcm_close()
668 snd_ac97_update_power(pcm->r[r].codec[cidx], in snd_ac97_pcm_close()
680 for (cidx = 0; cidx < 4; cidx++) in snd_ac97_pcm_close()
681 bus->used_slots[pcm->stream][cidx] &= ~(1 << i); in snd_ac97_pcm_close()