Skip to contentSkip to conversation

linux-next: manual merge of the drm tree with the kbuild tree

PATCH Mark Brown 2 participants 3 messages Sep 15, 2019 – Sep 16, 2019

Subsystems (5)
lore
Share & tools
lore

Mark Brown

author maintainer
#0 lore raw

Hi all,

Today's linux-next merge of the drm tree got a conflict in:

drivers/gpu/drm/amd/display/dc/dml/Makefile

between commit:

  54b8ae66ae1a345 ("kbuild: change *FLAGS_<basetarget>.o to take the path relative to $(obj)")

from the kbuild tree and commits:

0f0727d971f6fdf ("drm/amd/display: readd -msse2 to prevent Clang from emitting libcalls to undefined SW FP routines") 542816ff168d8a3 ("drm/amd/display: Add DCN2.1 changes to DML")
b04641a3f4c54b0 ("drm/amd/display: Add Renoir DML")
057fc695e934a77 ("drm/amd/display: support "dummy pstate"")

from the drm tree.

I fixed it up (see below) and can carry the fix as necessary. This is now fixed as far as linux-next is concerned, but any non trivial conflicts should be mentioned to your upstream maintainer when your tree is submitted for merging. You may also want to consider cooperating with the maintainer of the conflicting tree to minimise any particularly complex conflicts.

drivers/gpu/drm/amd/display/dc/dml/Makefile +0 -0
diff --cc drivers/gpu/drm/amd/display/dc/dml/Makefile
index 83792e2c0f0e4,af2a864a6da05..0000000000000
@@@ -32,16 -32,29 +32,25 @@@ endi
  
  dml_ccflags := -mhard-float -msse $(cc_stack_align)
  
+ ifdef CONFIG_CC_IS_CLANG
+ dml_ccflags += -msse2
+ endif
+ 
 -CFLAGS_display_mode_lib.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/display_mode_lib.o := $(dml_ccflags)
  
  ifdef CONFIG_DRM_AMD_DC_DCN2_0
 -CFLAGS_display_mode_vba.o := $(dml_ccflags)
 -CFLAGS_display_mode_vba_20.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_calc_20.o := $(dml_ccflags)
 -CFLAGS_display_mode_vba_20v2.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_calc_20v2.o := $(dml_ccflags)
 -endif
 +CFLAGS_$(AMDDALPATH)/dc/dml/display_mode_vba.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_mode_vba_20.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_rq_dlg_calc_20.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_mode_vba_20v2.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_rq_dlg_calc_20v2.o := $(dml_ccflags)
+ ifdef CONFIG_DRM_AMD_DC_DCN2_1
 -CFLAGS_display_mode_vba_21.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_calc_21.o := $(dml_ccflags)
 -endif
 -ifdef CONFIG_DRM_AMD_DCN3AG
 -CFLAGS_display_mode_vba_3ag.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn21/display_mode_vba_21.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn21/display_rq_dlg_calc_21.o := $(dml_ccflags)
  endif
 -CFLAGS_dml1_display_rq_dlg_calc.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_helpers.o := $(dml_ccflags)
 -CFLAGS_dml_common_defs.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/dml1_display_rq_dlg_calc.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/display_rq_dlg_helpers.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/dml_common_defs.o := $(dml_ccflags)
  
  DML = display_mode_lib.o display_rq_dlg_helpers.o dml1_display_rq_dlg_calc.o \
  	dml_common_defs.o
#1 lore raw
Quoted 7 lines · Mark Brown

Hi all,

Today's linux-next merge of the drm tree got a conflict in:

drivers/gpu/drm/amd/display/dc/dml/Makefile

Quoted 7 lines

between commit:

  54b8ae66ae1a345 ("kbuild: change *FLAGS_<basetarget>.o to take the path relative to $(obj)")

from the kbuild tree and commits:

0f0727d971f6fdf ("drm/amd/display: readd -msse2 to prevent Clang from emitting libcalls to undefined SW FP routines")

^ this patch is now broken due to the SHA above it.

(quoted diff) +0 -0

b/drivers/gpu/drm/amd/display/dc/dcn20/Makefile
index 2b399cfa72e6..ddb8d5649e79 100644

drivers/gpu/drm/amd/display/dc/dcn20/Makefile +0 -0
@@ -19,7 +19,7 @@ endif
 CFLAGS_$(AMDDALPATH)/dc/dcn20/dcn20_resource.o := -mhard-float -msse

$(cc_stack_align)

ifdef CONFIG_CC_IS_CLANG
-CFLAGS_dcn20_resource.o += -msse2 +CFLAGS_$(AMDDALPATH)/dc/dcn20/dcn20_resource.o += -msse2
endif

AMD_DAL_DCN20 = $(addprefix $(AMDDALPATH)/dc/dcn20/,$(DCN20))

Quoted 34 lines

