From: "Danilo Krummrich" <dakr@kernel.org>
To: <maarten.lankhorst@linux.intel.com>, <mripard@kernel.org>,
<tzimmermann@suse.de>, <airlied@gmail.com>, <simona@ffwll.ch>
Cc: dri-devel@lists.freedesktop.org,
"Alice Ryhl" <aliceryhl@google.com>,
"Christian König" <christian.koenig@amd.com>
Subject: Re: [PATCH] drm/test: drm_exec: use kzalloc() to allocate GEM objects
Date: Fri, 29 Aug 2025 18:03:54 +0200 [thread overview]
Message-ID: <DCF1EU09LIK8.24NDGBI967VSC@kernel.org> (raw)
In-Reply-To: <20250829075633.2306-1-dakr@kernel.org>
On Fri Aug 29, 2025 at 9:55 AM CEST, Danilo Krummrich wrote:
> Since commit e7fa80e2932c ("drm_gem: add mutex to drm_gem_object.gpuva")
> it is possible for test_prepare_array() to exceed a stack frame size of
> 2048 bytes depending on the exact configuration of the kernel.
>
> drivers/gpu/drm/tests/drm_exec_test.c: In function ‘test_prepare_array’:
> drivers/gpu/drm/tests/drm_exec_test.c:171:1: error: the frame size of 2128 bytes is larger than 2048 bytes [-Werror=frame-larger-than=]
> 171 | }
> | ^
> cc1: all warnings being treated as errors
> make[6]: *** [scripts/Makefile.build:287: drivers/gpu/drm/tests/drm_exec_test.o] Error 1
> make[6]: *** Waiting for unfinished jobs....
>
> In order to fix this, allocate the GEM objects in test_prepare_array()
> with kzalloc(), rather than placing them on the stack.
>
> Cc: Alice Ryhl <aliceryhl@google.com>
> Cc: Christian König <christian.koenig@amd.com>
> Fixes: e7fa80e2932c ("drm_gem: add mutex to drm_gem_object.gpuva")
> Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Applied to drm-misc-next, thanks!
[ Use kunit_kzalloc() instead of kzalloc(). - Danilo ]
prev parent reply other threads:[~2025-08-29 16:04 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-29 7:55 [PATCH] drm/test: drm_exec: use kzalloc() to allocate GEM objects Danilo Krummrich
2025-08-29 8:00 ` Nirmoy Das
2025-08-29 8:41 ` Alice Ryhl
2025-08-29 10:54 ` Christian König
2025-08-29 11:03 ` Danilo Krummrich
2025-08-29 16:03 ` Danilo Krummrich [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DCF1EU09LIK8.24NDGBI967VSC@kernel.org \
--to=dakr@kernel.org \
--cc=airlied@gmail.com \
--cc=aliceryhl@google.com \
--cc=christian.koenig@amd.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=simona@ffwll.ch \
--cc=tzimmermann@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.