aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/display/dmub/src
diff options
context:
space:
mode:
authorDuncan Ma <[email protected]>2024-04-22 14:17:11 +0000
committerAlex Deucher <[email protected]>2024-05-13 19:47:59 +0000
commitfa73ec95c969c7af292caf622ef499e7af7cb062 (patch)
treee6ded23e6052a27f42178c7c6448d05be9152172 /drivers/gpu/drm/amd/display/dmub/src
parentdrm/amd/display: Find max flickerless instant vtotal delta (diff)
downloadkernel-fa73ec95c969c7af292caf622ef499e7af7cb062.tar.gz
kernel-fa73ec95c969c7af292caf622ef499e7af7cb062.zip
drm/amd/display: Read default boot options
[WHY] DPIA boot option is set by VBIOS. It gets overwritten when driver loads DMU. [HOW] Read PreOS boot options and determine if dpia is enabled. Reviewed-by: Ovidiu Bunea <[email protected]> Acked-by: Alex Hung <[email protected]> Signed-off-by: Duncan Ma <[email protected]> Tested-by: Daniel Wheeler <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dmub/src')
-rw-r--r--drivers/gpu/drm/amd/display/dmub/src/dmub_dcn35.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn35.c b/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn35.c
index 70e63aeb8f89..7f53074f4e48 100644
--- a/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn35.c
+++ b/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn35.c
@@ -410,10 +410,13 @@ union dmub_fw_boot_options dmub_dcn35_get_fw_boot_option(struct dmub_srv *dmub)
void dmub_dcn35_enable_dmub_boot_options(struct dmub_srv *dmub, const struct dmub_srv_hw_params *params)
{
union dmub_fw_boot_options boot_options = {0};
+ union dmub_fw_boot_options cur_boot_options = {0};
+
+ cur_boot_options = dmub_dcn35_get_fw_boot_option(dmub);
boot_options.bits.z10_disable = params->disable_z10;
boot_options.bits.dpia_supported = params->dpia_supported;
- boot_options.bits.enable_dpia = params->disable_dpia == true ? 0:1;
+ boot_options.bits.enable_dpia = cur_boot_options.bits.enable_dpia && !params->disable_dpia;
boot_options.bits.usb4_cm_version = params->usb4_cm_version;
boot_options.bits.dpia_hpd_int_enable_supported = params->dpia_hpd_int_enable_supported;
boot_options.bits.power_optimization = params->power_optimization;