summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/Kconfig
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2022-10-24 18:40:54 +0300
committerAlex Deucher <alexander.deucher@amd.com>2022-11-10 23:29:00 +0300
commit20ea34710f7b20e218a42d457da618d99e3fc9d6 (patch)
tree099a27952d251bde711b936204b97dfea207bd25 /drivers/gpu/drm/Kconfig
parentd1a372af1c3d834c2346b2e822cd6c40abc09866 (diff)
downloadlinux-20ea34710f7b20e218a42d457da618d99e3fc9d6.tar.xz
drm/radeon: Add HD-audio component notifier support (v6)
This patch adds the support for the notification of HD-audio hotplug via the already existing drm_audio_component framework to radeon driver. This allows us more reliable hotplug notification and ELD transfer without accessing HD-audio bus; it's more efficient, and more importantly, it works without waking up the runtime PM. The implementation is rather simplistic: radeon driver provides the get_eld ops for HD-audio, and it notifies the audio hotplug via pin_eld_notify callback upon each radeon_audio_enable() call. The pin->id is referred as the port number passed to the notifier callback, and the corresponding connector is looked through the encoder list in the get_eld callback in turn. The bind and unbind callbacks handle the device-link so that it assures the PM call order. Also, as a gratis bonus, this patch "fixes" the regression by the recent change in HD-audio to be more strict for the HDMI/DP connection, too. Since the HD-audio HDMI/DP codec requires both the connection bit and the valid ELD to be provided, it started failing on some RADEON gfx boards where the ELD update performed instably. As this change switches the communication to a direct way between the audio and the graphics drivers, now the system receives the proper ELD, and the HDMI/DP hotplug starts working again. [ v2: fix the logic in radeon_audio_component_get_eld to walk the connector list since that is where the EDID lives and we can derive the encoder from the connector because the encoder has not been assigned at this point (i.e., during monitor probe). v3: the component binding is moved outside radeon_audio_init() and _fini(), as those are called from suspend/resume, too. Drop modeset lock calls that caused Oops. Moved Kconfig change so that it can be applied on older kernels. v4: revive drm_modeset_lock*() again, add the missing device_link_remove() call at unbinding v5: squash in mutex fix v6: squash in fix for audio get_eld callback ] Link: https://gitlab.freedesktop.org/drm/amd/-/issues/1569 Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/Kconfig')
-rw-r--r--drivers/gpu/drm/Kconfig1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index 34f5a092c99e..fa986075e8fb 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -243,6 +243,7 @@ config DRM_RADEON
select DRM_KMS_HELPER
select DRM_TTM
select DRM_TTM_HELPER
+ select SND_HDA_COMPONENT if SND_HDA_CORE
select POWER_SUPPLY
select HWMON
select BACKLIGHT_CLASS_DEVICE