Lines Matching full:fb

54 static inline bool dcss_plane_fb_is_linear(const struct drm_framebuffer *fb)  in dcss_plane_fb_is_linear()  argument
56 return ((fb->flags & DRM_MODE_FB_MODIFIERS) == 0) || in dcss_plane_fb_is_linear()
57 ((fb->flags & DRM_MODE_FB_MODIFIERS) != 0 && in dcss_plane_fb_is_linear()
58 fb->modifier == DRM_FORMAT_MOD_LINEAR); in dcss_plane_fb_is_linear()
148 struct drm_framebuffer *fb = new_plane_state->fb; in dcss_plane_atomic_check() local
156 if (!fb || !new_plane_state->crtc) in dcss_plane_atomic_check()
159 dma_obj = drm_fb_dma_get_gem_obj(fb, 0); in dcss_plane_atomic_check()
170 fb->format->format)) { in dcss_plane_atomic_check()
187 if (!dcss_plane_can_rotate(fb->format, in dcss_plane_atomic_check()
188 !!(fb->flags & DRM_MODE_FB_MODIFIERS), in dcss_plane_atomic_check()
189 fb->modifier, in dcss_plane_atomic_check()
198 !dcss_plane_fb_is_linear(fb)) { in dcss_plane_atomic_check()
203 if ((fb->flags & DRM_MODE_FB_MODIFIERS) && in dcss_plane_atomic_check()
205 fb->format->format, in dcss_plane_atomic_check()
206 fb->modifier)) { in dcss_plane_atomic_check()
207 DRM_DEBUG_KMS("Invalid modifier: %llx", fb->modifier); in dcss_plane_atomic_check()
219 struct drm_framebuffer *fb = state->fb; in dcss_plane_atomic_set_base() local
220 const struct drm_format_info *format = fb->format; in dcss_plane_atomic_set_base()
221 struct drm_gem_dma_object *dma_obj = drm_fb_dma_get_gem_obj(fb, 0); in dcss_plane_atomic_set_base()
227 p1_ba = dma_obj->dma_addr + fb->offsets[0] + in dcss_plane_atomic_set_base()
228 fb->pitches[0] * (state->src.y1 >> 16) + in dcss_plane_atomic_set_base()
234 p1_ba = dma_obj->dma_addr + fb->offsets[0] + in dcss_plane_atomic_set_base()
235 fb->pitches[0] * (state->src.y1 >> 16) + in dcss_plane_atomic_set_base()
240 p2_ba = dma_obj->dma_addr + fb->offsets[1] + in dcss_plane_atomic_set_base()
241 (((fb->pitches[1] >> 1) * (state->src.y1 >> 17) + in dcss_plane_atomic_set_base()
245 fb->pitches[0]); in dcss_plane_atomic_set_base()
251 struct drm_framebuffer *fb = state->fb; in dcss_plane_needs_setup() local
252 struct drm_framebuffer *old_fb = old_state->fb; in dcss_plane_needs_setup()
262 fb->format->format != old_fb->format->format || in dcss_plane_needs_setup()
263 fb->modifier != old_fb->modifier || in dcss_plane_needs_setup()
277 struct drm_framebuffer *fb = new_state->fb; in dcss_plane_atomic_update() local
285 if (!fb || !new_state->crtc || !new_state->visible) in dcss_plane_atomic_update()
289 modifiers_present = !!(fb->flags & DRM_MODE_FB_MODIFIERS); in dcss_plane_atomic_update()
291 if (old_state->fb && !drm_atomic_crtc_needs_modeset(crtc_state) && in dcss_plane_atomic_update()
309 modifiers_present && fb->modifier == DRM_FORMAT_MOD_LINEAR) in dcss_plane_atomic_update()
313 new_state->fb->format, in dcss_plane_atomic_update()
314 modifiers_present ? fb->modifier : in dcss_plane_atomic_update()
329 new_state->fb->format, in dcss_plane_atomic_update()
338 fb->format, new_state->alpha >> 8); in dcss_plane_atomic_update()