Commit 8f0fdc09 authored by Takashi Iwai's avatar Takashi Iwai

Merge branch 'test/hda-gen-parser' into test/hda-migrate

* test/hda-gen-parser:
  ALSA: hda - Improve naming rule for primary output
  ALSA: hda - Add PCM capture hook to hda_gen_spec
  ALSA: hda - Record all detected ADCs in hda_gen_spec
  ALSA: hda - Move vmaster TLV parsing to snd_hda_gen_parse_auto_config()
  ALSA: hda - Add input jack mode enum controls to generic parser
  ALSA: hda - Give more comments to hda_gen_spec flags
  ALSA: hda - Add suppress_auto_mute flag to hda_gen_spec
  ALSA: hda - Record the current speaker / LO mute status in hda_gen_spec
  ALSA: hda - Properly call automute/switch hooks at init
parents f6655d52 247d85ee
This diff is collapsed.
......@@ -142,9 +142,11 @@ struct hda_gen_spec {
unsigned int dyn_adc_idx[HDA_MAX_NUM_INPUTS];
hda_nid_t shared_mic_vref_pin;
/* DAC list */
/* DAC/ADC lists */
int num_all_dacs;
hda_nid_t all_dacs[16];
int num_all_adcs;
hda_nid_t all_adcs[AUTO_CFG_MAX_OUTS];
/* path list */
struct snd_array paths;
......@@ -164,24 +166,34 @@ struct hda_gen_spec {
struct automic_entry am_entry[MAX_AUTO_MIC_PINS];
/* for pin sensing */
/* current status; set in hda_geneic.c */
unsigned int hp_jack_present:1;
unsigned int line_jack_present:1;
unsigned int master_mute:1;
unsigned int speaker_muted:1; /* current status of speaker mute */
unsigned int line_out_muted:1; /* current status of LO mute */
/* internal states of automute / autoswitch behavior */
unsigned int auto_mic:1;
unsigned int automute_speaker:1; /* automute speaker outputs */
unsigned int automute_lo:1; /* automute LO outputs */
/* capabilities detected by parser */
unsigned int detect_hp:1; /* Headphone detection enabled */
unsigned int detect_lo:1; /* Line-out detection enabled */
unsigned int automute_speaker_possible:1; /* there are speakers and either LO or HP */
unsigned int automute_lo_possible:1; /* there are line outs and HP */
/* additional parameters set by codec drivers */
unsigned int master_mute:1; /* master mute over all */
unsigned int keep_vref_in_automute:1; /* Don't clear VREF in automute */
unsigned int suppress_auto_mic:1; /* suppress input jack auto switch */
unsigned int line_in_auto_switch:1; /* allow line-in auto switch */
/* other flags */
/* parser behavior flags; set before snd_hda_gen_parse_auto_config() */
unsigned int suppress_auto_mute:1; /* suppress input jack auto mute */
unsigned int suppress_auto_mic:1; /* suppress input jack auto switch */
/* other parse behavior flags */
unsigned int need_dac_fix:1; /* need to limit DACs for multi channels */
unsigned int no_analog:1; /* digital I/O only */
unsigned int dyn_adc_switch:1; /* switch ADCs (for ALC275) */
unsigned int shared_mic_hp:1; /* HP/Mic-in sharing */
unsigned int no_primary_hp:1; /* Don't prefer HP pins to speaker pins */
unsigned int multi_cap_vol:1; /* allow multiple capture xxx volumes */
......@@ -189,16 +201,22 @@ struct hda_gen_spec {
unsigned int own_eapd_ctl:1; /* set EAPD by own function */
unsigned int vmaster_mute_enum:1; /* add vmaster mute mode enum */
unsigned int indep_hp:1; /* independent HP supported */
unsigned int indep_hp_enabled:1; /* independent HP enabled */
unsigned int prefer_hp_amp:1; /* enable HP amp for speaker if any */
unsigned int add_stereo_mix_input:1; /* add aamix as a capture src */
unsigned int add_out_jack_modes:1; /* add output jack mode enum ctls */
unsigned int add_in_jack_modes:1; /* add input jack mode enum ctls */
/* other internal flags */
unsigned int no_analog:1; /* digital I/O only */
unsigned int dyn_adc_switch:1; /* switch ADCs (for ALC275) */
unsigned int indep_hp_enabled:1; /* independent HP enabled */
/* loopback mixing mode */
bool aamix_mode;
/* for virtual master */
hda_nid_t vmaster_nid;
unsigned int vmaster_tlv[4];
struct hda_vmaster_mute_hook vmaster_mute;
#ifdef CONFIG_PM
struct hda_loopback_check loopback;
......@@ -215,11 +233,15 @@ struct hda_gen_spec {
void (*automute_hook)(struct hda_codec *codec);
void (*cap_sync_hook)(struct hda_codec *codec);
/* PCM playback hook */
/* PCM hooks */
void (*pcm_playback_hook)(struct hda_pcm_stream *hinfo,
struct hda_codec *codec,
struct snd_pcm_substream *substream,
int action);
void (*pcm_capture_hook)(struct hda_pcm_stream *hinfo,
struct hda_codec *codec,
struct snd_pcm_substream *substream,
int action);
/* automute / autoswitch hooks */
void (*hp_automute_hook)(struct hda_codec *codec,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment