#include <linux/init.h>
#include <linux/slab.h>
#include <linux/module.h>
#include <sound/core.h>
#include <linux/pci.h>
#include <sound/tlv.h>
#include <sound/hda_codec.h>
#include "hda_local.h"
#include "hda_auto_parser.h"
#include "hda_jack.h"
#include "hda_generic.h"
struct cs_spec { … };
enum { … };
enum { … };
#define CS420X_VENDOR_NID …
#define CS_DIG_OUT1_PIN_NID …
#define CS_DIG_OUT2_PIN_NID …
#define CS_DMIC1_PIN_NID …
#define CS_DMIC2_PIN_NID …
#define IDX_SPDIF_STAT …
#define IDX_SPDIF_CTL …
#define IDX_ADC_CFG …
#define CS_COEF_ADC_SZC_MASK …
#define CS_COEF_ADC_MIC_SZC_MODE …
#define CS_COEF_ADC_LI_SZC_MODE …
#define CS_COEF_ADC_MIC_PGA_MODE …
#define CS_COEF_ADC_LI_PGA_MODE …
#define IDX_DAC_CFG …
#define CS_COEF_DAC_HP_SZC_MODE …
#define CS_COEF_DAC_LO_SZC_MODE …
#define CS_COEF_DAC_SPK_SZC_MODE …
#define IDX_BEEP_CFG …
#define CS4208_VENDOR_NID …
#define CS4210_DAC_NID …
#define CS4210_ADC_NID …
#define CS4210_VENDOR_NID …
#define CS421X_DMIC_PIN_NID …
#define CS421X_SPDIF_PIN_NID …
#define CS421X_IDX_DEV_CFG …
#define CS421X_IDX_ADC_CFG …
#define CS421X_IDX_DAC_CFG …
#define CS421X_IDX_SPK_CTL …
#define CS4213_VENDOR_NID …
static inline int cs_vendor_coef_get(struct hda_codec *codec, unsigned int idx)
{ … }
static inline void cs_vendor_coef_set(struct hda_codec *codec, unsigned int idx,
unsigned int coef)
{ … }
static void cs_automute(struct hda_codec *codec)
{ … }
static bool is_active_pin(struct hda_codec *codec, hda_nid_t nid)
{ … }
static void init_input_coef(struct hda_codec *codec)
{ … }
static const struct hda_verb cs_coef_init_verbs[] = …;
static const struct hda_verb cs4208_coef_init_verbs[] = …;
static const struct hda_verb cs_errata_init_verbs[] = …;
static void init_digital_coef(struct hda_codec *codec)
{ … }
static int cs_init(struct hda_codec *codec)
{ … }
static int cs_build_controls(struct hda_codec *codec)
{ … }
#define cs_free …
static const struct hda_codec_ops cs_patch_ops = …;
static int cs_parse_auto_config(struct hda_codec *codec)
{ … }
static const struct hda_model_fixup cs420x_models[] = …;
static const struct snd_pci_quirk cs420x_fixup_tbl[] = …;
static const struct hda_pintbl mbp53_pincfgs[] = …;
static const struct hda_pintbl mbp55_pincfgs[] = …;
static const struct hda_pintbl imac27_pincfgs[] = …;
static const struct hda_pintbl mbp101_pincfgs[] = …;
static const struct hda_pintbl mba42_pincfgs[] = …;
static const struct hda_pintbl mba6_pincfgs[] = …;
static void cs420x_fixup_gpio_13(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static void cs420x_fixup_gpio_23(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static const struct hda_fixup cs420x_fixups[] = …;
static struct cs_spec *cs_alloc_spec(struct hda_codec *codec, int vendor_nid)
{ … }
static int patch_cs420x(struct hda_codec *codec)
{ … }
enum { … };
static const struct hda_model_fixup cs4208_models[] = …;
static const struct snd_pci_quirk cs4208_fixup_tbl[] = …;
static const struct snd_pci_quirk cs4208_mac_fixup_tbl[] = …;
static void cs4208_fixup_gpio0(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static const struct hda_fixup cs4208_fixups[];
static void cs4208_fixup_mac(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static void cs4208_fixup_macmini(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static int cs4208_spdif_sw_put(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{ … }
static void cs4208_fixup_spdif_switch(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static const struct hda_fixup cs4208_fixups[] = …;
static void cs4208_fix_amp_caps(struct hda_codec *codec, hda_nid_t adc)
{ … }
static int patch_cs4208(struct hda_codec *codec)
{ … }
static const struct hda_model_fixup cs421x_models[] = …;
static const struct snd_pci_quirk cs421x_fixup_tbl[] = …;
static const struct hda_pintbl cdb4210_pincfgs[] = …;
static const struct hda_pintbl stumpy_pincfgs[] = …;
static void cs421x_fixup_sense_b(struct hda_codec *codec,
const struct hda_fixup *fix, int action)
{ … }
static const struct hda_fixup cs421x_fixups[] = …;
static const struct hda_verb cs421x_coef_init_verbs[] = …;
static const struct hda_verb cs421x_coef_init_verbs_A1_silicon_fixes[] = …;
static const DECLARE_TLV_DB_SCALE(cs421x_speaker_boost_db_scale, 900, 300, 0);
static int cs421x_boost_vol_info(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_info *uinfo)
{ … }
static int cs421x_boost_vol_get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{ … }
static int cs421x_boost_vol_put(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{ … }
static const struct snd_kcontrol_new cs421x_speaker_boost_ctl = …;
static void cs4210_pinmux_init(struct hda_codec *codec)
{ … }
static void cs4210_spdif_automute(struct hda_codec *codec,
struct hda_jack_callback *tbl)
{ … }
static void parse_cs421x_digital(struct hda_codec *codec)
{ … }
static int cs421x_init(struct hda_codec *codec)
{ … }
static void fix_volume_caps(struct hda_codec *codec, hda_nid_t dac)
{ … }
static int cs421x_parse_auto_config(struct hda_codec *codec)
{ … }
static int cs421x_suspend(struct hda_codec *codec)
{ … }
static const struct hda_codec_ops cs421x_patch_ops = …;
static int patch_cs4210(struct hda_codec *codec)
{ … }
static int patch_cs4213(struct hda_codec *codec)
{ … }
static const struct hda_device_id snd_hda_id_cirrus[] = …;
MODULE_DEVICE_TABLE(hdaudio, snd_hda_id_cirrus);
MODULE_LICENSE(…) …;
MODULE_DESCRIPTION(…) …;
static struct hda_codec_driver cirrus_driver = …;
module_hda_codec_driver(…) …;