gallium: fix ddebug and noop screen caps init

Fixes: a036231c09 ("gallium: add u_init_pipe_screen_caps")
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33176>
(cherry picked from commit 2af8172b62)
This commit is contained in:
Qiang Yu 2025-01-22 11:15:56 +08:00 committed by Eric Engestrom
parent 59865a1b1e
commit ebe6878a6a
3 changed files with 7 additions and 1 deletions

View file

@ -1394,7 +1394,7 @@
"description": "gallium: fix ddebug and noop screen caps init",
"nominated": true,
"nomination_type": 2,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": "a036231c096a6dec717e0e3c6b85a83a29c50723",
"notes": null

View file

@ -679,6 +679,9 @@ ddebug_screen_create(struct pipe_screen *screen)
SCR_INIT(vertex_state_destroy);
dscreen->base.get_driver_pipe_screen = dd_get_driver_pipe_screen;
/* copy all caps */
*(struct pipe_caps *)&dscreen->base.caps = screen->caps;
#undef SCR_INIT
dscreen->screen = screen;

View file

@ -831,6 +831,9 @@ struct pipe_screen *noop_screen_create(struct pipe_screen *oscreen)
screen->query_compression_modifiers = noop_query_compression_modifiers;
screen->get_driver_pipe_screen = noop_get_driver_pipe_screen;
/* copy all caps */
*(struct pipe_caps *)&screen->caps = oscreen->caps;
slab_create_parent(&noop_screen->pool_transfers,
sizeof(struct pipe_transfer), 64);