diff options
author | Takashi Iwai <tiwai@suse.de> | 2021-02-03 13:42:41 +0100 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2021-03-05 15:13:55 -0500 |
commit | 7c20984795d7c26a8993ca2bd2c1cbad312b2ffa (patch) | |
tree | a6d99a6c607fba501430bdf33946c4d15ae08910 /drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | |
parent | f275e8759c872d0a2a53dce0a49c02fe10263010 (diff) | |
download | linux-7c20984795d7c26a8993ca2bd2c1cbad312b2ffa.tar.bz2 |
drm/amd/display: Add a backlight module option
There seem devices that don't work with the aux channel backlight
control. For allowing such users to test with the other backlight
control method, provide a new module option, aux_backlight, to specify
enabling or disabling the aux backport support explicitly. As
default, the aux support is detected by the hardware capability.
v2: make the backlight option generic in case we add future
backlight types (Alex)
BugLink: https://bugzilla.opensuse.org/show_bug.cgi?id=1180749
BugLink: https://gitlab.freedesktop.org/drm/amd/-/issues/1438
Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c')
-rw-r--r-- | drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index ad64e01ab0c4..281b99fa64a7 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -2324,6 +2324,11 @@ static void update_connector_ext_caps(struct amdgpu_dm_connector *aconnector) caps->ext_caps->bits.hdr_aux_backlight_control == 1) caps->aux_support = true; + if (amdgpu_backlight == 0) + caps->aux_support = false; + else if (amdgpu_backlight == 1) + caps->aux_support = true; + /* From the specification (CTA-861-G), for calculating the maximum * luminance we need to use: * Luminance = 50*2**(CV/32) |