ext_disp->current_disp = data->type;
} else if ((state == EXT_DISPLAY_CABLE_DISCONNECT) &&
!ext_disp->ack_enabled) {
- ext_disp->ops->audio_info_setup = NULL;
- ext_disp->ops->get_audio_edid_blk = NULL;
- ext_disp->ops->cable_status = NULL;
- ext_disp->ops->get_intf_id = NULL;
+ if (ext_disp->ops) {
+ ext_disp->ops->audio_info_setup = NULL;
+ ext_disp->ops->get_audio_edid_blk = NULL;
+ ext_disp->ops->cable_status = NULL;
+ ext_disp->ops->get_intf_id = NULL;
+ }
+
ext_disp->current_disp = EXT_DISPLAY_TYPE_MAX;
}
if (ret)
goto end;
- if (new_state == EXT_DISPLAY_CABLE_CONNECT) {
+ if (new_state == EXT_DISPLAY_CABLE_CONNECT && ext_disp->ops) {
ext_disp->ops->audio_info_setup =
data->codec_ops.audio_info_setup;
ext_disp->ops->get_audio_edid_blk =
* empty.
*/
if (!ack_hpd) {
- ext_disp->ops->audio_info_setup = NULL;
- ext_disp->ops->get_audio_edid_blk = NULL;
- ext_disp->ops->cable_status = NULL;
- ext_disp->ops->get_intf_id = NULL;
+ if (ext_disp->ops) {
+ ext_disp->ops->audio_info_setup = NULL;
+ ext_disp->ops->get_audio_edid_blk = NULL;
+ ext_disp->ops->cable_status = NULL;
+ ext_disp->ops->get_intf_id = NULL;
+ }
+
ext_disp->current_disp = EXT_DISPLAY_TYPE_MAX;
}