Subject: Re: linux-next: build failure after merge of the amdgpu tree

From: Rodrigo Siqueira Jordao <[email-masked]>
Date: Tue, 10 Oct 2023 15:14:46 -0600

On 10/9/23 19:43, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the amdgpu tree, today's linux-next build (x86_64
> allmodconfig) failed like this:
> 
> drivers/gpu/drm/amd/amdgpu/../display/dc/dml2/display_mode_core.c: In function 'dml_core_mode_support':
> drivers/gpu/drm/amd/amdgpu/../display/dc/dml2/display_mode_core.c:8229:1: error: the frame size of 2736 bytes is larger than 2048 bytes [-Werror=frame-larger-than=]
>   8229 | } // dml_core_mode_support
>        | ^
> cc1: all warnings being treated as errors
> 
> Caused by commit
> 
>    7966f319c66d ("drm/amd/display: Introduce DML2")
> 
> (or maybe something later that changed storage size).
> 
> I have used the amdgpu tree from next-20231009 for today.
> 

Hi Stephen,
(+ others)

I think I have a fix for that, but some things are unclear to me. I'm 
only able to see this issue when using allmodconfig. Additionally, when 
I inspected the function, it had a few local variables, not enough to 
explode the stack size fwiu. Is there any option in the allmodconfig 
that makes it easy to see this issue? Maybe something that I'm missing 
in my custom config file? Is it possible that allmodconfig enables some 
option that might increase the stack size? Perhaps the FPU flags from 
GCC include something else in the stack?

Also, for investigating this issue, I'm considering the local variables, 
but as you can see from dml_core_mode_support, it has a few pointers. Am 
I missing something?

P.s.: I was able to fix this issue by splitting two operations from the 
original function.

Thanks
Siqueira