H A D | hda_generic.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Universal Interface for Intel High Definition Audio Codec 32 * snd_hda_gen_spec_init - initialize hda_gen_spec struct 39 snd_array_init(&spec->kctls, sizeof(struct snd_kcontrol_new), 32); in snd_hda_gen_spec_init() 40 snd_array_init(&spec->paths, sizeof(struct nid_path), 8); in snd_hda_gen_spec_init() 41 snd_array_init(&spec->loopback_lis in snd_hda_gen_spec_init() 105 parse_user_hints(struct hda_codec * codec) parse_user_hints() argument 205 update_pin_ctl(codec,pin,val) global() argument 210 restore_pin_ctl(struct hda_codec * codec,hda_nid_t pin) restore_pin_ctl() argument 216 set_pin_target(struct hda_codec * codec,hda_nid_t pin,unsigned int val,bool do_write) set_pin_target() argument 228 set_pin_targets(struct hda_codec * codec,int num_pins,hda_nid_t * pins,unsigned int val) set_pin_targets() argument 256 get_nid_path(struct hda_codec * codec,hda_nid_t from_nid,hda_nid_t to_nid,int anchor_nid) get_nid_path() argument 287 snd_hda_get_path_idx(struct hda_codec * codec,struct nid_path * path) snd_hda_get_path_idx() argument 308 snd_hda_get_path_from_idx(struct hda_codec * codec,int idx) snd_hda_get_path_from_idx() argument 319 is_dac_already_used(struct hda_codec * codec,hda_nid_t nid) is_dac_already_used() argument 333 is_reachable_path(struct hda_codec * codec,hda_nid_t from_nid,hda_nid_t to_nid) is_reachable_path() argument 345 is_ctl_used(struct hda_codec * codec,unsigned int val,int type) is_ctl_used() argument 360 is_ctl_associated(struct hda_codec * codec,hda_nid_t nid,int dir,int idx,int type) is_ctl_associated() argument 367 print_nid_path(struct hda_codec * codec,const char * pfx,struct nid_path * path) print_nid_path() argument 384 __parse_nid_path(struct hda_codec * codec,hda_nid_t from_nid,hda_nid_t to_nid,int anchor_nid,struct nid_path * path,int depth) __parse_nid_path() argument 454 snd_hda_parse_nid_path(struct hda_codec * codec,hda_nid_t from_nid,hda_nid_t to_nid,int anchor_nid,struct nid_path * path) snd_hda_parse_nid_path() argument 477 snd_hda_add_new_path(struct hda_codec * codec,hda_nid_t from_nid,hda_nid_t to_nid,int anchor_nid) snd_hda_add_new_path() argument 504 invalidate_nid_path(struct hda_codec * codec,int idx) invalidate_nid_path() argument 513 get_preferred_dac(struct hda_codec * codec,hda_nid_t pin) get_preferred_dac() argument 527 look_for_dac(struct hda_codec * codec,hda_nid_t pin,bool is_digital) look_for_dac() argument 555 same_amp_caps(struct hda_codec * codec,hda_nid_t nid1,hda_nid_t nid2,int dir) same_amp_caps() argument 565 look_for_out_mute_nid(struct hda_codec * codec,struct nid_path * path) look_for_out_mute_nid() argument 581 look_for_out_vol_nid(struct hda_codec * codec,struct nid_path * path) look_for_out_vol_nid() argument 602 has_amp_in(struct hda_codec * codec,struct nid_path * path,int idx) has_amp_in() argument 616 has_amp_out(struct hda_codec * codec,struct nid_path * path,int idx) has_amp_out() argument 630 is_active_nid(struct hda_codec * codec,hda_nid_t nid,unsigned int dir,unsigned int idx) is_active_nid() argument 665 is_active_nid_for_any(codec,nid) global() argument 669 get_amp_val_to_activate(struct hda_codec * codec,hda_nid_t nid,int dir,unsigned int caps,bool enable) get_amp_val_to_activate() argument 687 is_stereo_amps(struct hda_codec * codec,hda_nid_t nid,int dir) is_stereo_amps() argument 704 init_amp(struct hda_codec * codec,hda_nid_t nid,int dir,int idx) init_amp() argument 716 update_amp(struct hda_codec * codec,hda_nid_t nid,int dir,int idx,unsigned int mask,unsigned int val) update_amp() argument 730 get_amp_mask_to_modify(struct hda_codec * codec,hda_nid_t nid,int dir,int idx,unsigned int caps) get_amp_mask_to_modify() argument 748 activate_amp(struct hda_codec * codec,hda_nid_t nid,int dir,int idx,int idx_to_check,bool enable) activate_amp() argument 764 check_and_activate_amp(struct hda_codec * codec,hda_nid_t nid,int dir,int idx,int idx_to_check,bool enable) check_and_activate_amp() argument 774 activate_amp_out(struct hda_codec * codec,struct nid_path * path,int i,bool enable) activate_amp_out() argument 782 activate_amp_in(struct hda_codec * codec,struct nid_path * path,int i,bool enable,bool add_aamix) activate_amp_in() argument 823 path_power_update(struct hda_codec * codec,struct nid_path * path,bool allow_powerdown) path_power_update() argument 862 sync_power_state_change(struct hda_codec * codec,hda_nid_t nid) sync_power_state_change() argument 879 snd_hda_activate_path(struct hda_codec * codec,struct nid_path * path,bool enable,bool add_aamix) snd_hda_activate_path() argument 907 path_power_down_sync(struct hda_codec * codec,struct nid_path * path) path_power_down_sync() argument 917 set_pin_eapd(struct hda_codec * codec,hda_nid_t pin,bool enable) set_pin_eapd() argument 933 resume_path_from_idx(struct hda_codec * codec,int path_idx) resume_path_from_idx() argument 1020 add_vol_ctl(struct hda_codec * codec,const char * pfx,int cidx,unsigned int chs,struct nid_path * path) add_vol_ctl() argument 1034 get_default_ch_nums(struct hda_codec * codec,struct nid_path * path,int type) get_default_ch_nums() argument 1046 add_stereo_vol(struct hda_codec * codec,const char * pfx,int cidx,struct nid_path * path) add_stereo_vol() argument 1056 add_sw_ctl(struct hda_codec * codec,const char * pfx,int cidx,unsigned int chs,struct nid_path * path) add_sw_ctl() argument 1079 add_stereo_sw(struct hda_codec * codec,const char * pfx,int cidx,struct nid_path * path) add_stereo_sw() argument 1090 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); sync_auto_mute_bits() local 1117 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); hda_gen_bind_mute_get() local 1133 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); hda_gen_bind_mute_put() local 1156 path_has_mixer(struct hda_codec * codec,int path_idx,int ctl_type) path_has_mixer() argument 1167 get_line_out_pfx(struct hda_codec * codec,int ch,int * index,int ctl_type) get_line_out_pfx() argument 1285 assign_out_path_ctls(struct hda_codec * codec,struct nid_path * path) assign_out_path_ctls() argument 1348 get_primary_out(struct hda_codec * codec,int idx) get_primary_out() argument 1362 try_dac(struct hda_codec * codec,hda_nid_t dac,hda_nid_t pin) try_dac() argument 1369 try_assign_dacs(struct hda_codec * codec,int num_outs,const hda_nid_t * pins,hda_nid_t * dacs,int * path_idx,const struct badness_table * bad) try_assign_dacs() argument 1461 get_dac_if_single(struct hda_codec * codec,hda_nid_t pin) get_dac_if_single() argument 1481 can_be_multiio_pin(struct hda_codec * codec,unsigned int location,hda_nid_t nid) can_be_multiio_pin() argument 1498 count_multiio_pins(struct hda_codec * codec,hda_nid_t reference_pin) count_multiio_pins() argument 1527 fill_multi_ios(struct hda_codec * codec,hda_nid_t reference_pin,bool hardwired) fill_multi_ios() argument 1613 map_singles(struct hda_codec * codec,int outs,const hda_nid_t * pins,hda_nid_t * dacs,int * path_idx) map_singles() argument 1649 check_aamix_out_path(struct hda_codec * codec,int path_idx) check_aamix_out_path() argument 1685 indep_hp_possible(struct hda_codec * codec) indep_hp_possible() argument 1724 refill_shared_dacs(struct hda_codec * codec,int num_outs,hda_nid_t * dacs,int * path_idx) refill_shared_dacs() argument 1741 fill_and_eval_dacs(struct hda_codec * codec,bool fill_hardwired,bool fill_mio_first) fill_and_eval_dacs() argument 1904 print_nid_path_idx(struct hda_codec * codec,const char * pfx,int idx) print_nid_path_idx() argument 1914 debug_show_configs(struct hda_codec * codec,struct auto_pin_cfg * cfg) debug_show_configs() argument 1963 debug_show_configs(codec,cfg) global() argument 1967 fill_all_dac_nids(struct hda_codec * codec) fill_all_dac_nids() argument 1985 parse_output_paths(struct hda_codec * codec) parse_output_paths() argument 2106 create_multi_out_ctls(struct hda_codec * codec,const struct auto_pin_cfg * cfg) create_multi_out_ctls() argument 2157 create_extra_out(struct hda_codec * codec,int path_idx,const char * pfx,int cidx) create_extra_out() argument 2176 create_extra_outs(struct hda_codec * codec,int num_pins,const int * paths,const char * pfx) create_extra_outs() argument 2203 create_hp_out_ctls(struct hda_codec * codec) create_hp_out_ctls() argument 2211 create_speaker_out_ctls(struct hda_codec * codec) create_speaker_out_ctls() argument 2234 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); indep_hp_get() local 2247 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); indep_hp_put() local 2302 create_indep_hp_ctls(struct hda_codec * codec) create_indep_hp_ctls() argument 2332 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); ch_mode_info() local 2349 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); ch_mode_get() local 2357 get_multiio_path(struct hda_codec * codec,int idx) get_multiio_path() argument 2374 set_multi_io(struct hda_codec * codec,int idx,bool output) set_multi_io() argument 2407 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); ch_mode_put() local 2434 create_multi_channel_mode(struct hda_codec * codec) create_multi_channel_mode() argument 2454 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); loopback_mixing_get() local 2460 update_aamix_paths(struct hda_codec * codec,bool do_mix,int nomix_path_idx,int mix_path_idx,int out_type) update_aamix_paths() argument 2491 update_output_paths(struct hda_codec * codec,int num_outs,const int * paths) update_output_paths() argument 2509 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); loopback_mixing_put() local 2546 create_loopback_mixing_ctl(struct hda_codec * codec) create_loopback_mixing_ctl() argument 2565 update_hp_mic(struct hda_codec * codec,int adc_mux,bool force) update_hp_mic() argument 2609 create_hp_mic(struct hda_codec * codec) create_hp_mic() argument 2677 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); out_jack_mode_get() local 2689 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); out_jack_mode_put() local 2707 find_kctl_name(struct hda_codec * codec,const char * name,int idx) find_kctl_name() argument 2720 get_jack_mode_name(struct hda_codec * codec,hda_nid_t pin,char * name,size_t name_len) get_jack_mode_name() argument 2733 get_out_jack_num_items(struct hda_codec * codec,hda_nid_t pin) get_out_jack_num_items() argument 2744 create_out_jack_modes(struct hda_codec * codec,int num_pins,hda_nid_t * pins) create_out_jack_modes() argument 2781 get_vref_caps(struct hda_codec * codec,hda_nid_t pin) get_vref_caps() argument 2824 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); in_jack_mode_info() local 2839 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); in_jack_mode_get() local 2852 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); in_jack_mode_put() local 2875 get_in_jack_num_items(struct hda_codec * codec,hda_nid_t pin) get_in_jack_num_items() argument 2884 create_in_jack_mode(struct hda_codec * codec,hda_nid_t pin) create_in_jack_mode() argument 2917 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); hp_mic_jack_mode_info() local 2948 get_cur_hp_mic_jack_mode(struct hda_codec * codec,hda_nid_t nid) get_cur_hp_mic_jack_mode() argument 2972 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); hp_mic_jack_mode_get() local 2982 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); hp_mic_jack_mode_put() local 3021 create_hp_mic_jack_mode(struct hda_codec * codec,hda_nid_t pin) create_hp_mic_jack_mode() argument 3057 look_for_mix_leaf_ctls(struct hda_codec * codec,hda_nid_t mix_nid,hda_nid_t pin,unsigned int * mix_val,unsigned int * mute_val) look_for_mix_leaf_ctls() argument 3093 new_analog_input(struct hda_codec * codec,int input_idx,hda_nid_t pin,const char * ctlname,int ctlidx,hda_nid_t mix_nid) new_analog_input() argument 3149 is_input_pin(struct hda_codec * codec,hda_nid_t nid) is_input_pin() argument 3156 fill_adc_nids(struct hda_codec * codec) fill_adc_nids() argument 3186 check_dyn_adc_switch(struct hda_codec * codec) check_dyn_adc_switch() argument 3254 parse_capture_source(struct hda_codec * codec,hda_nid_t pin,int cfg_idx,int num_adcs,const char * label,int anchor) parse_capture_source() argument 3296 fill_input_pin_labels(struct hda_codec * codec) fill_input_pin_labels() argument 3329 create_input_ctls(struct hda_codec * codec) create_input_ctls() argument 3402 get_input_path(struct hda_codec * codec,int adc_idx,int imux_idx) get_input_path() argument 3424 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); mux_enum_info() local 3432 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); mux_enum_get() local 3444 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); mux_enum_put() local 3470 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); cap_put_caller() local 3544 parse_capvol_in_path(struct hda_codec * codec,struct nid_path * path) parse_capvol_in_path() argument 3583 is_inv_dmic_pin(struct hda_codec * codec,hda_nid_t nid) is_inv_dmic_pin() argument 3607 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); cap_single_sw_put() local 3621 add_single_cap_ctl(struct hda_codec * codec,const char * label,int idx,bool is_switch,unsigned int ctl,bool inv_dmic) add_single_cap_ctl() argument 3673 create_single_cap_vol_ctl(struct hda_codec * codec,int idx,unsigned int vol_ctl,unsigned int sw_ctl,bool inv_dmic) create_single_cap_vol_ctl() argument 3688 create_bind_cap_vol_ctl(struct hda_codec * codec,int idx,unsigned int vol_ctl,unsigned int sw_ctl) create_bind_cap_vol_ctl() argument 3716 get_first_cap_ctl(struct hda_codec * codec,int idx,int type) get_first_cap_ctl() argument 3737 create_multi_cap_vol_ctl(struct hda_codec * codec) create_multi_cap_vol_ctl() argument 3766 create_capture_mixers(struct hda_codec * codec) create_capture_mixers() argument 3839 check_boost_vol(struct hda_codec * codec,hda_nid_t nid,int dir,int idx) check_boost_vol() argument 3857 look_for_boost_amp(struct hda_codec * codec,struct nid_path * path) look_for_boost_amp() argument 3882 parse_mic_boost(struct hda_codec * codec) parse_mic_boost() argument 3931 create_mute_led_cdev(struct hda_codec * codec,int (* callback)(struct led_classdev *,enum led_brightness),bool micmute) create_mute_led_cdev() argument 3963 snd_hda_gen_add_mute_led_cdev(struct hda_codec * codec,int (* callback)(struct led_classdev *,enum led_brightness)) snd_hda_gen_add_mute_led_cdev() argument 4000 snd_hda_gen_add_micmute_led_cdev(struct hda_codec * codec,int (* callback)(struct led_classdev *,enum led_brightness)) snd_hda_gen_add_micmute_led_cdev() argument 4024 parse_digital(struct hda_codec * codec) parse_digital() argument 4088 mux_select(struct hda_codec * codec,unsigned int adc_idx,unsigned int idx) mux_select() argument 4135 set_path_power(struct hda_codec * codec,hda_nid_t nid,int pin_state,int stream_state) set_path_power() argument 4167 detect_pin_state(struct hda_codec * codec,hda_nid_t pin) detect_pin_state() argument 4180 set_pin_power_jack(struct hda_codec * codec,hda_nid_t pin,int power) set_pin_power_jack() argument 4195 pin_power_callback(struct hda_codec * codec,struct hda_jack_callback * jack,bool on) pin_power_callback() argument 4205 pin_power_up_callback(struct hda_codec * codec,struct hda_jack_callback * jack) pin_power_up_callback() argument 4212 pin_power_down_callback(struct hda_codec * codec,struct hda_jack_callback * jack) pin_power_down_callback() argument 4219 add_pin_power_ctls(struct hda_codec * codec,int num_pins,const hda_nid_t * pins,bool on) add_pin_power_ctls() argument 4237 add_all_pin_power_ctls(struct hda_codec * codec,bool on) add_all_pin_power_ctls() argument 4255 sync_pin_power_ctls(struct hda_codec * codec,int num_pins,const hda_nid_t * pins) sync_pin_power_ctls() argument 4266 sync_all_pin_power_ctls(struct hda_codec * codec) sync_all_pin_power_ctls() argument 4284 add_fake_paths(struct hda_codec * codec,hda_nid_t nid,int num_pins,const hda_nid_t * pins) add_fake_paths() argument 4309 add_fake_beep_paths(struct hda_codec * codec) add_fake_beep_paths() argument 4346 snd_hda_gen_fix_pin_power(struct hda_codec * codec,hda_nid_t pin) snd_hda_gen_fix_pin_power() argument 4369 detect_jacks(struct hda_codec * codec,int num_pins,const hda_nid_t * pins) detect_jacks() argument 4388 do_automute(struct hda_codec * codec,int num_pins,const hda_nid_t * pins,int * paths,bool mute) do_automute() argument 4453 snd_hda_gen_update_outputs(struct hda_codec * codec) snd_hda_gen_update_outputs() argument 4500 call_update_outputs(struct hda_codec * codec) call_update_outputs() argument 4518 snd_hda_gen_hp_automute(struct hda_codec * codec,struct hda_jack_callback * jack) snd_hda_gen_hp_automute() argument 4543 snd_hda_gen_line_automute(struct hda_codec * codec,struct hda_jack_callback * jack) snd_hda_gen_line_automute() argument 4568 snd_hda_gen_mic_autoswitch(struct hda_codec * codec,struct hda_jack_callback * jack) snd_hda_gen_mic_autoswitch() argument 4592 call_hp_automute(struct hda_codec * codec,struct hda_jack_callback * jack) call_hp_automute() argument 4602 call_line_automute(struct hda_codec * codec,struct hda_jack_callback * jack) call_line_automute() argument 4612 call_mic_autoswitch(struct hda_codec * codec,struct hda_jack_callback * jack) call_mic_autoswitch() argument 4623 update_automute_all(struct hda_codec * codec) update_automute_all() argument 4636 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); automute_mode_info() local 4650 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); automute_mode_get() local 4665 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); automute_mode_put() local 4711 add_automute_mode_enum(struct hda_codec * codec) add_automute_mode_enum() argument 4724 check_auto_mute_availability(struct hda_codec * codec) check_auto_mute_availability() argument 4797 auto_mic_check_imux(struct hda_codec * codec) auto_mic_check_imux() argument 4831 check_auto_mic_availability(struct hda_codec * codec) check_auto_mic_availability() argument 4906 snd_hda_gen_path_power_filter(struct hda_codec * codec,hda_nid_t nid,unsigned int power_state) snd_hda_gen_path_power_filter() argument 4925 mute_all_mixer_nid(struct hda_codec * codec,hda_nid_t mix) mute_all_mixer_nid() argument 4951 snd_hda_gen_stream_pm(struct hda_codec * codec,hda_nid_t nid,bool on) snd_hda_gen_stream_pm() argument 4959 force_mute_output_path(struct hda_codec * codec,hda_nid_t nid) force_mute_output_path() argument 4988 snd_hda_gen_shutup_speakers(struct hda_codec * codec) snd_hda_gen_shutup_speakers() argument 5030 snd_hda_gen_parse_auto_config(struct hda_codec * codec,struct auto_pin_cfg * cfg) snd_hda_gen_parse_auto_config() argument 5235 snd_hda_gen_build_controls(struct hda_codec * codec) snd_hda_gen_build_controls() argument 5308 call_pcm_playback_hook(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream,int action) call_pcm_playback_hook() argument 5318 call_pcm_capture_hook(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream,int action) call_pcm_capture_hook() argument 5331 playback_pcm_open(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) playback_pcm_open() argument 5351 playback_pcm_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) playback_pcm_prepare() argument 5368 playback_pcm_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) playback_pcm_cleanup() argument 5382 playback_pcm_close(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) playback_pcm_close() argument 5395 capture_pcm_open(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) capture_pcm_open() argument 5403 capture_pcm_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) capture_pcm_prepare() argument 5415 capture_pcm_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) capture_pcm_cleanup() argument 5425 capture_pcm_close(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) capture_pcm_close() argument 5433 alt_playback_pcm_open(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) alt_playback_pcm_open() argument 5451 alt_playback_pcm_close(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) alt_playback_pcm_close() argument 5464 alt_playback_pcm_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) alt_playback_pcm_prepare() argument 5476 alt_playback_pcm_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) alt_playback_pcm_cleanup() argument 5489 dig_playback_pcm_open(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) dig_playback_pcm_open() argument 5497 dig_playback_pcm_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) dig_playback_pcm_prepare() argument 5508 dig_playback_pcm_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) dig_playback_pcm_cleanup() argument 5516 dig_playback_pcm_close(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) dig_playback_pcm_close() argument 5530 alt_capture_pcm_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) alt_capture_pcm_prepare() argument 5545 alt_capture_pcm_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) alt_capture_pcm_cleanup() argument 5641 dyn_adc_pcm_resetup(struct hda_codec * codec,int cur) dyn_adc_pcm_resetup() argument 5660 dyn_adc_capture_pcm_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) dyn_adc_capture_pcm_prepare() argument 5675 dyn_adc_capture_pcm_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) dyn_adc_capture_pcm_cleanup() argument 5748 snd_hda_gen_build_pcms(struct hda_codec * codec) snd_hda_gen_build_pcms() argument 5862 set_output_and_unmute(struct hda_codec * codec,int path_idx) set_output_and_unmute() argument 5878 init_multi_out(struct hda_codec * codec) init_multi_out() argument 5888 __init_extra_out(struct hda_codec * codec,int num_outs,int * paths) __init_extra_out() argument 5897 init_extra_out(struct hda_codec * codec) init_extra_out() argument 5909 init_multi_io(struct hda_codec * codec) init_multi_io() argument 5928 init_aamix_paths(struct hda_codec * codec) init_aamix_paths() argument 5948 init_analog_input(struct hda_codec * codec) init_analog_input() argument 5968 init_input_src(struct hda_codec * codec) init_input_src() argument 5999 init_digital(struct hda_codec * codec) init_digital() argument 6017 clear_unsol_on_unused_pins(struct hda_codec * codec) clear_unsol_on_unused_pins() argument 6037 snd_hda_gen_init(struct hda_codec * codec) snd_hda_gen_init() argument 6078 snd_hda_gen_free(struct hda_codec * codec) snd_hda_gen_free() argument 6094 snd_hda_gen_check_power_status(struct hda_codec * codec,hda_nid_t nid) snd_hda_gen_check_power_status() argument 6119 snd_hda_parse_generic_codec(struct hda_codec * codec) snd_hda_parse_generic_codec() argument [all...] |
H A D | hda_codec.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Universal Interface for Intel High Definition Audio Codec 27 #define codec_in_pm(codec) snd_hdac_is_in_pm(&codec->core) argument 28 #define hda_codec_is_power_on(codec) snd_hdac_is_power_o argument 29 codec_has_epss(codec) global() argument 31 codec_has_clkstop(codec) global() argument 40 struct hda_codec *codec = container_of(dev, struct hda_codec, core); codec_exec_verb() local 79 snd_hda_sequence_write(struct hda_codec * codec,const struct hda_verb * seq) snd_hda_sequence_write() argument 96 lookup_conn_list(struct hda_codec * codec,hda_nid_t nid) lookup_conn_list() argument 106 add_conn_list(struct hda_codec * codec,hda_nid_t nid,int len,const hda_nid_t * list) add_conn_list() argument 121 remove_conn_list(struct hda_codec * codec) remove_conn_list() argument 132 read_and_add_raw_conns(struct hda_codec * codec,hda_nid_t nid) read_and_add_raw_conns() argument 168 snd_hda_get_conn_list(struct hda_codec * codec,hda_nid_t nid,const hda_nid_t ** listp) snd_hda_get_conn_list() argument 207 snd_hda_get_connections(struct hda_codec * codec,hda_nid_t nid,hda_nid_t * conn_list,int max_conns) snd_hda_get_connections() argument 238 snd_hda_override_conn_list(struct hda_codec * codec,hda_nid_t nid,int len,const hda_nid_t * list) snd_hda_override_conn_list() argument 264 snd_hda_get_conn_index(struct hda_codec * codec,hda_nid_t mux,hda_nid_t nid,int recursive) snd_hda_get_conn_index() argument 300 snd_hda_get_num_devices(struct hda_codec * codec,hda_nid_t nid) snd_hda_get_num_devices() argument 326 snd_hda_get_devices(struct hda_codec * codec,hda_nid_t nid,u8 * dev_list,int max_devices) snd_hda_get_devices() argument 365 snd_hda_get_dev_select(struct hda_codec * codec,hda_nid_t nid) snd_hda_get_dev_select() argument 383 snd_hda_set_dev_select(struct hda_codec * codec,hda_nid_t nid,int dev_id) snd_hda_set_dev_select() argument 416 read_widget_caps(struct hda_codec * codec,hda_nid_t fg_node) read_widget_caps() argument 432 read_pin_defaults(struct hda_codec * codec) read_pin_defaults() argument 460 look_up_pincfg(struct hda_codec * codec,struct snd_array * array,hda_nid_t nid) look_up_pincfg() argument 477 snd_hda_add_pincfg(struct hda_codec * codec,struct snd_array * list,hda_nid_t nid,unsigned int cfg) snd_hda_add_pincfg() argument 512 snd_hda_codec_set_pincfg(struct hda_codec * codec,hda_nid_t nid,unsigned int cfg) snd_hda_codec_set_pincfg() argument 528 snd_hda_codec_get_pincfg(struct hda_codec * codec,hda_nid_t nid) snd_hda_codec_get_pincfg() argument 564 snd_hda_codec_set_pin_target(struct hda_codec * codec,hda_nid_t nid,unsigned int val) snd_hda_codec_set_pin_target() argument 582 snd_hda_codec_get_pin_target(struct hda_codec * codec,hda_nid_t nid) snd_hda_codec_get_pin_target() argument 600 snd_hda_shutup_pins(struct hda_codec * codec) snd_hda_shutup_pins() argument 620 restore_shutup_pins(struct hda_codec * codec) restore_shutup_pins() argument 639 struct hda_codec *codec = hda_jackpoll_work() local 663 free_init_pincfgs(struct hda_codec * codec) free_init_pincfgs() argument 686 get_hda_cvt_setup(struct hda_codec * codec,hda_nid_t nid) get_hda_cvt_setup() argument 711 snd_hda_codec_pcm_new(struct hda_codec * codec,const char * fmt,...) snd_hda_codec_pcm_new() argument 739 snd_hda_codec_disconnect_pcms(struct hda_codec * codec) snd_hda_codec_disconnect_pcms() argument 753 codec_release_pcms(struct hda_codec * codec) codec_release_pcms() argument 771 snd_hda_codec_cleanup_for_unbind(struct hda_codec * codec) snd_hda_codec_cleanup_for_unbind() argument 811 snd_hda_codec_display_power(struct hda_codec * codec,bool enable) snd_hda_codec_display_power() argument 823 snd_hda_codec_register(struct hda_codec * codec) snd_hda_codec_register() argument 847 snd_hda_codec_unregister(struct hda_codec * codec) snd_hda_codec_unregister() argument 876 struct hda_codec *codec = dev_to_hda_codec(dev); snd_hda_codec_dev_release() local 902 struct hda_codec *codec; snd_hda_codec_device_init() local 962 struct hda_codec *codec; snd_hda_codec_new() local 980 snd_hda_codec_device_new(struct hda_bus * bus,struct snd_card * card,unsigned int codec_addr,struct hda_codec * codec,bool snddev_managed) snd_hda_codec_device_new() argument 1059 snd_hda_codec_update_widgets(struct hda_codec * codec) snd_hda_codec_update_widgets() argument 1085 update_pcm_stream_id(struct hda_codec * codec,struct hda_cvt_setup * p,hda_nid_t nid,u32 stream_tag,int channel_id) update_pcm_stream_id() argument 1104 update_pcm_format(struct hda_codec * codec,struct hda_cvt_setup * p,hda_nid_t nid,int format) update_pcm_format() argument 1130 snd_hda_codec_setup_stream(struct hda_codec * codec,hda_nid_t nid,u32 stream_tag,int channel_id,int format) snd_hda_codec_setup_stream() argument 1181 __snd_hda_codec_cleanup_stream(struct hda_codec * codec,hda_nid_t nid,int do_now) __snd_hda_codec_cleanup_stream() argument 1207 really_cleanup_stream(struct hda_codec * codec,struct hda_cvt_setup * q) really_cleanup_stream() argument 1223 purify_inactive_streams(struct hda_codec * codec) purify_inactive_streams() argument 1238 hda_cleanup_all_streams(struct hda_codec * codec) hda_cleanup_all_streams() argument 1265 query_amp_caps(struct hda_codec * codec,hda_nid_t nid,int direction) query_amp_caps() argument 1284 snd_hda_check_amp_caps(struct hda_codec * codec,hda_nid_t nid,int dir,unsigned int bits) snd_hda_check_amp_caps() argument 1309 snd_hda_override_amp_caps(struct hda_codec * codec,hda_nid_t nid,int dir,unsigned int caps) snd_hda_override_amp_caps() argument 1321 encode_amp(struct hda_codec * codec,hda_nid_t nid,int ch,int dir,int idx) encode_amp() argument 1345 snd_hda_codec_amp_update(struct hda_codec * codec,hda_nid_t nid,int ch,int dir,int idx,int mask,int val) snd_hda_codec_amp_update() argument 1366 snd_hda_codec_amp_stereo(struct hda_codec * codec,hda_nid_t nid,int direction,int idx,int mask,int val) snd_hda_codec_amp_stereo() argument 1394 snd_hda_codec_amp_init(struct hda_codec * codec,hda_nid_t nid,int ch,int dir,int idx,int mask,int val) snd_hda_codec_amp_init() argument 1416 snd_hda_codec_amp_init_stereo(struct hda_codec * codec,hda_nid_t nid,int dir,int idx,int mask,int val) snd_hda_codec_amp_init_stereo() argument 1430 get_amp_max_value(struct hda_codec * codec,hda_nid_t nid,int dir,unsigned int ofs) get_amp_max_value() argument 1452 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_mixer_amp_volume_info() local 1474 read_amp_value(struct hda_codec * codec,hda_nid_t nid,int ch,int dir,int idx,unsigned int ofs) read_amp_value() argument 1488 update_amp_value(struct hda_codec * codec,hda_nid_t nid,int ch,int dir,int idx,unsigned int ofs,unsigned int val) update_amp_value() argument 1515 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_mixer_amp_volume_get() local 1542 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_mixer_amp_volume_put() local 1572 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); get_ctl_amp_tlv() local 1628 snd_hda_set_vmaster_tlv(struct hda_codec * codec,hda_nid_t nid,int dir,unsigned int * tlv) snd_hda_set_vmaster_tlv() argument 1647 find_mixer_ctl(struct hda_codec * codec,const char * name,int dev,int idx) find_mixer_ctl() argument 1667 snd_hda_find_mixer_ctl(struct hda_codec * codec,const char * name) snd_hda_find_mixer_ctl() argument 1674 find_empty_mixer_ctl_idx(struct hda_codec * codec,const char * name,int start_idx) find_empty_mixer_ctl_idx() argument 1705 snd_hda_ctl_add(struct hda_codec * codec,hda_nid_t nid,struct snd_kcontrol * kctl) snd_hda_ctl_add() argument 1745 snd_hda_add_nid(struct hda_codec * codec,struct snd_kcontrol * kctl,unsigned int index,hda_nid_t nid) snd_hda_add_nid() argument 1769 snd_hda_ctls_clear(struct hda_codec * codec) snd_hda_ctls_clear() argument 1789 struct hda_codec *codec; snd_hda_lock_devices() local 1843 snd_hda_codec_reset(struct hda_codec * codec) snd_hda_codec_reset() argument 1861 map_followers(struct hda_codec * codec,const char * const * followers,const char * suffix,map_follower_func_t func,void * data) map_followers() argument 1892 check_follower_present(struct hda_codec * codec,void * data,struct snd_kcontrol * sctl) check_follower_present() argument 1913 struct hda_codec *codec; global() member 1972 add_follower(struct hda_codec * codec,void * data,struct snd_kcontrol * follower) add_follower() argument 1998 __snd_hda_add_vmaster(struct hda_codec * codec,char * name,unsigned int * tlv,const char * const * followers,const char * suffix,bool init_follower_vol,unsigned int access,struct snd_kcontrol ** ctl_ret) __snd_hda_add_vmaster() argument 2059 snd_hda_add_vmaster_hook(struct hda_codec * codec,struct hda_vmaster_mute_hook * hook) snd_hda_add_vmaster_hook() argument 2123 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_mixer_amp_switch_get() local 2151 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_mixer_amp_switch_put() local 2215 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_default_get() local 2286 set_dig_out(struct hda_codec * codec,hda_nid_t nid,int mask,int val) set_dig_out() argument 2301 set_dig_out_convert(struct hda_codec * codec,hda_nid_t nid,int dig1,int dig2) set_dig_out_convert() argument 2321 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_default_put() local 2352 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_out_switch_get() local 2365 set_spdif_ctls(struct hda_codec * codec,hda_nid_t nid,int dig1,int dig2) set_spdif_ctls() argument 2379 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_out_switch_put() local 2445 snd_hda_create_dig_out_ctls(struct hda_codec * codec,hda_nid_t associated_nid,hda_nid_t cvt_nid,int type) snd_hda_create_dig_out_ctls() argument 2514 snd_hda_spdif_out_of_nid(struct hda_codec * codec,hda_nid_t nid) snd_hda_spdif_out_of_nid() argument 2535 snd_hda_spdif_ctls_unassign(struct hda_codec * codec,int idx) snd_hda_spdif_ctls_unassign() argument 2556 snd_hda_spdif_ctls_assign(struct hda_codec * codec,int idx,hda_nid_t nid) snd_hda_spdif_ctls_assign() argument 2606 snd_hda_create_spdif_share_sw(struct hda_codec * codec,struct hda_multi_out * mout) snd_hda_create_spdif_share_sw() argument 2631 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_in_switch_get() local 2640 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_in_switch_put() local 2659 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); snd_hda_spdif_in_status_get() local 2702 snd_hda_create_spdif_in_ctls(struct hda_codec * codec,hda_nid_t nid) snd_hda_create_spdif_in_ctls() argument 2741 snd_hda_codec_set_power_to_all(struct hda_codec * codec,hda_nid_t fg,unsigned int power_state) snd_hda_codec_set_power_to_all() argument 2771 snd_hda_codec_eapd_power_filter(struct hda_codec * codec,hda_nid_t nid,unsigned int power_state) snd_hda_codec_eapd_power_filter() argument 2792 hda_set_power_state(struct hda_codec * codec,unsigned int power_state) hda_set_power_state() argument 2835 sync_power_up_states(struct hda_codec * codec) sync_power_up_states() argument 2859 hda_exec_init_verbs(struct hda_codec * codec) hda_exec_init_verbs() argument 2865 hda_exec_init_verbs(struct hda_codec * codec) hda_exec_init_verbs() argument 2869 update_power_acct(struct hda_codec * codec,bool on) update_power_acct() argument 2880 snd_hda_update_power_acct(struct hda_codec * codec) snd_hda_update_power_acct() argument 2889 hda_call_codec_suspend(struct hda_codec * codec) hda_call_codec_suspend() argument 2907 hda_call_codec_resume(struct hda_codec * codec) hda_call_codec_resume() argument 2937 struct hda_codec *codec = dev_to_hda_codec(dev); hda_codec_runtime_suspend() local 2962 struct hda_codec *codec = dev_to_hda_codec(dev); hda_codec_runtime_resume() local 2977 struct hda_codec *codec = dev_to_hda_codec(dev); hda_codec_pm_prepare() local 2986 struct hda_codec *codec = dev_to_hda_codec(dev); hda_codec_pm_complete() local 3011 struct hda_codec *codec = dev_to_hda_codec(dev); hda_codec_pm_freeze() local 3045 snd_hda_codec_shutdown(struct hda_codec * codec) snd_hda_codec_shutdown() argument 3064 add_std_chmaps(struct hda_codec * codec) add_std_chmaps() argument 3102 snd_hda_codec_build_controls(struct hda_codec * codec) snd_hda_codec_build_controls() argument 3132 hda_pcm_default_open_close(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) hda_pcm_default_open_close() argument 3139 hda_pcm_default_prepare(struct hda_pcm_stream * hinfo,struct hda_codec * codec,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) hda_pcm_default_prepare() argument 3149 hda_pcm_default_cleanup(struct hda_pcm_stream * hinfo,struct hda_codec * codec,struct snd_pcm_substream * substream) hda_pcm_default_cleanup() argument 3156 set_pcm_default_values(struct hda_codec * codec,struct hda_pcm_stream * info) set_pcm_default_values() argument 3202 snd_hda_codec_prepare(struct hda_codec * codec,struct hda_pcm_stream * hinfo,unsigned int stream,unsigned int format,struct snd_pcm_substream * substream) snd_hda_codec_prepare() argument 3230 snd_hda_codec_cleanup(struct hda_codec * codec,struct hda_pcm_stream * hinfo,struct snd_pcm_substream * substream) snd_hda_codec_cleanup() argument 3295 snd_hda_codec_parse_pcms(struct hda_codec * codec) snd_hda_codec_parse_pcms() argument 3336 snd_hda_codec_build_pcms(struct hda_codec * codec) snd_hda_codec_build_pcms() argument 3381 snd_hda_add_new_ctls(struct hda_codec * codec,const struct snd_kcontrol_new * knew) snd_hda_add_new_ctls() argument 3433 snd_hda_codec_set_power_save(struct hda_codec * codec,int delay) snd_hda_codec_set_power_save() argument 3482 snd_hda_check_amp_list_power(struct hda_codec * codec,struct hda_loopback_check * check,hda_nid_t nid) snd_hda_check_amp_list_power() argument 3554 snd_hda_input_mux_put(struct hda_codec * codec,const struct hda_input_mux * imux,struct snd_ctl_elem_value * ucontrol,hda_nid_t nid,unsigned int * cur_val) snd_hda_input_mux_put() argument 3609 setup_dig_out_stream(struct hda_codec * codec,hda_nid_t nid,unsigned int stream_tag,unsigned int format) setup_dig_out_stream() argument 3648 cleanup_dig_out_stream(struct hda_codec * codec,hda_nid_t nid) cleanup_dig_out_stream() argument 3663 snd_hda_multi_out_dig_open(struct hda_codec * codec,struct hda_multi_out * mout) snd_hda_multi_out_dig_open() argument 3684 snd_hda_multi_out_dig_prepare(struct hda_codec * codec,struct hda_multi_out * mout,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) snd_hda_multi_out_dig_prepare() argument 3702 snd_hda_multi_out_dig_cleanup(struct hda_codec * codec,struct hda_multi_out * mout) snd_hda_multi_out_dig_cleanup() argument 3717 snd_hda_multi_out_dig_close(struct hda_codec * codec,struct hda_multi_out * mout) snd_hda_multi_out_dig_close() argument 3738 snd_hda_multi_out_analog_open(struct hda_codec * codec,struct hda_multi_out * mout,struct snd_pcm_substream * substream,struct hda_pcm_stream * hinfo) snd_hda_multi_out_analog_open() argument 3793 snd_hda_multi_out_analog_prepare(struct hda_codec * codec,struct hda_multi_out * mout,unsigned int stream_tag,unsigned int format,struct snd_pcm_substream * substream) snd_hda_multi_out_analog_prepare() argument 3869 snd_hda_multi_out_analog_cleanup(struct hda_codec * codec,struct hda_multi_out * mout) snd_hda_multi_out_analog_cleanup() argument 3905 snd_hda_get_default_vref(struct hda_codec * codec,hda_nid_t pin) snd_hda_get_default_vref() argument 3932 snd_hda_correct_pin_ctl(struct hda_codec * codec,hda_nid_t pin,unsigned int val) snd_hda_correct_pin_ctl() argument 3995 _snd_hda_set_pin_ctl(struct hda_codec * codec,hda_nid_t pin,unsigned int val,bool cached) _snd_hda_set_pin_ctl() argument 4021 snd_hda_add_imux_item(struct hda_codec * codec,struct hda_input_mux * imux,const char * label,int index,int * type_idx) snd_hda_add_imux_item() argument 4055 struct hda_codec *codec; snd_hda_bus_reset_codecs() local [all...] |