summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/radeon_audio.c
diff options
context:
space:
mode:
authorSlava Grigorev <slava.grigorev@amd.com>2014-12-10 14:52:43 -0500
committerAlex Deucher <alexander.deucher@amd.com>2015-01-22 10:42:17 -0500
commit6f945693be7eea24b1a8e5ce252a96df98d55a5c (patch)
tree400b28c40a96ca5f87c577087da4b4dd6cca1da0 /drivers/gpu/drm/radeon/radeon_audio.c
parent6e72376dcc663e4b8a00cdd08f61a8623f572ef1 (diff)
downloadblackbird-op-linux-6f945693be7eea24b1a8e5ce252a96df98d55a5c.tar.gz
blackbird-op-linux-6f945693be7eea24b1a8e5ce252a96df98d55a5c.zip
radeon/audio: applied audio_dpms() and audio_mode_set() calls
Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Slava Grigorev <slava.grigorev@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_audio.c')
-rw-r--r--drivers/gpu/drm/radeon/radeon_audio.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_audio.c b/drivers/gpu/drm/radeon/radeon_audio.c
index 05c7ffed6996..4a2774ac7827 100644
--- a/drivers/gpu/drm/radeon/radeon_audio.c
+++ b/drivers/gpu/drm/radeon/radeon_audio.c
@@ -97,6 +97,8 @@ void dce3_2_set_mute(struct drm_encoder *encoder, u32 offset, bool mute);
void dce4_set_mute(struct drm_encoder *encoder, u32 offset, bool mute);
static void radeon_audio_hdmi_mode_set(struct drm_encoder *encoder,
struct drm_display_mode *mode);
+void r600_hdmi_enable(struct drm_encoder *encoder, bool enable);
+void evergreen_hdmi_enable(struct drm_encoder *encoder, bool enable);
static const u32 pin_offsets[7] =
{
@@ -153,6 +155,7 @@ static struct radeon_audio_funcs r600_hdmi_funcs = {
.set_audio_packet = r600_set_audio_packet,
.set_mute = r600_set_mute,
.mode_set = radeon_audio_hdmi_mode_set,
+ .dpms = r600_hdmi_enable,
};
static struct radeon_audio_funcs dce32_hdmi_funcs = {
@@ -166,6 +169,7 @@ static struct radeon_audio_funcs dce32_hdmi_funcs = {
.set_audio_packet = dce3_2_set_audio_packet,
.set_mute = dce3_2_set_mute,
.mode_set = radeon_audio_hdmi_mode_set,
+ .dpms = r600_hdmi_enable,
};
static struct radeon_audio_funcs dce32_dp_funcs = {
@@ -189,6 +193,7 @@ static struct radeon_audio_funcs dce4_hdmi_funcs = {
.set_audio_packet = dce4_set_audio_packet,
.set_mute = dce4_set_mute,
.mode_set = radeon_audio_hdmi_mode_set,
+ .dpms = evergreen_hdmi_enable,
};
static struct radeon_audio_funcs dce4_dp_funcs = {
@@ -214,6 +219,7 @@ static struct radeon_audio_funcs dce6_hdmi_funcs = {
.set_audio_packet = dce4_set_audio_packet,
.set_mute = dce4_set_mute,
.mode_set = radeon_audio_hdmi_mode_set,
+ .dpms = evergreen_hdmi_enable,
};
static struct radeon_audio_funcs dce6_dp_funcs = {
@@ -705,3 +711,11 @@ void radeon_audio_mode_set(struct drm_encoder *encoder,
if (radeon_encoder->audio && radeon_encoder->audio->mode_set)
radeon_encoder->audio->mode_set(encoder, mode);
}
+
+void radeon_audio_dpms(struct drm_encoder *encoder, int mode)
+{
+ struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
+
+ if (radeon_encoder->audio && radeon_encoder->audio->dpms)
+ radeon_encoder->audio->dpms(encoder, mode == DRM_MODE_DPMS_ON);
+}
OpenPOWER on IntegriCloud