aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/hda')
-rw-r--r--sound/pci/hda/hda_jack.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sound/pci/hda/hda_jack.c b/sound/pci/hda/hda_jack.c
index eac002d01fd..ef36cbb9e96 100644
--- a/sound/pci/hda/hda_jack.c
+++ b/sound/pci/hda/hda_jack.c
@@ -194,6 +194,8 @@ void snd_hda_jack_report_sync(struct hda_codec *codec)
194 for (i = 0; i < codec->jacktbl.used; i++, jack++) 194 for (i = 0; i < codec->jacktbl.used; i++, jack++)
195 if (jack->nid) { 195 if (jack->nid) {
196 jack_detect_update(codec, jack); 196 jack_detect_update(codec, jack);
197 if (!jack->kctl)
198 continue;
197 state = get_jack_plug_state(jack->pin_sense); 199 state = get_jack_plug_state(jack->pin_sense);
198 snd_kctl_jack_report(codec->bus->card, jack->kctl, state); 200 snd_kctl_jack_report(codec->bus->card, jack->kctl, state);
199 } 201 }
@@ -356,7 +358,7 @@ void snd_hda_input_jack_report(struct hda_codec *codec, hda_nid_t nid)
356 unsigned int present; 358 unsigned int present;
357 int type; 359 int type;
358 360
359 if (!jack) 361 if (!jack || !jack->jack)
360 return; 362 return;
361 363
362 present = snd_hda_jack_detect(codec, nid); 364 present = snd_hda_jack_detect(codec, nid);