{
struct i915_audio_component *acomp = bus->audio_component;
- if (!acomp->ops)
+ if (!acomp || !acomp->ops)
return -ENODEV;
if (!acomp->ops->codec_wake_override) {
{
struct i915_audio_component *acomp = bus->audio_component;
- if (!acomp->ops)
+ if (!acomp || !acomp->ops)
return -ENODEV;
dev_dbg(bus->dev, "display power %s\n",
{
struct i915_audio_component *acomp = bus->audio_component;
- if (!acomp->ops)
+ if (!acomp || !acomp->ops)
return -ENODEV;
return acomp->ops->get_cdclk_freq(acomp->dev);
struct device *dev = bus->dev;
struct i915_audio_component *acomp = bus->audio_component;
+ if (!acomp)
+ return 0;
+
WARN_ON(bus->i915_power_refcount);
- if (bus->i915_power_refcount > 0 && acomp && acomp->ops)
+ if (bus->i915_power_refcount > 0 && acomp->ops)
acomp->ops->put_power(acomp->dev);
component_master_del(dev, &hdac_component_master_ops);