From 5a511e4f9edd3c1e3c5e8c726ced91b4a4d010a6 Mon Sep 17 00:00:00 2001 From: Hector Martin Date: Mon, 26 Dec 2016 12:15:20 +0900 Subject: [PATCH] radeon: always enable audio pin #3 on Liverpool --- drivers/gpu/drm/radeon/radeon.h | 6 +++--- drivers/gpu/drm/radeon/radeon_audio.c | 4 ++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h index 4fca3a44c23c6c..610780661a53aa 100644 --- a/drivers/gpu/drm/radeon/radeon.h +++ b/drivers/gpu/drm/radeon/radeon.h @@ -2656,10 +2656,10 @@ void r100_pll_errata_after_index(struct radeon_device *rdev); #define ASIC_IS_NODCE(rdev) ((rdev->family == CHIP_HAINAN)) #define ASIC_IS_DCE8(rdev) ((rdev->family >= CHIP_BONAIRE)) #define ASIC_IS_DCE81(rdev) ((rdev->family == CHIP_KAVERI)) -#define ASIC_IS_DCE82(rdev) ((rdev->family == CHIP_BONAIRE) || \ - (rdev->family == CHIP_LIVERPOOL)) +#define ASIC_IS_DCE82(rdev) ((rdev->family == CHIP_BONAIRE)) #define ASIC_IS_DCE83(rdev) ((rdev->family == CHIP_KABINI) || \ - (rdev->family == CHIP_MULLINS)) + (rdev->family == CHIP_MULLINS) || \ + (rdev->family == CHIP_LIVERPOOL)) #define ASIC_IS_LOMBOK(rdev) ((rdev->ddev->pdev->device == 0x6849) || \ (rdev->ddev->pdev->device == 0x6850) || \ diff --git a/drivers/gpu/drm/radeon/radeon_audio.c b/drivers/gpu/drm/radeon/radeon_audio.c index 770e31f5fd1b0c..2bdc7ecf47b8bb 100644 --- a/drivers/gpu/drm/radeon/radeon_audio.c +++ b/drivers/gpu/drm/radeon/radeon_audio.c @@ -338,6 +338,10 @@ int radeon_audio_init(struct radeon_device *rdev) for (i = 0; i < rdev->audio.num_pins; i++) radeon_audio_enable(rdev, &rdev->audio.pin[i], 0); + /* LVP has standalone S/PDIF on the third pin, always enable */ + if (rdev->family == CHIP_LIVERPOOL) { + radeon_audio_enable(rdev, &rdev->audio.pin[2], 0xf); + } return 0; }