static void hdmi_unsol_event(struct hda_codec *codec, unsigned int res)
 {
-       struct hdmi_spec *spec = codec->spec;
        int tag = res >> AC_UNSOL_RES_TAG_SHIFT;
        int subtag = (res & AC_UNSOL_RES_SUBTAG) >> AC_UNSOL_RES_SUBTAG_SHIFT;
 
        if (pcmdev > 0)
                sprintf(hdmi_str + strlen(hdmi_str), ",pcm=%d", pcmdev);
 
-       hdmi_present_sense(per_pin, 0);
        return snd_hda_jack_add_kctl(codec, per_pin->pin_nid, hdmi_str, 0);
 }
 
                if (err < 0)
                        return err;
 
-               hdmi_present_sense(per_pin, false);
+               hdmi_present_sense(per_pin, 0);
        }
 
        return 0;