struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
int status, result;
- if (!radeon_encoder->hdmi_offset)
+ if (!radeon_encoder->hdmi_enabled)
return 0;
status = r600_hdmi_is_audio_buffer_filled(encoder);
struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
uint32_t offset = radeon_encoder->hdmi_offset;
- if (!offset)
+ if (!radeon_encoder->hdmi_enabled)
return;
if (!radeon_encoder->hdmi_audio_workaround ||
if (ASIC_IS_DCE5(rdev))
return;
- if (!offset)
+ if (!to_radeon_encoder(encoder)->hdmi_enabled)
return;
r600_audio_set_clock(encoder, mode->clock);
uint32_t iec;
- if (!offset)
+ if (!to_radeon_encoder(encoder)->hdmi_enabled)
return;
DRM_DEBUG("%s with %d channels, %d Hz sampling rate, %d bits per sample,\n",
/* Only 1 routable block */
radeon_encoder->hdmi_offset = R600_HDMI_BLOCK1;
}
+ radeon_encoder->hdmi_enabled = true;
}
/*
if (ASIC_IS_DCE5(rdev))
return;
- if (!radeon_encoder->hdmi_offset) {
+ if (!radeon_encoder->hdmi_enabled) {
r600_hdmi_assign_block(encoder);
- if (!radeon_encoder->hdmi_offset) {
+ if (!radeon_encoder->hdmi_enabled) {
dev_warn(rdev->dev, "Could not find HDMI block for "
"0x%x encoder\n", radeon_encoder->encoder_id);
return;
return;
offset = radeon_encoder->hdmi_offset;
- if (!offset) {
+ if (!radeon_encoder->hdmi_enabled) {
dev_err(rdev->dev, "Disabling not enabled HDMI\n");
return;
}
}
}
+ radeon_encoder->hdmi_enabled = false;
radeon_encoder->hdmi_offset = 0;
}