Lines Matching full:planes
3 * R-Car Display Unit Planes
33 * The core idea is to avoid using a free planes bitmask that would need to be
36 * over all plane states to compute the free planes bitmask, allocates hardware
37 * planes based on that bitmask, and stores the result back in the plane states.
39 * For this to work we need to access the current state of planes not touched by
41 * planes using drm_atomic_get_plane_state(). This effectively serializes atomic
55 * Lowering the number of planes doesn't strictly require reallocation in rcar_du_plane_needs_realloc()
60 old_state->format->planes != new_state->format->planes) in rcar_du_plane_needs_realloc()
63 /* Reallocate hardware planes if the source has changed. */ in rcar_du_plane_needs_realloc()
78 if (state->format->planes == 2) in rcar_du_plane_hwmask()
90 * and allocate planes in reverse index order otherwise to ensure maximum
91 * availability of planes 0 and 1.
100 unsigned int num_planes = state->format->planes; in rcar_du_plane_hwalloc()
142 /* Check if hardware planes need to be reallocated. */ in rcar_du_atomic_check_planes()
155 plane->group->index, plane - plane->group->planes); in rcar_du_atomic_check_planes()
165 index = plane - plane->group->planes; in rcar_du_atomic_check_planes()
181 index = plane - plane->group->planes; in rcar_du_atomic_check_planes()
196 * Compute the used planes mask for each group at the same time to avoid in rcar_du_atomic_check_planes()
197 * looping over the planes separately later. in rcar_du_atomic_check_planes()
204 dev_dbg(rcdu->dev, "%s: finding free planes for group %u\n", in rcar_du_atomic_check_planes()
208 struct rcar_du_plane *plane = &group->planes[i]; in rcar_du_atomic_check_planes()
218 * hardware planes must not be added to the used planes in rcar_du_atomic_check_planes()
221 * above. Use the local freed planes list to check for in rcar_du_atomic_check_planes()
228 plane - plane->group->planes); in rcar_du_atomic_check_planes()
238 plane - plane->group->planes, in rcar_du_atomic_check_planes()
240 new_plane_state->format->planes : 0, in rcar_du_atomic_check_planes()
247 dev_dbg(rcdu->dev, "%s: group %u free planes mask 0x%02x\n", in rcar_du_atomic_check_planes()
251 /* Reallocate hardware planes for each plane that needs it. */ in rcar_du_atomic_check_planes()
266 plane->group->index, plane - plane->group->planes); in rcar_du_atomic_check_planes()
269 * Skip planes that are being disabled or don't need to be in rcar_du_atomic_check_planes()
277 * Try to allocate the plane from the free planes currently in rcar_du_atomic_check_planes()
280 * allocating from all free planes. in rcar_du_atomic_check_planes()
299 __func__, new_plane_state->format->planes, idx); in rcar_du_atomic_check_planes()
306 dev_dbg(rcdu->dev, "%s: group %u free planes mask 0x%02x\n", in rcar_du_atomic_check_planes()
347 if (state->format->planes == 2) in rcar_du_plane_setup_scanout()
352 for (i = 0; i < state->format->planes; ++i) { in rcar_du_plane_setup_scanout()
389 if (state->format->planes == 2) { in rcar_du_plane_setup_scanout()
481 if (state->format->planes == 2) { in rcar_du_plane_setup_format_gen2()
523 * On Gen3, some DU channels have two planes, each being wired to a in rcar_du_plane_setup_format_gen3()
524 * separate VSPD instance. The DU can then blend two planes. While in rcar_du_plane_setup_format_gen3()
526 * blending (such as incorrect colors or planes being invisible) may in rcar_du_plane_setup_format_gen3()
567 if (state->format->planes == 2) in __rcar_du_plane_setup()
794 * planes. in rcar_du_planes_init()
804 struct rcar_du_plane *plane = &rgrp->planes[i]; in rcar_du_planes_init()