summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/display/dc/bios
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/bios')
-rw-r--r--drivers/gpu/drm/amd/display/dc/bios/Makefile8
-rw-r--r--drivers/gpu/drm/amd/display/dc/bios/bios_parser_interface.c14
2 files changed, 22 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/bios/Makefile b/drivers/gpu/drm/amd/display/dc/bios/Makefile
index 876614d37412..770248429a81 100644
--- a/drivers/gpu/drm/amd/display/dc/bios/Makefile
+++ b/drivers/gpu/drm/amd/display/dc/bios/Makefile
@@ -4,6 +4,10 @@
BIOS = bios_parser.o bios_parser_interface.o bios_parser_helper.o command_table.o command_table_helper.o
+ifdef CONFIG_DRM_AMD_DC_DCE12_0
+BIOS += command_table2.o command_table_helper2.o bios_parser2.o
+endif
+
AMD_DAL_BIOS = $(addprefix $(AMDDALPATH)/dc/bios/,$(BIOS))
AMD_DISPLAY_FILES += $(AMD_DAL_BIOS)
@@ -21,3 +25,7 @@ AMD_DISPLAY_FILES += $(AMDDALPATH)/dc/bios/dce80/command_table_helper_dce80.o
AMD_DISPLAY_FILES += $(AMDDALPATH)/dc/bios/dce110/command_table_helper_dce110.o
AMD_DISPLAY_FILES += $(AMDDALPATH)/dc/bios/dce112/command_table_helper_dce112.o
+
+ifdef CONFIG_DRM_AMD_DC_DCE12_0
+AMD_DISPLAY_FILES += $(AMDDALPATH)/dc/bios/dce112/command_table_helper2_dce112.o
+endif
diff --git a/drivers/gpu/drm/amd/display/dc/bios/bios_parser_interface.c b/drivers/gpu/drm/amd/display/dc/bios/bios_parser_interface.c
index 42272c35df2d..7fe2a791ef42 100644
--- a/drivers/gpu/drm/amd/display/dc/bios/bios_parser_interface.c
+++ b/drivers/gpu/drm/amd/display/dc/bios/bios_parser_interface.c
@@ -29,6 +29,10 @@
#include "bios_parser_interface.h"
#include "bios_parser.h"
+#if defined(CONFIG_DRM_AMD_DC_DCE12_0)
+#include "bios_parser2.h"
+#endif
+
struct dc_bios *dal_bios_parser_create(
struct bp_init_data *init,
@@ -36,7 +40,17 @@ struct dc_bios *dal_bios_parser_create(
{
struct dc_bios *bios = NULL;
+#if defined(CONFIG_DRM_AMD_DC_DCE12_0)
+ bios = firmware_parser_create(init, dce_version);
+
+ if (bios == NULL)
+ /* TODO: remove dce_version from bios_parser.
+ * cannot remove today because dal enum to bp enum translation is dce specific
+ */
+ bios = bios_parser_create(init, dce_version);
+#else
bios = bios_parser_create(init, dce_version);
+#endif
return bios;
}