Lines Matching +full:codec +full:- +full:2

1 // SPDX-License-Identifier: GPL-2.0-or-later
66 /* Vendor-specific processing widget */
79 * 1 = digital immediate, analog zero-cross
80 * 2 = digtail & analog soft-ramp
81 * 3 = digital soft-ramp, analog zero-cross
85 #define CS_COEF_ADC_LI_SZC_MODE (3 << 0) /* SZC setup for line-in */
86 /* PGA mode: 0 = differential, 1 = signle-ended */
88 #define CS_COEF_ADC_LI_PGA_MODE (1 << 6) /* PGA setup for line-in */
92 * 1 = zero-cross
93 * 2 = soft-ramp
94 * 3 = soft-ramp on zero-cross
97 #define CS_COEF_DAC_LO_SZC_MODE (3 << 2) /* nid 0x03 */
101 /* 0x0008 - test reg key */
102 /* 0x0009 - 0x0014 -> 12 test regs */
103 /* 0x0015 - visibility reg */
130 static inline int cs_vendor_coef_get(struct hda_codec *codec, unsigned int idx) in cs_vendor_coef_get() argument
132 struct cs_spec *spec = codec->spec; in cs_vendor_coef_get()
134 snd_hda_codec_write(codec, spec->vendor_nid, 0, in cs_vendor_coef_get()
136 return snd_hda_codec_read(codec, spec->vendor_nid, 0, in cs_vendor_coef_get()
140 static inline void cs_vendor_coef_set(struct hda_codec *codec, unsigned int idx, in cs_vendor_coef_set() argument
143 struct cs_spec *spec = codec->spec; in cs_vendor_coef_set()
145 snd_hda_codec_write(codec, spec->vendor_nid, 0, in cs_vendor_coef_set()
147 snd_hda_codec_write(codec, spec->vendor_nid, 0, in cs_vendor_coef_set()
152 * auto-mute and auto-mic switching
153 * CS421x auto-output redirecting
157 static void cs_automute(struct hda_codec *codec) in cs_automute() argument
159 struct cs_spec *spec = codec->spec; in cs_automute()
162 spec->gen.master_mute = !!(spec->spdif_present && spec->sense_b); in cs_automute()
164 snd_hda_gen_update_outputs(codec); in cs_automute()
166 if (spec->gpio_eapd_hp || spec->gpio_eapd_speaker) { in cs_automute()
167 if (spec->gen.automute_speaker) in cs_automute()
168 spec->gpio_data = spec->gen.hp_jack_present ? in cs_automute()
169 spec->gpio_eapd_hp : spec->gpio_eapd_speaker; in cs_automute()
171 spec->gpio_data = in cs_automute()
172 spec->gpio_eapd_hp | spec->gpio_eapd_speaker; in cs_automute()
173 snd_hda_codec_write(codec, 0x01, 0, in cs_automute()
174 AC_VERB_SET_GPIO_DATA, spec->gpio_data); in cs_automute()
178 static bool is_active_pin(struct hda_codec *codec, hda_nid_t nid) in is_active_pin() argument
182 val = snd_hda_codec_get_pincfg(codec, nid); in is_active_pin()
186 static void init_input_coef(struct hda_codec *codec) in init_input_coef() argument
188 struct cs_spec *spec = codec->spec; in init_input_coef()
192 if (spec->vendor_nid == CS420X_VENDOR_NID) { in init_input_coef()
193 coef = cs_vendor_coef_get(codec, IDX_BEEP_CFG); in init_input_coef()
194 if (is_active_pin(codec, CS_DMIC2_PIN_NID)) in init_input_coef()
195 coef |= 1 << 4; /* DMIC2 2 chan on, GPIO1 off */ in init_input_coef()
196 if (is_active_pin(codec, CS_DMIC1_PIN_NID)) in init_input_coef()
197 coef |= 1 << 3; /* DMIC1 2 chan on, GPIO0 off in init_input_coef()
202 cs_vendor_coef_set(codec, IDX_BEEP_CFG, coef); in init_input_coef()
210 (0x002a /* DAC1/2/3 SZCMode Soft Ramp */
215 /* ADC1/2 - Digital and Analog Soft Ramp */
220 {0x11, AC_VERB_SET_PROC_COEF, 0x0007}, /* Enable Beep thru DAC1/2/3 */
278 static void init_digital_coef(struct hda_codec *codec) in init_digital_coef() argument
282 coef = 0x0002; /* SRC_MUTE soft-mute on SPDIF (if no lock) */ in init_digital_coef()
284 if (is_active_pin(codec, CS_DIG_OUT2_PIN_NID)) in init_digital_coef()
289 cs_vendor_coef_set(codec, IDX_SPDIF_CTL, coef); in init_digital_coef()
292 static int cs_init(struct hda_codec *codec) in cs_init() argument
294 struct cs_spec *spec = codec->spec; in cs_init()
296 if (spec->vendor_nid == CS420X_VENDOR_NID) { in cs_init()
298 snd_hda_sequence_write(codec, cs_errata_init_verbs); in cs_init()
299 snd_hda_sequence_write(codec, cs_coef_init_verbs); in cs_init()
300 } else if (spec->vendor_nid == CS4208_VENDOR_NID) { in cs_init()
301 snd_hda_sequence_write(codec, cs4208_coef_init_verbs); in cs_init()
304 snd_hda_gen_init(codec); in cs_init()
306 if (spec->gpio_mask) { in cs_init()
307 snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_MASK, in cs_init()
308 spec->gpio_mask); in cs_init()
309 snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_DIRECTION, in cs_init()
310 spec->gpio_dir); in cs_init()
311 snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_DATA, in cs_init()
312 spec->gpio_data); in cs_init()
315 if (spec->vendor_nid == CS420X_VENDOR_NID) { in cs_init()
316 init_input_coef(codec); in cs_init()
317 init_digital_coef(codec); in cs_init()
323 static int cs_build_controls(struct hda_codec *codec) in cs_build_controls() argument
327 err = snd_hda_gen_build_controls(codec); in cs_build_controls()
330 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_BUILD); in cs_build_controls()
344 static int cs_parse_auto_config(struct hda_codec *codec) in cs_parse_auto_config() argument
346 struct cs_spec *spec = codec->spec; in cs_parse_auto_config()
350 err = snd_hda_parse_pin_defcfg(codec, &spec->gen.autocfg, NULL, 0); in cs_parse_auto_config()
354 err = snd_hda_gen_parse_auto_config(codec, &spec->gen.autocfg); in cs_parse_auto_config()
359 if (spec->gen.dyn_adc_switch) { in cs_parse_auto_config()
362 for (i = 0; i < spec->gen.input_mux.num_items; i++) { in cs_parse_auto_config()
363 int idx = spec->gen.dyn_adc_idx[i]; in cs_parse_auto_config()
367 snd_hda_gen_fix_pin_power(codec, in cs_parse_auto_config()
368 spec->gen.adc_nids[idx]); in cs_parse_auto_config()
390 SND_PCI_QUIRK(0x10de, 0x0d94, "MacBookAir 3,1(2)", CS420X_MBP55),
396 /* codec SSID */
400 SND_PCI_QUIRK(0x106b, 0x2000, "iMac 12,2", CS420X_IMAC27_122),
402 SND_PCI_QUIRK(0x106b, 0x5600, "MacBookAir 5,2", CS420X_MBP81),
403 SND_PCI_QUIRK(0x106b, 0x5b00, "MacBookAir 4,2", CS420X_MBA42),
494 static void cs420x_fixup_gpio_13(struct hda_codec *codec, in cs420x_fixup_gpio_13() argument
498 struct cs_spec *spec = codec->spec; in cs420x_fixup_gpio_13()
500 spec->gpio_eapd_hp = 2; /* GPIO1 = headphones */ in cs420x_fixup_gpio_13()
501 spec->gpio_eapd_speaker = 8; /* GPIO3 = speakers */ in cs420x_fixup_gpio_13()
502 spec->gpio_mask = spec->gpio_dir = in cs420x_fixup_gpio_13()
503 spec->gpio_eapd_hp | spec->gpio_eapd_speaker; in cs420x_fixup_gpio_13()
507 static void cs420x_fixup_gpio_23(struct hda_codec *codec, in cs420x_fixup_gpio_23() argument
511 struct cs_spec *spec = codec->spec; in cs420x_fixup_gpio_23()
513 spec->gpio_eapd_hp = 4; /* GPIO2 = headphones */ in cs420x_fixup_gpio_23()
514 spec->gpio_eapd_speaker = 8; /* GPIO3 = speakers */ in cs420x_fixup_gpio_23()
515 spec->gpio_mask = spec->gpio_dir = in cs420x_fixup_gpio_23()
516 spec->gpio_eapd_hp | spec->gpio_eapd_speaker; in cs420x_fixup_gpio_23()
572 static struct cs_spec *cs_alloc_spec(struct hda_codec *codec, int vendor_nid) in cs_alloc_spec() argument
579 codec->spec = spec; in cs_alloc_spec()
580 spec->vendor_nid = vendor_nid; in cs_alloc_spec()
581 codec->power_save_node = 1; in cs_alloc_spec()
582 snd_hda_gen_spec_init(&spec->gen); in cs_alloc_spec()
587 static int patch_cs420x(struct hda_codec *codec) in patch_cs420x() argument
592 spec = cs_alloc_spec(codec, CS420X_VENDOR_NID); in patch_cs420x()
594 return -ENOMEM; in patch_cs420x()
596 codec->patch_ops = cs_patch_ops; in patch_cs420x()
597 spec->gen.automute_hook = cs_automute; in patch_cs420x()
598 codec->single_adc_amp = 1; in patch_cs420x()
600 snd_hda_pick_fixup(codec, cs420x_models, cs420x_fixup_tbl, in patch_cs420x()
602 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PRE_PROBE); in patch_cs420x()
604 err = cs_parse_auto_config(codec); in patch_cs420x()
608 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PROBE); in patch_cs420x()
613 cs_free(codec); in patch_cs420x()
642 /* codec SSID matching */
644 SND_PCI_QUIRK(0x106b, 0x5e00, "MacBookPro 11,2", CS4208_MBP11),
647 SND_PCI_QUIRK(0x106b, 0x7200, "MacBookAir 6,2", CS4208_MBA6),
652 static void cs4208_fixup_gpio0(struct hda_codec *codec, in cs4208_fixup_gpio0() argument
656 struct cs_spec *spec = codec->spec; in cs4208_fixup_gpio0()
658 spec->gpio_eapd_hp = 0; in cs4208_fixup_gpio0()
659 spec->gpio_eapd_speaker = 1; in cs4208_fixup_gpio0()
660 spec->gpio_mask = spec->gpio_dir = in cs4208_fixup_gpio0()
661 spec->gpio_eapd_hp | spec->gpio_eapd_speaker; in cs4208_fixup_gpio0()
667 /* remap the fixup from codec SSID and apply it */
668 static void cs4208_fixup_mac(struct hda_codec *codec, in cs4208_fixup_mac() argument
674 codec->fixup_id = HDA_FIXUP_ID_NOT_SET; in cs4208_fixup_mac()
675 snd_hda_pick_fixup(codec, NULL, cs4208_mac_fixup_tbl, cs4208_fixups); in cs4208_fixup_mac()
676 if (codec->fixup_id == HDA_FIXUP_ID_NOT_SET) in cs4208_fixup_mac()
677 codec->fixup_id = CS4208_GPIO0; /* default fixup */ in cs4208_fixup_mac()
678 snd_hda_apply_fixup(codec, action); in cs4208_fixup_mac()
682 static void cs4208_fixup_macmini(struct hda_codec *codec, in cs4208_fixup_macmini() argument
686 { 0x18, 0x00ab9150 }, /* mic (audio-in) jack: disable detect */ in cs4208_fixup_macmini()
693 codec->inv_jack_detect = 1; in cs4208_fixup_macmini()
695 snd_hda_apply_pincfgs(codec, pincfgs); in cs4208_fixup_macmini()
702 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); in cs4208_spdif_sw_put() local
703 struct cs_spec *spec = codec->spec; in cs4208_spdif_sw_put()
704 hda_nid_t pin = spec->gen.autocfg.dig_out_pins[0]; in cs4208_spdif_sw_put()
705 int pinctl = ucontrol->value.integer.value[0] ? PIN_OUT : 0; in cs4208_spdif_sw_put()
707 snd_hda_set_pin_ctl_cache(codec, pin, pinctl); in cs4208_spdif_sw_put()
708 return spec->spdif_sw_put(kcontrol, ucontrol); in cs4208_spdif_sw_put()
712 static void cs4208_fixup_spdif_switch(struct hda_codec *codec, in cs4208_fixup_spdif_switch() argument
716 struct cs_spec *spec = codec->spec; in cs4208_fixup_spdif_switch()
719 if (!spec->gen.autocfg.dig_out_pins[0]) in cs4208_fixup_spdif_switch()
721 kctl = snd_hda_find_mixer_ctl(codec, "IEC958 Playback Switch"); in cs4208_fixup_spdif_switch()
724 spec->spdif_sw_put = kctl->put; in cs4208_fixup_spdif_switch()
725 kctl->put = cs4208_spdif_sw_put; in cs4208_fixup_spdif_switch()
759 static void cs4208_fix_amp_caps(struct hda_codec *codec, hda_nid_t adc) in cs4208_fix_amp_caps() argument
763 caps = query_amp_caps(codec, adc, HDA_INPUT); in cs4208_fix_amp_caps()
766 snd_hda_override_amp_caps(codec, adc, HDA_INPUT, caps); in cs4208_fix_amp_caps()
769 static int patch_cs4208(struct hda_codec *codec) in patch_cs4208() argument
774 spec = cs_alloc_spec(codec, CS4208_VENDOR_NID); in patch_cs4208()
776 return -ENOMEM; in patch_cs4208()
778 codec->patch_ops = cs_patch_ops; in patch_cs4208()
779 spec->gen.automute_hook = cs_automute; in patch_cs4208()
781 spec->gen.out_vol_mask = 1ULL << 0x10; in patch_cs4208()
783 snd_hda_pick_fixup(codec, cs4208_models, cs4208_fixup_tbl, in patch_cs4208()
785 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PRE_PROBE); in patch_cs4208()
787 snd_hda_override_wcaps(codec, 0x18, in patch_cs4208()
788 get_wcaps(codec, 0x18) | AC_WCAP_STEREO); in patch_cs4208()
789 cs4208_fix_amp_caps(codec, 0x18); in patch_cs4208()
790 cs4208_fix_amp_caps(codec, 0x1b); in patch_cs4208()
791 cs4208_fix_amp_caps(codec, 0x1c); in patch_cs4208()
793 err = cs_parse_auto_config(codec); in patch_cs4208()
797 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PROBE); in patch_cs4208()
802 cs_free(codec); in patch_cs4208()
851 static void cs421x_fixup_sense_b(struct hda_codec *codec, in cs421x_fixup_sense_b() argument
854 struct cs_spec *spec = codec->spec; in cs421x_fixup_sense_b()
857 spec->sense_b = 1; in cs421x_fixup_sense_b()
881 * Disable Coefficient Index Auto-Increment(DAI)=1,
905 * 2. Speaker output is not completely muted upon HP detect.
941 uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; in cs421x_boost_vol_info()
942 uinfo->count = 1; in cs421x_boost_vol_info()
943 uinfo->value.integer.min = 0; in cs421x_boost_vol_info()
944 uinfo->value.integer.max = 3; in cs421x_boost_vol_info()
951 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); in cs421x_boost_vol_get() local
953 ucontrol->value.integer.value[0] = in cs421x_boost_vol_get()
954 cs_vendor_coef_get(codec, CS421X_IDX_SPK_CTL) & 0x0003; in cs421x_boost_vol_get()
961 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); in cs421x_boost_vol_put() local
963 unsigned int vol = ucontrol->value.integer.value[0]; in cs421x_boost_vol_put()
965 cs_vendor_coef_get(codec, CS421X_IDX_SPK_CTL); in cs421x_boost_vol_put()
971 cs_vendor_coef_set(codec, CS421X_IDX_SPK_CTL, coef); in cs421x_boost_vol_put()
990 static void cs4210_pinmux_init(struct hda_codec *codec) in cs4210_pinmux_init() argument
992 struct cs_spec *spec = codec->spec; in cs4210_pinmux_init()
996 coef = cs_vendor_coef_get(codec, CS421X_IDX_DEV_CFG); in cs4210_pinmux_init()
998 if (spec->gpio_mask) in cs4210_pinmux_init()
1003 if (spec->sense_b) in cs4210_pinmux_init()
1008 cs_vendor_coef_set(codec, CS421X_IDX_DEV_CFG, coef); in cs4210_pinmux_init()
1010 if ((spec->gpio_mask || spec->sense_b) && in cs4210_pinmux_init()
1011 is_active_pin(codec, CS421X_DMIC_PIN_NID)) { in cs4210_pinmux_init()
1014 * GPIO or SENSE_B forced - disconnect the DMIC pin. in cs4210_pinmux_init()
1016 def_conf = snd_hda_codec_get_pincfg(codec, CS421X_DMIC_PIN_NID); in cs4210_pinmux_init()
1019 snd_hda_codec_set_pincfg(codec, CS421X_DMIC_PIN_NID, def_conf); in cs4210_pinmux_init()
1023 static void cs4210_spdif_automute(struct hda_codec *codec, in cs4210_spdif_automute() argument
1026 struct cs_spec *spec = codec->spec; in cs4210_spdif_automute()
1028 hda_nid_t spdif_pin = spec->gen.autocfg.dig_out_pins[0]; in cs4210_spdif_automute()
1031 if (!spec->spdif_detect || in cs4210_spdif_automute()
1032 spec->vendor_nid != CS4210_VENDOR_NID) in cs4210_spdif_automute()
1035 spdif_present = snd_hda_jack_detect(codec, spdif_pin); in cs4210_spdif_automute()
1036 if (spdif_present == spec->spdif_present) in cs4210_spdif_automute()
1039 spec->spdif_present = spdif_present; in cs4210_spdif_automute()
1041 snd_hda_set_pin_ctl(codec, spdif_pin, spdif_present ? PIN_OUT : 0); in cs4210_spdif_automute()
1043 cs_automute(codec); in cs4210_spdif_automute()
1046 static void parse_cs421x_digital(struct hda_codec *codec) in parse_cs421x_digital() argument
1048 struct cs_spec *spec = codec->spec; in parse_cs421x_digital()
1049 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in parse_cs421x_digital()
1052 for (i = 0; i < cfg->dig_outs; i++) { in parse_cs421x_digital()
1053 hda_nid_t nid = cfg->dig_out_pins[i]; in parse_cs421x_digital()
1055 if (get_wcaps(codec, nid) & AC_WCAP_UNSOL_CAP) { in parse_cs421x_digital()
1056 spec->spdif_detect = 1; in parse_cs421x_digital()
1057 snd_hda_jack_detect_enable_callback(codec, nid, in parse_cs421x_digital()
1063 static int cs421x_init(struct hda_codec *codec) in cs421x_init() argument
1065 struct cs_spec *spec = codec->spec; in cs421x_init()
1067 if (spec->vendor_nid == CS4210_VENDOR_NID) { in cs421x_init()
1068 snd_hda_sequence_write(codec, cs421x_coef_init_verbs); in cs421x_init()
1069 snd_hda_sequence_write(codec, cs421x_coef_init_verbs_A1_silicon_fixes); in cs421x_init()
1070 cs4210_pinmux_init(codec); in cs421x_init()
1073 snd_hda_gen_init(codec); in cs421x_init()
1075 if (spec->gpio_mask) { in cs421x_init()
1076 snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_MASK, in cs421x_init()
1077 spec->gpio_mask); in cs421x_init()
1078 snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_DIRECTION, in cs421x_init()
1079 spec->gpio_dir); in cs421x_init()
1080 snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_DATA, in cs421x_init()
1081 spec->gpio_data); in cs421x_init()
1084 init_input_coef(codec); in cs421x_init()
1086 cs4210_spdif_automute(codec, NULL); in cs421x_init()
1091 static void fix_volume_caps(struct hda_codec *codec, hda_nid_t dac) in fix_volume_caps() argument
1095 /* set the upper-limit for mixer amp to 0dB */ in fix_volume_caps()
1096 caps = query_amp_caps(codec, dac, HDA_OUTPUT); in fix_volume_caps()
1100 snd_hda_override_amp_caps(codec, dac, HDA_OUTPUT, caps); in fix_volume_caps()
1103 static int cs421x_parse_auto_config(struct hda_codec *codec) in cs421x_parse_auto_config() argument
1105 struct cs_spec *spec = codec->spec; in cs421x_parse_auto_config()
1109 fix_volume_caps(codec, dac); in cs421x_parse_auto_config()
1111 err = snd_hda_parse_pin_defcfg(codec, &spec->gen.autocfg, NULL, 0); in cs421x_parse_auto_config()
1115 err = snd_hda_gen_parse_auto_config(codec, &spec->gen.autocfg); in cs421x_parse_auto_config()
1119 parse_cs421x_digital(codec); in cs421x_parse_auto_config()
1121 if (spec->gen.autocfg.speaker_outs && in cs421x_parse_auto_config()
1122 spec->vendor_nid == CS4210_VENDOR_NID) { in cs421x_parse_auto_config()
1123 if (!snd_hda_gen_add_kctl(&spec->gen, NULL, in cs421x_parse_auto_config()
1125 return -ENOMEM; in cs421x_parse_auto_config()
1134 * (DAC,ADC) -> D3, PDREF=1, AFG->D3
1136 static int cs421x_suspend(struct hda_codec *codec) in cs421x_suspend() argument
1138 struct cs_spec *spec = codec->spec; in cs421x_suspend()
1141 snd_hda_shutup_pins(codec); in cs421x_suspend()
1143 snd_hda_codec_write(codec, CS4210_DAC_NID, 0, in cs421x_suspend()
1145 snd_hda_codec_write(codec, CS4210_ADC_NID, 0, in cs421x_suspend()
1148 if (spec->vendor_nid == CS4210_VENDOR_NID) { in cs421x_suspend()
1149 coef = cs_vendor_coef_get(codec, CS421X_IDX_DEV_CFG); in cs421x_suspend()
1151 cs_vendor_coef_set(codec, CS421X_IDX_DEV_CFG, coef); in cs421x_suspend()
1169 static int patch_cs4210(struct hda_codec *codec) in patch_cs4210() argument
1174 spec = cs_alloc_spec(codec, CS4210_VENDOR_NID); in patch_cs4210()
1176 return -ENOMEM; in patch_cs4210()
1178 codec->patch_ops = cs421x_patch_ops; in patch_cs4210()
1179 spec->gen.automute_hook = cs_automute; in patch_cs4210()
1181 snd_hda_pick_fixup(codec, cs421x_models, cs421x_fixup_tbl, in patch_cs4210()
1183 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PRE_PROBE); in patch_cs4210()
1187 * is auto-parsed. If GPIO or SENSE_B is forced, DMIC input in patch_cs4210()
1190 cs4210_pinmux_init(codec); in patch_cs4210()
1192 err = cs421x_parse_auto_config(codec); in patch_cs4210()
1196 snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_PROBE); in patch_cs4210()
1201 cs_free(codec); in patch_cs4210()
1205 static int patch_cs4213(struct hda_codec *codec) in patch_cs4213() argument
1210 spec = cs_alloc_spec(codec, CS4213_VENDOR_NID); in patch_cs4213()
1212 return -ENOMEM; in patch_cs4213()
1214 codec->patch_ops = cs421x_patch_ops; in patch_cs4213()
1216 err = cs421x_parse_auto_config(codec); in patch_cs4213()
1223 cs_free(codec); in patch_cs4213()
1241 MODULE_DESCRIPTION("Cirrus Logic HD-audio codec");