]> git.baikalelectronics.ru Git - kernel.git/commit
drm/vc4: plane: Prevent async update if we don't have a dlist
authorMaxime Ripard <maxime@cerno.tech>
Fri, 10 Jun 2022 11:51:36 +0000 (13:51 +0200)
committerMaxime Ripard <maxime@cerno.tech>
Thu, 16 Jun 2022 09:07:51 +0000 (11:07 +0200)
commit050ade6dbca014e6011e5f3fc2efb54571b935e4
treebfcd59a5ded39c70f9d1cc276d23b87124ad4b16
parent37803cb6508fe10f3dfd35f28096efc77d28443a
drm/vc4: plane: Prevent async update if we don't have a dlist

The vc4 planes are setup in hardware by creating a hardware descriptor
in a dedicated RAM. As part of the process to setup a plane in KMS, we
thus need to allocate some part of that dedicated RAM to store our
descriptor there.

The async update path will just reuse the descriptor already allocated
for that plane and will modify it directly in RAM to match whatever has
been asked for.

In order to do that, it will compare the descriptor for the old plane
state and the new plane state, will make sure they fit in the same size,
and check that only the position or buffer address have changed.

Reviewed-by: Melissa Wen <mwen@igalia.com>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20220610115149.964394-2-maxime@cerno.tech
drivers/gpu/drm/vc4/vc4_plane.c