Lines Matching refs:format

52 static size_t gud_xrgb8888_to_r124(u8 *dst, const struct drm_format_info *format,  in gud_xrgb8888_to_r124()  argument
57 unsigned int block_width = drm_format_info_block_width(format, 0); in gud_xrgb8888_to_r124()
65 WARN_ON_ONCE(format->char_per_block[0] != 1); in gud_xrgb8888_to_r124()
71 len = drm_format_info_min_pitch(format, 0, width) * height; in gud_xrgb8888_to_r124()
102 static size_t gud_xrgb8888_to_color(u8 *dst, const struct drm_format_info *format, in gud_xrgb8888_to_color() argument
106 unsigned int block_width = drm_format_info_block_width(format, 0); in gud_xrgb8888_to_color()
117 len = drm_format_info_min_pitch(format, 0, width) * drm_rect_height(rect); in gud_xrgb8888_to_color()
137 switch (format->format) { in gud_xrgb8888_to_color()
155 const struct drm_format_info *format, struct drm_rect *rect, in gud_prep_flush() argument
164 pitch = drm_format_info_min_pitch(format, 0, drm_rect_width(rect)); in gud_prep_flush()
181 if (format != fb->format) { in gud_prep_flush()
182 if (format->format == GUD_DRM_FORMAT_R1) { in gud_prep_flush()
183 len = gud_xrgb8888_to_r124(buf, format, vaddr, fb, rect, fmtcnv_state); in gud_prep_flush()
186 } else if (format->format == DRM_FORMAT_R8) { in gud_prep_flush()
188 } else if (format->format == DRM_FORMAT_RGB332) { in gud_prep_flush()
190 } else if (format->format == DRM_FORMAT_RGB565) { in gud_prep_flush()
198 } else if (format->format == DRM_FORMAT_RGB888) { in gud_prep_flush()
201 len = gud_xrgb8888_to_color(buf, format, vaddr, fb, rect); in gud_prep_flush()
203 } else if (gud_is_big_endian() && format->cpp[0] > 1) { in gud_prep_flush()
276 const struct drm_format_info *format, struct drm_rect *rect, in gud_flush_rect() argument
285 ret = gud_prep_flush(gdrm, fb, src, cached_reads, format, rect, &req, fmtcnv_state); in gud_flush_rect()
330 const struct drm_format_info *format; in gud_flush_damage() local
335 format = fb->format; in gud_flush_damage()
336 if (format->format == DRM_FORMAT_XRGB8888 && gdrm->xrgb8888_emulation_format) in gud_flush_damage()
337 format = gdrm->xrgb8888_emulation_format; in gud_flush_damage()
340 pitch = drm_format_info_min_pitch(format, 0, drm_rect_width(damage)); in gud_flush_damage()
352 ret = gud_flush_rect(gdrm, fb, src, cached_reads, format, &rect, &fmtcnv_state); in gud_flush_damage()
412 iosys_map_incr(&shadow_map, drm_fb_clip_offset(fb->pitches[0], fb->format, damage)); in gud_fb_queue_damage()
465 const struct drm_format_info *format = fb->format; in gud_pipe_check() local
478 if (old_fb && old_fb->format != format) in gud_pipe_check()
488 if (format->format == DRM_FORMAT_XRGB8888 && gdrm->xrgb8888_emulation_format) in gud_pipe_check()
489 format = gdrm->xrgb8888_emulation_format; in gud_pipe_check()
524 req->format = gud_from_fourcc(format->format); in gud_pipe_check()
525 if (WARN_ON_ONCE(!req->format)) { in gud_pipe_check()