From 9547bb18ef8efae6c97bf5cd0046e4c1195be519 Mon Sep 17 00:00:00 2001 From: q66 Date: Sat, 30 Jan 2021 19:39:42 +0100 Subject: [PATCH] linux5.10: fix dcn30 ppc64 patch on musl since musl uses 64-bit ldbl, this will trigger the soft vs hard float linker nonsense, so apply the same hack as for renoir --- .../patches/amdgpu-dcn30-ppc64.patch | 30 ++++++++++++++++--- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/srcpkgs/linux5.10/patches/amdgpu-dcn30-ppc64.patch b/srcpkgs/linux5.10/patches/amdgpu-dcn30-ppc64.patch index a72cdfea781..6f5688d7530 100644 --- a/srcpkgs/linux5.10/patches/amdgpu-dcn30-ppc64.patch +++ b/srcpkgs/linux5.10/patches/amdgpu-dcn30-ppc64.patch @@ -1,12 +1,13 @@ -From 3a75ebe236580073d77ad69730fc1d8980e130c2 Mon Sep 17 00:00:00 2001 +From 295ba06fc80af54595c604ca6bab5f3e9c9ef154 Mon Sep 17 00:00:00 2001 From: Daniel Kolesa Date: Fri, 29 Jan 2021 22:25:29 +0100 Subject: [PATCH] amd/display: enable dcn30 for ppc64 --- - drivers/gpu/drm/amd/display/Kconfig | 2 +- - drivers/gpu/drm/amd/display/dc/dcn30/Makefile | 2 ++ - 2 files changed, 3 insertions(+), 1 deletion(-) + drivers/gpu/drm/amd/display/Kconfig | 2 +- + drivers/gpu/drm/amd/display/dc/clk_mgr/Makefile | 10 ++++++++++ + drivers/gpu/drm/amd/display/dc/dcn30/Makefile | 2 ++ + 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/Kconfig b/drivers/gpu/drm/amd/display/Kconfig index 3c410d2..a749cc7 100644 @@ -21,6 +22,27 @@ index 3c410d2..a749cc7 100644 depends on DRM_AMD_DC_DCN help Choose this option if you want to have +diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/Makefile b/drivers/gpu/drm/amd/display/dc/clk_mgr/Makefile +index 52b1ce7..adf3919 100644 +--- a/drivers/gpu/drm/amd/display/dc/clk_mgr/Makefile ++++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/Makefile +@@ -114,6 +114,16 @@ ifdef CONFIG_DRM_AMD_DC_DCN3_0 + ############################################################################### + CLK_MGR_DCN30 = dcn30_clk_mgr.o dcn30_clk_mgr_smu_msg.o + ++# see above ++# technically it should not matter that this file is soft-float since all it ++# does is read doubles from a struct and write them somewhere else; this is not ++# passing between hard-float and soft-float APIs via registers (which would be ++# problematic because of different calling convention), and the memory layout ++# is always the same (IEEE double precision) so the error is probably harmless ++ifdef CONFIG_PPC64 ++CFLAGS_$(AMDDALPATH)/dc/clk_mgr/dcn30/dcn30_clk_mgr.o := $(call cc-option,-mno-gnu-attribute) ++endif ++ + AMD_DAL_CLK_MGR_DCN30 = $(addprefix $(AMDDALPATH)/dc/clk_mgr/dcn30/,$(CLK_MGR_DCN30)) + + AMD_DISPLAY_FILES += $(AMD_DAL_CLK_MGR_DCN30) diff --git a/drivers/gpu/drm/amd/display/dc/dcn30/Makefile b/drivers/gpu/drm/amd/display/dc/dcn30/Makefile index bd2a068..248c271 100644 --- a/drivers/gpu/drm/amd/display/dc/dcn30/Makefile