aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'sound/hda/hdac_i915.c')
-rw-r--r--sound/hda/hdac_i915.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/hda/hdac_i915.c b/sound/hda/hdac_i915.c
index 8fef1b8d1fd8..bd7bcf428bcf 100644
--- a/sound/hda/hdac_i915.c
+++ b/sound/hda/hdac_i915.c
@@ -183,7 +183,7 @@ static int hdac_component_master_match(struct device *dev, void *data)
183 */ 183 */
184int snd_hdac_i915_register_notifier(const struct i915_audio_component_audio_ops *aops) 184int snd_hdac_i915_register_notifier(const struct i915_audio_component_audio_ops *aops)
185{ 185{
186 if (WARN_ON(!hdac_acomp)) 186 if (!hdac_acomp)
187 return -ENODEV; 187 return -ENODEV;
188 188
189 hdac_acomp->audio_ops = aops; 189 hdac_acomp->audio_ops = aops;
@@ -240,7 +240,8 @@ out_master_del:
240out_err: 240out_err:
241 kfree(acomp); 241 kfree(acomp);
242 bus->audio_component = NULL; 242 bus->audio_component = NULL;
243 dev_err(dev, "failed to add i915 component master (%d)\n", ret); 243 hdac_acomp = NULL;
244 dev_info(dev, "failed to add i915 component master (%d)\n", ret);
244 245
245 return ret; 246 return ret;
246} 247}
@@ -273,6 +274,7 @@ int snd_hdac_i915_exit(struct hdac_bus *bus)
273 274
274 kfree(acomp); 275 kfree(acomp);
275 bus->audio_component = NULL; 276 bus->audio_component = NULL;
277 hdac_acomp = NULL;
276 278
277 return 0; 279 return 0;
278} 280}