Lines Matching refs:codec
117 #define snd_hda_codec_amp_read(codec, nid, ch, dir, idx) \ argument
118 snd_hdac_regmap_get_amp(&(codec)->core, nid, ch, dir, idx)
119 int snd_hda_codec_amp_update(struct hda_codec *codec, hda_nid_t nid,
121 int snd_hda_codec_amp_stereo(struct hda_codec *codec, hda_nid_t nid,
123 int snd_hda_codec_amp_init(struct hda_codec *codec, hda_nid_t nid, int ch,
125 int snd_hda_codec_amp_init_stereo(struct hda_codec *codec, hda_nid_t nid,
127 void snd_hda_set_vmaster_tlv(struct hda_codec *codec, hda_nid_t nid, int dir,
129 struct snd_kcontrol *snd_hda_find_mixer_ctl(struct hda_codec *codec,
131 int __snd_hda_add_vmaster(struct hda_codec *codec, char *name,
135 #define snd_hda_add_vmaster(codec, name, tlv, followers, suffix, access) \ argument
136 __snd_hda_add_vmaster(codec, name, tlv, followers, suffix, true, access, NULL)
137 int snd_hda_codec_reset(struct hda_codec *codec);
138 void snd_hda_codec_register(struct hda_codec *codec);
139 void snd_hda_codec_cleanup_for_unbind(struct hda_codec *codec);
140 void snd_hda_codec_disconnect_pcms(struct hda_codec *codec);
142 #define snd_hda_regmap_sync(codec) snd_hdac_regmap_sync(&(codec)->core) argument
151 struct hda_codec *codec; member
154 int snd_hda_add_vmaster_hook(struct hda_codec *codec,
166 int snd_hda_create_dig_out_ctls(struct hda_codec *codec,
169 #define snd_hda_create_spdif_out_ctls(codec, anid, cnid) \ argument
170 snd_hda_create_dig_out_ctls(codec, anid, cnid, HDA_PCM_TYPE_SPDIF)
171 int snd_hda_create_spdif_in_ctls(struct hda_codec *codec, hda_nid_t nid);
188 int snd_hda_input_mux_put(struct hda_codec *codec,
192 int snd_hda_add_imux_item(struct hda_codec *codec,
226 int snd_hda_create_spdif_share_sw(struct hda_codec *codec,
228 int snd_hda_multi_out_dig_open(struct hda_codec *codec,
230 int snd_hda_multi_out_dig_close(struct hda_codec *codec,
232 int snd_hda_multi_out_dig_prepare(struct hda_codec *codec,
237 int snd_hda_multi_out_dig_cleanup(struct hda_codec *codec,
239 int snd_hda_multi_out_analog_open(struct hda_codec *codec,
243 int snd_hda_multi_out_analog_prepare(struct hda_codec *codec,
248 int snd_hda_multi_out_analog_cleanup(struct hda_codec *codec,
255 int snd_hda_codec_proc_new(struct hda_codec *codec);
257 static inline int snd_hda_codec_proc_new(struct hda_codec *codec) { return 0; } in snd_hda_codec_proc_new() argument
266 int snd_hda_add_new_ctls(struct hda_codec *codec,
291 void (*func)(struct hda_codec *codec,
298 unsigned int codec; /* Codec vendor/device ID */ member
310 { .codec = _codec,\
319 { .codec = _codec,\
348 int snd_hda_add_verbs(struct hda_codec *codec, const struct hda_verb *list);
349 void snd_hda_apply_verbs(struct hda_codec *codec);
350 void snd_hda_apply_pincfgs(struct hda_codec *codec,
352 void snd_hda_apply_fixup(struct hda_codec *codec, int action);
353 void __snd_hda_apply_fixup(struct hda_codec *codec, int id, int action, int depth);
354 void snd_hda_pick_fixup(struct hda_codec *codec,
358 void snd_hda_pick_pin_fixup(struct hda_codec *codec,
394 unsigned int snd_hda_get_default_vref(struct hda_codec *codec, hda_nid_t pin);
395 unsigned int snd_hda_correct_pin_ctl(struct hda_codec *codec,
397 int _snd_hda_set_pin_ctl(struct hda_codec *codec, hda_nid_t pin,
416 snd_hda_set_pin_ctl(struct hda_codec *codec, hda_nid_t pin, unsigned int val) in snd_hda_set_pin_ctl() argument
418 return _snd_hda_set_pin_ctl(codec, pin, val, false); in snd_hda_set_pin_ctl()
430 snd_hda_set_pin_ctl_cache(struct hda_codec *codec, hda_nid_t pin, in snd_hda_set_pin_ctl_cache() argument
433 return _snd_hda_set_pin_ctl(codec, pin, val, true); in snd_hda_set_pin_ctl_cache()
436 int snd_hda_codec_get_pin_target(struct hda_codec *codec, hda_nid_t nid);
437 int snd_hda_codec_set_pin_target(struct hda_codec *codec, hda_nid_t nid,
440 #define for_each_hda_codec_node(nid, codec) \ argument
441 for ((nid) = (codec)->core.start_nid; (nid) < (codec)->core.end_nid; (nid)++)
447 static inline void snd_hda_codec_allow_unsol_events(struct hda_codec *codec) in snd_hda_codec_allow_unsol_events() argument
449 codec->core.dev.power.power_state = PMSG_ON; in snd_hda_codec_allow_unsol_events()
455 static inline u32 get_wcaps(struct hda_codec *codec, hda_nid_t nid) in get_wcaps() argument
457 if (nid < codec->core.start_nid || in get_wcaps()
458 nid >= codec->core.start_nid + codec->core.num_nodes) in get_wcaps()
460 return codec->wcaps[nid - codec->core.start_nid]; in get_wcaps()
481 static inline void snd_hda_override_wcaps(struct hda_codec *codec, in snd_hda_override_wcaps() argument
484 if (nid >= codec->core.start_nid && in snd_hda_override_wcaps()
485 nid < codec->core.start_nid + codec->core.num_nodes) in snd_hda_override_wcaps()
486 codec->wcaps[nid - codec->core.start_nid] = val; in snd_hda_override_wcaps()
489 u32 query_amp_caps(struct hda_codec *codec, hda_nid_t nid, int direction);
490 int snd_hda_override_amp_caps(struct hda_codec *codec, hda_nid_t nid, int dir,
504 snd_hda_query_pin_caps(struct hda_codec *codec, hda_nid_t nid) in snd_hda_query_pin_caps() argument
506 return snd_hda_param_read(codec, nid, AC_PAR_PIN_CAP); in snd_hda_query_pin_caps()
521 snd_hda_override_pin_caps(struct hda_codec *codec, hda_nid_t nid, in snd_hda_override_pin_caps() argument
524 return snd_hdac_override_parm(&codec->core, nid, AC_PAR_PIN_CAP, caps); in snd_hda_override_pin_caps()
527 bool snd_hda_check_amp_caps(struct hda_codec *codec, hda_nid_t nid,
530 #define nid_has_mute(codec, nid, dir) \ argument
531 snd_hda_check_amp_caps(codec, nid, dir, (AC_AMPCAP_MUTE | AC_AMPCAP_MIN_MUTE))
532 #define nid_has_volume(codec, nid, dir) \ argument
533 snd_hda_check_amp_caps(codec, nid, dir, AC_AMPCAP_NUM_STEPS)
546 int snd_hda_ctl_add(struct hda_codec *codec, hda_nid_t nid,
548 int snd_hda_add_nid(struct hda_codec *codec, struct snd_kcontrol *kctl,
550 void snd_hda_ctls_clear(struct hda_codec *codec);
556 int snd_hda_create_hwdep(struct hda_codec *codec);
558 static inline int snd_hda_create_hwdep(struct hda_codec *codec) { return 0; } in snd_hda_create_hwdep() argument
561 void snd_hda_sysfs_init(struct hda_codec *codec);
562 void snd_hda_sysfs_clear(struct hda_codec *codec);
567 const char *snd_hda_get_hint(struct hda_codec *codec, const char *key);
568 int snd_hda_get_bool_hint(struct hda_codec *codec, const char *key);
569 int snd_hda_get_int_hint(struct hda_codec *codec, const char *key, int *valp);
572 const char *snd_hda_get_hint(struct hda_codec *codec, const char *key) in snd_hda_get_hint() argument
578 int snd_hda_get_bool_hint(struct hda_codec *codec, const char *key) in snd_hda_get_bool_hint() argument
584 int snd_hda_get_int_hint(struct hda_codec *codec, const char *key, int *valp) in snd_hda_get_int_hint() argument
594 void snd_hda_schedule_power_save(struct hda_codec *codec);
607 int snd_hda_check_amp_list_power(struct hda_codec *codec,
613 snd_hda_check_power_state(struct hda_codec *codec, hda_nid_t nid, in snd_hda_check_power_state() argument
616 return snd_hdac_check_power_state(&codec->core, nid, target_state); in snd_hda_check_power_state()
619 static inline unsigned int snd_hda_sync_power_state(struct hda_codec *codec, in snd_hda_sync_power_state() argument
623 return snd_hdac_sync_power_state(&codec->core, nid, target_state); in snd_hda_sync_power_state()
625 unsigned int snd_hda_codec_eapd_power_filter(struct hda_codec *codec,
629 void snd_hda_codec_shutdown(struct hda_codec *codec);
702 int snd_hdmi_get_eld_size(struct hda_codec *codec, hda_nid_t nid);
703 int snd_hdmi_get_eld(struct hda_codec *codec, hda_nid_t nid,
705 int snd_hdmi_parse_eld(struct hda_codec *codec, struct parsed_hdmi_eld *e,
707 void snd_hdmi_show_eld(struct hda_codec *codec, struct parsed_hdmi_eld *e);
711 int snd_hdmi_get_eld_ati(struct hda_codec *codec, hda_nid_t nid,
725 void snd_hda_codec_display_power(struct hda_codec *codec, bool enable);
729 #define codec_err(codec, fmt, args...) \ argument
730 dev_err(hda_codec_dev(codec), fmt, ##args)
731 #define codec_warn(codec, fmt, args...) \ argument
732 dev_warn(hda_codec_dev(codec), fmt, ##args)
733 #define codec_info(codec, fmt, args...) \ argument
734 dev_info(hda_codec_dev(codec), fmt, ##args)
735 #define codec_dbg(codec, fmt, args...) \ argument
736 dev_dbg(hda_codec_dev(codec), fmt, ##args)