snd_printdd("hda-codec: Enable HP auto-muting on NID 0x%x\n",
                            nid);
                snd_hda_jack_detect_enable_callback(codec, nid, HDA_GEN_HP_EVENT,
+                                                   spec->hp_automute_hook ?
+                                                   spec->hp_automute_hook :
                                                    snd_hda_gen_hp_automute);
                spec->detect_hp = 1;
        }
                                snd_printdd("hda-codec: Enable Line-Out auto-muting on NID 0x%x\n", nid);
                                snd_hda_jack_detect_enable_callback(codec, nid,
                                                                    HDA_GEN_FRONT_EVENT,
+                                                                   spec->line_automute_hook ?
+                                                                   spec->line_automute_hook :
                                                                    snd_hda_gen_line_automute);
                                spec->detect_lo = 1;
                        }
                snd_hda_jack_detect_enable_callback(codec,
                                                    spec->am_entry[i].pin,
                                                    HDA_GEN_MIC_EVENT,
+                                                   spec->mic_autoswitch_hook ?
+                                                   spec->mic_autoswitch_hook :
                                                    snd_hda_gen_mic_autoswitch);
        return true;
 }
 
        void (*init_hook)(struct hda_codec *codec);
        void (*automute_hook)(struct hda_codec *codec);
        void (*cap_sync_hook)(struct hda_codec *codec);
+
+       /* automute / autoswitch hooks */
+       void (*hp_automute_hook)(struct hda_codec *codec,
+                                struct hda_jack_tbl *tbl);
+       void (*line_automute_hook)(struct hda_codec *codec,
+                                  struct hda_jack_tbl *tbl);
+       void (*mic_autoswitch_hook)(struct hda_codec *codec,
+                                   struct hda_jack_tbl *tbl);
 };
 
 int snd_hda_gen_spec_init(struct hda_gen_spec *spec);