diff --git a/drivers/gpu/drm/display/drm_hdmi_state_helper.c b/drivers/gpu/drm/display/drm_hdmi_state_helper.c index 5a3817271d91..e8556bf9e1da 100644 --- a/drivers/gpu/drm/display/drm_hdmi_state_helper.c +++ b/drivers/gpu/drm/display/drm_hdmi_state_helper.c @@ -1061,7 +1061,7 @@ drm_atomic_helper_connector_hdmi_update_audio_infoframe(struct drm_connector *co if (!info->is_hdmi) return 0; - if (!funcs) { + if (!funcs || !funcs->audio.write_infoframe) { drm_dbg_kms(connector->dev, "Function not implemented, bailing.\n"); return -EINVAL; } @@ -1102,7 +1102,7 @@ drm_atomic_helper_connector_hdmi_clear_audio_infoframe(struct drm_connector *con if (!info->is_hdmi) return 0; - if (!funcs) { + if (!funcs || !funcs->audio.write_infoframe) { drm_dbg_kms(connector->dev, "Function not implemented, bailing.\n"); return -EINVAL; }