Lines Matching full:fb

95 	struct drm_framebuffer *fb = state->fb;  in drm_plane_state_to_eba()  local
100 cma_obj = drm_fb_cma_get_gem_obj(fb, plane); in drm_plane_state_to_eba()
103 return cma_obj->paddr + fb->offsets[plane] + fb->pitches[plane] * y + in drm_plane_state_to_eba()
104 fb->format->cpp[plane] * x; in drm_plane_state_to_eba()
110 struct drm_framebuffer *fb = state->fb; in drm_plane_state_to_ubo() local
116 cma_obj = drm_fb_cma_get_gem_obj(fb, 1); in drm_plane_state_to_ubo()
119 x /= fb->format->hsub; in drm_plane_state_to_ubo()
120 y /= fb->format->vsub; in drm_plane_state_to_ubo()
122 return cma_obj->paddr + fb->offsets[1] + fb->pitches[1] * y + in drm_plane_state_to_ubo()
123 fb->format->cpp[1] * x - eba; in drm_plane_state_to_ubo()
129 struct drm_framebuffer *fb = state->fb; in drm_plane_state_to_vbo() local
135 cma_obj = drm_fb_cma_get_gem_obj(fb, 2); in drm_plane_state_to_vbo()
138 x /= fb->format->hsub; in drm_plane_state_to_vbo()
139 y /= fb->format->vsub; in drm_plane_state_to_vbo()
141 return cma_obj->paddr + fb->offsets[2] + fb->pitches[2] * y + in drm_plane_state_to_vbo()
142 fb->format->cpp[2] * x - eba; in drm_plane_state_to_vbo()
205 switch (ipu_plane->base.state->fb->format->format) { in ipu_plane_separate_alpha()
352 struct drm_framebuffer *fb = state->fb; in ipu_plane_atomic_check() local
353 struct drm_framebuffer *old_fb = old_state->fb; in ipu_plane_atomic_check()
359 if (!fb) in ipu_plane_atomic_check()
407 fb->format != old_fb->format)) in ipu_plane_atomic_check()
415 if (fb->pitches[0] < 1 || fb->pitches[0] > 16384) in ipu_plane_atomic_check()
418 if (old_fb && fb->pitches[0] != old_fb->pitches[0]) in ipu_plane_atomic_check()
421 switch (fb->format->format) { in ipu_plane_atomic_check()
441 if (old_fb && (fb->format == old_fb->format)) { in ipu_plane_atomic_check()
447 if (fb->pitches[1] != fb->pitches[2]) in ipu_plane_atomic_check()
458 if (old_fb && (fb->format == old_fb->format)) { in ipu_plane_atomic_check()
464 if (fb->pitches[1] < 1 || fb->pitches[1] > 16384) in ipu_plane_atomic_check()
467 if (old_fb && old_fb->pitches[1] != fb->pitches[1]) in ipu_plane_atomic_check()
474 if (((state->src.x1 >> 16) & (fb->format->hsub - 1)) || in ipu_plane_atomic_check()
475 ((state->src.y1 >> 16) & (fb->format->vsub - 1))) in ipu_plane_atomic_check()
488 if (fb->pitches[1] < 1 || fb->pitches[1] > 16384) in ipu_plane_atomic_check()
491 if (old_fb && old_fb->pitches[1] != fb->pitches[1]) in ipu_plane_atomic_check()
551 struct drm_framebuffer *fb = state->fb; in ipu_plane_atomic_update() local
569 !fb->format->has_alpha, 0xff, in ipu_plane_atomic_update()
578 !fb->format->has_alpha, 0xff, in ipu_plane_atomic_update()
595 fb->pitches[0], fb->format->format, in ipu_plane_atomic_update()
596 fb->modifier, &eba); in ipu_plane_atomic_update()
599 if (old_state->fb && !drm_atomic_crtc_needs_modeset(crtc_state)) { in ipu_plane_atomic_update()
615 ics = ipu_drm_fourcc_to_colorspace(fb->format->format); in ipu_plane_atomic_update()
630 info = drm_format_info(fb->format->format); in ipu_plane_atomic_update()
631 ipu_calculate_bursts(width, info->cpp[0], fb->pitches[0], in ipu_plane_atomic_update()
636 ipu_cpmem_set_fmt(ipu_plane->ipu_ch, fb->format->format); in ipu_plane_atomic_update()
641 ipu_cpmem_set_stride(ipu_plane->ipu_ch, fb->pitches[0]); in ipu_plane_atomic_update()
644 switch (fb->format->format) { in ipu_plane_atomic_update()
653 if (fb->format->format == DRM_FORMAT_YVU420 || in ipu_plane_atomic_update()
654 fb->format->format == DRM_FORMAT_YVU422 || in ipu_plane_atomic_update()
655 fb->format->format == DRM_FORMAT_YVU444) in ipu_plane_atomic_update()
659 fb->pitches[1], ubo, vbo); in ipu_plane_atomic_update()
670 fb->pitches[1], ubo, ubo); in ipu_plane_atomic_update()
697 ipu_cpmem_set_stride(ipu_plane->alpha_ch, fb->pitches[1]); in ipu_plane_atomic_update()
773 if (!plane_state->fb) { in ipu_planes_assign_pre()
778 if (!(plane_state->fb->flags & DRM_MODE_FB_MODIFIERS) || in ipu_planes_assign_pre()
779 plane_state->fb->modifier == DRM_FORMAT_MOD_LINEAR) in ipu_planes_assign_pre()
786 plane_state->fb->format->format, in ipu_planes_assign_pre()
787 plane_state->fb->modifier)) in ipu_planes_assign_pre()
798 if (!plane_state->fb) { in ipu_planes_assign_pre()
803 if ((plane_state->fb->flags & DRM_MODE_FB_MODIFIERS) && in ipu_planes_assign_pre()
804 plane_state->fb->modifier != DRM_FORMAT_MOD_LINEAR) in ipu_planes_assign_pre()
808 plane_state->fb->modifier = DRM_FORMAT_MOD_LINEAR; in ipu_planes_assign_pre()
812 plane_state->fb->format->format, in ipu_planes_assign_pre()
813 plane_state->fb->modifier)) { in ipu_planes_assign_pre()