From 7b2007715830ff42717bbfe9e45fb70a499a646a Mon Sep 17 00:00:00 2001 From: Hawking Zhang Date: Thu, 16 Apr 2026 20:42:52 +0800 Subject: [PATCH] drm/amd/display: use GNU make rwildcard instead of find MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace external find calls with GNU Make’s $(rwildcard …) to collect files. Depending on ‘find’ can fail if it’s unavailable or returns no matches, which left CFLAGS_* unset. In that case, floating-point code was built with -mno-sse, leading to build failures. Signed-off-by: Hawking Zhang Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/dml2_0/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dml2_0/Makefile b/drivers/gpu/drm/amd/display/dc/dml2_0/Makefile index 5388bf094fbc..b3e23dbf2ebf 100644 --- a/drivers/gpu/drm/amd/display/dc/dml2_0/Makefile +++ b/drivers/gpu/drm/amd/display/dc/dml2_0/Makefile @@ -62,7 +62,8 @@ subdir-ccflags-y += -I$(FULL_AMD_DISPLAY_PATH)/dc/dml2_0/dml21/src/dml2_cga/ THIS_MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST))) DML2_ABS_PATH := $(patsubst %/,%,$(dir $(THIS_MAKEFILE_PATH))) -DML2_C_FILES := $(shell find $(DML2_ABS_PATH) -name '*.c') +rwildcard = $(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$(2)) $(filter $(subst *,%,$(2)),$d)) +DML2_C_FILES := $(call rwildcard,$(DML2_ABS_PATH)/,*.c) # FPU flags step 2: Convert to .o and make paths relative to $(AMDDALPATH)/dc/dml2_0/ DML2_RELATIVE_O_FILES := $(patsubst $(DML2_ABS_PATH)/%,dc/dml2_0/%,$(patsubst %.c,%.o,$(DML2_C_FILES)))