Lines Matching refs:kcontrol
366 static int snd_akm4xxx_volume_info(struct snd_kcontrol *kcontrol, in snd_akm4xxx_volume_info() argument
369 unsigned int mask = AK_GET_MASK(kcontrol->private_value); in snd_akm4xxx_volume_info()
378 static int snd_akm4xxx_volume_get(struct snd_kcontrol *kcontrol, in snd_akm4xxx_volume_get() argument
381 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in snd_akm4xxx_volume_get()
382 int chip = AK_GET_CHIP(kcontrol->private_value); in snd_akm4xxx_volume_get()
383 int addr = AK_GET_ADDR(kcontrol->private_value); in snd_akm4xxx_volume_get()
389 static int put_ak_reg(struct snd_kcontrol *kcontrol, int addr, in put_ak_reg() argument
392 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in put_ak_reg()
393 unsigned int mask = AK_GET_MASK(kcontrol->private_value); in put_ak_reg()
394 int chip = AK_GET_CHIP(kcontrol->private_value); in put_ak_reg()
400 if (AK_GET_VOL_CVT(kcontrol->private_value) && nval < 128) in put_ak_reg()
402 if (AK_GET_IPGA(kcontrol->private_value) && nval >= 128) in put_ak_reg()
404 if (AK_GET_INVERT(kcontrol->private_value)) in put_ak_reg()
406 if (AK_GET_NEEDSMSB(kcontrol->private_value)) in put_ak_reg()
414 static int snd_akm4xxx_volume_put(struct snd_kcontrol *kcontrol, in snd_akm4xxx_volume_put() argument
417 unsigned int mask = AK_GET_MASK(kcontrol->private_value); in snd_akm4xxx_volume_put()
421 return put_ak_reg(kcontrol, AK_GET_ADDR(kcontrol->private_value), val); in snd_akm4xxx_volume_put()
424 static int snd_akm4xxx_stereo_volume_info(struct snd_kcontrol *kcontrol, in snd_akm4xxx_stereo_volume_info() argument
427 unsigned int mask = AK_GET_MASK(kcontrol->private_value); in snd_akm4xxx_stereo_volume_info()
436 static int snd_akm4xxx_stereo_volume_get(struct snd_kcontrol *kcontrol, in snd_akm4xxx_stereo_volume_get() argument
439 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in snd_akm4xxx_stereo_volume_get()
440 int chip = AK_GET_CHIP(kcontrol->private_value); in snd_akm4xxx_stereo_volume_get()
441 int addr = AK_GET_ADDR(kcontrol->private_value); in snd_akm4xxx_stereo_volume_get()
448 static int snd_akm4xxx_stereo_volume_put(struct snd_kcontrol *kcontrol, in snd_akm4xxx_stereo_volume_put() argument
451 int addr = AK_GET_ADDR(kcontrol->private_value); in snd_akm4xxx_stereo_volume_put()
452 unsigned int mask = AK_GET_MASK(kcontrol->private_value); in snd_akm4xxx_stereo_volume_put()
460 change = put_ak_reg(kcontrol, addr, val[0]); in snd_akm4xxx_stereo_volume_put()
461 change |= put_ak_reg(kcontrol, addr + 1, val[1]); in snd_akm4xxx_stereo_volume_put()
465 static int snd_akm4xxx_deemphasis_info(struct snd_kcontrol *kcontrol, in snd_akm4xxx_deemphasis_info() argument
474 static int snd_akm4xxx_deemphasis_get(struct snd_kcontrol *kcontrol, in snd_akm4xxx_deemphasis_get() argument
477 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in snd_akm4xxx_deemphasis_get()
478 int chip = AK_GET_CHIP(kcontrol->private_value); in snd_akm4xxx_deemphasis_get()
479 int addr = AK_GET_ADDR(kcontrol->private_value); in snd_akm4xxx_deemphasis_get()
480 int shift = AK_GET_SHIFT(kcontrol->private_value); in snd_akm4xxx_deemphasis_get()
486 static int snd_akm4xxx_deemphasis_put(struct snd_kcontrol *kcontrol, in snd_akm4xxx_deemphasis_put() argument
489 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in snd_akm4xxx_deemphasis_put()
490 int chip = AK_GET_CHIP(kcontrol->private_value); in snd_akm4xxx_deemphasis_put()
491 int addr = AK_GET_ADDR(kcontrol->private_value); in snd_akm4xxx_deemphasis_put()
492 int shift = AK_GET_SHIFT(kcontrol->private_value); in snd_akm4xxx_deemphasis_put()
506 static int ak4xxx_switch_get(struct snd_kcontrol *kcontrol, in ak4xxx_switch_get() argument
509 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in ak4xxx_switch_get()
510 int chip = AK_GET_CHIP(kcontrol->private_value); in ak4xxx_switch_get()
511 int addr = AK_GET_ADDR(kcontrol->private_value); in ak4xxx_switch_get()
512 int shift = AK_GET_SHIFT(kcontrol->private_value); in ak4xxx_switch_get()
513 int invert = AK_GET_INVERT(kcontrol->private_value); in ak4xxx_switch_get()
522 static int ak4xxx_switch_put(struct snd_kcontrol *kcontrol, in ak4xxx_switch_put() argument
525 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in ak4xxx_switch_put()
526 int chip = AK_GET_CHIP(kcontrol->private_value); in ak4xxx_switch_put()
527 int addr = AK_GET_ADDR(kcontrol->private_value); in ak4xxx_switch_put()
528 int shift = AK_GET_SHIFT(kcontrol->private_value); in ak4xxx_switch_put()
529 int invert = AK_GET_INVERT(kcontrol->private_value); in ak4xxx_switch_put()
561 static int ak4xxx_capture_source_info(struct snd_kcontrol *kcontrol, in ak4xxx_capture_source_info() argument
564 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in ak4xxx_capture_source_info()
565 int mixer_ch = AK_GET_SHIFT(kcontrol->private_value); in ak4xxx_capture_source_info()
575 static int ak4xxx_capture_source_get(struct snd_kcontrol *kcontrol, in ak4xxx_capture_source_get() argument
578 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in ak4xxx_capture_source_get()
579 int chip = AK_GET_CHIP(kcontrol->private_value); in ak4xxx_capture_source_get()
580 int addr = AK_GET_ADDR(kcontrol->private_value); in ak4xxx_capture_source_get()
581 int mask = AK_GET_MASK(kcontrol->private_value); in ak4xxx_capture_source_get()
589 static int ak4xxx_capture_source_put(struct snd_kcontrol *kcontrol, in ak4xxx_capture_source_put() argument
592 struct snd_akm4xxx *ak = snd_kcontrol_chip(kcontrol); in ak4xxx_capture_source_put()
593 int mixer_ch = AK_GET_SHIFT(kcontrol->private_value); in ak4xxx_capture_source_put()
594 int chip = AK_GET_CHIP(kcontrol->private_value); in ak4xxx_capture_source_put()
595 int addr = AK_GET_ADDR(kcontrol->private_value); in ak4xxx_capture_source_put()
596 int mask = AK_GET_MASK(kcontrol->private_value); in ak4xxx_capture_source_put()