asahi: Flip kmsro around to allocate on the GPU
authorAsahi Lina <lina@asahilina.net>
Wed, 5 Apr 2023 12:41:27 +0000 (21:41 +0900)
committerMarge Bot <emma+marge@anholt.net>
Fri, 7 Apr 2023 03:23:04 +0000 (03:23 +0000)
commit534a04d557f3e2022b23821368ae06f2f746c9d8
tree2e004916b8872e8c983f8a2b3f1b84ea4f5b7622
parent9db36376a687c103a5405c34fa1bd31a0371ed2a
asahi: Flip kmsro around to allocate on the GPU

Our display controller can handle arbitrary GPU imports, so there is no
reason to use dumb KMS buffers. Allocate everything on the GPU instead.

This also allows us to be lazy about mapping things to the KMS side, so
only clients that really want a KMS handle actually do that, which stops
us from ending up with a bunch of junk mapped to DCP (e.g. X11 clients
always request SCANOUT even under XWayland).

Signed-off-by: Asahi Lina <lina@asahilina.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22353>
src/gallium/drivers/asahi/agx_pipe.c
src/gallium/winsys/kmsro/drm/kmsro_drm_winsys.c