drm/vc4: Move the buffer offset out of the vc4_plane_state
authorDave Stevenson <dave.stevenson@raspberrypi.com>
Mon, 25 Sep 2023 15:57:07 +0000 (16:57 +0100)
committerDom Cobley <popcornmix@gmail.com>
Mon, 19 Feb 2024 11:34:56 +0000 (11:34 +0000)
commitd15dbd44dee11937a107e66436215d25b7d7d9f9
treec87b07971d0b8d33e1d95e4f33d86e6f8a4465ad
parent7f213fb817a90f0cb5aba2ff7746816f4238534c
drm/vc4: Move the buffer offset out of the vc4_plane_state

The offset fields in vc4_plane_state are described as being
the offset for each buffer in the bo, however it is used to
store the complete DMA address that is then written into the
register.

The DMA address including the fb ofset  can be retrieved
using drm_fb_dma_get_gem_addr, and the offset adjustment due to
clipping is local to vc4_plane_mode_set.
Drop the offset field from the state, and compute the complete
DMA address in vc4_plane_mode_set.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
drivers/gpu/drm/vc4/vc4_drv.h
drivers/gpu/drm/vc4/vc4_plane.c