542816ff168d8a3 ("drm/amd/display: Add DCN2.1 changes to DML") b04641a3f4c54b0 ("drm/amd/display: Add Renoir DML") 057fc695e934a77 ("drm/amd/display: support "dummy pstate"")

from the drm tree.

I fixed it up (see below) and can carry the fix as necessary. This is now fixed as far as linux-next is concerned, but any non trivial conflicts should be mentioned to your upstream maintainer when your tree is submitted for merging. You may also want to consider cooperating with the maintainer of the conflicting tree to minimise any particularly complex conflicts.

drivers/gpu/drm/amd/display/dc/dml/Makefile +4 -0
diff --cc drivers/gpu/drm/amd/display/dc/dml/Makefile
index 83792e2c0f0e4,af2a864a6da05..0000000000000
@@@ -32,16 -32,29 +32,25 @@@ endi
 
  dml_ccflags := -mhard-float -msse $(cc_stack_align)
 
+ ifdef CONFIG_CC_IS_CLANG
+ dml_ccflags += -msse2
+ endif
+
 -CFLAGS_display_mode_lib.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/display_mode_lib.o := $(dml_ccflags)
 
  ifdef CONFIG_DRM_AMD_DC_DCN2_0
 -CFLAGS_display_mode_vba.o := $(dml_ccflags)
 -CFLAGS_display_mode_vba_20.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_calc_20.o := $(dml_ccflags)
 -CFLAGS_display_mode_vba_20v2.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_calc_20v2.o := $(dml_ccflags)

drivers/gpu/drm/amd/display/dc/dml/Makefile

Quoted 10 lines
drivers/gpu/drm/amd/display/dc/dml/Makefile +3 -0
 -endif
 +CFLAGS_$(AMDDALPATH)/dc/dml/display_mode_vba.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_mode_vba_20.o := $(dml_ccflags)
 +CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_rq_dlg_calc_20.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_mode_vba_20v2.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn20/display_rq_dlg_calc_20v2.o := $(dml_ccflags)
+ ifdef CONFIG_DRM_AMD_DC_DCN2_1
 -CFLAGS_display_mode_vba_21.o := $(dml_ccflags)
 -CFLAGS_display_rq_dlg_calc_21.o := $(dml_ccflags)
 -endif

^ this endif should not be removed.

Quoted 12 lines

-ifdef CONFIG_DRM_AMD_DCN3AG
-CFLAGS_display_mode_vba_3ag.o := $(dml_ccflags)
++CFLAGS_$(AMDDALPATH)/dc/dml/dcn21/display_mode_vba_21.o := $(dml_ccflags) ++CFLAGS_$(AMDDALPATH)/dc/dml/dcn21/display_rq_dlg_calc_21.o := $(dml_ccflags)
endif
-CFLAGS_dml1_display_rq_dlg_calc.o := $(dml_ccflags) -CFLAGS_display_rq_dlg_helpers.o := $(dml_ccflags) -CFLAGS_dml_common_defs.o := $(dml_ccflags) +CFLAGS_$(AMDDALPATH)/dc/dml/dml1_display_rq_dlg_calc.o := $(dml_ccflags) +CFLAGS_$(AMDDALPATH)/dc/dml/display_rq_dlg_helpers.o := $(dml_ccflags) +CFLAGS_$(AMDDALPATH)/dc/dml/dml_common_defs.o := $(dml_ccflags)

Quoted 2 lines
  DML = display_mode_lib.o display_rq_dlg_helpers.o dml1_display_rq_dlg_calc.o \
        dml_common_defs.o

--
Thanks,
~Nick Desaulniers

author maintainer
#2 lore raw
Quoted 5 lines · Nick Desaulniers
Quoted 1 line · Mark Brown

0f0727d971f6fdf ("drm/amd/display: readd -msse2 to prevent Clang from emitting libcalls to undefined SW FP routines")

^ this patch is now broken due to the SHA above it.

Right, all the sites that didn't conflict are broken. Like I say I think there needs to be some coordination with the Kbuild changes here.

drivers/gpu/drm/amd/display/dc/dcn20/Makefile endif · line 20

Quoted 7 lines

b/drivers/gpu/drm/amd/display/dc/dcn20/Makefile
index 2b399cfa72e6..ddb8d5649e79 100644

drivers/gpu/drm/amd/display/dc/dcn20/Makefile +0 -0
@@ -19,7 +19,7 @@ endif
 CFLAGS_$(AMDDALPATH)/dc/dcn20/dcn20_resource.o := -mhard-float -msse
 $(cc_stack_align)

I can't do anything with patches without signoffs so I'm not going to apply this as a workaround.

Quoted 6 lines
Quoted 4 lines

+ ifdef CONFIG_DRM_AMD_DC_DCN2_1 -CFLAGS_display_mode_vba_21.o := $(dml_ccflags) -CFLAGS_display_rq_dlg_calc_21.o := $(dml_ccflags) -endif

^ this endif should not be removed.

There's an endif left there? Someone sent a patch, I'm going to apply that.