|
22 | 22 | #include <drm/drm_fb_cma_helper.h> |
23 | 23 | #include <drm/drm_fourcc.h> |
24 | 24 | #include <drm/drm_gem_cma_helper.h> |
| 25 | +#include <drm/drm_gem_framebuffer_helper.h> |
25 | 26 | #include <drm/drm_plane.h> |
26 | 27 | #include <drm/drm_plane_helper.h> |
27 | 28 | #include <drm/drm_vblank.h> |
@@ -484,17 +485,27 @@ static void mxsfb_plane_overlay_atomic_update(struct drm_plane *plane, |
484 | 485 | writel(ctrl, mxsfb->base + LCDC_AS_CTRL); |
485 | 486 | } |
486 | 487 |
|
| 488 | +static bool mxsfb_format_mod_supported(struct drm_plane *plane, |
| 489 | + uint32_t format, |
| 490 | + uint64_t modifier) |
| 491 | +{ |
| 492 | + return modifier == DRM_FORMAT_MOD_LINEAR; |
| 493 | +} |
| 494 | + |
487 | 495 | static const struct drm_plane_helper_funcs mxsfb_plane_primary_helper_funcs = { |
| 496 | + .prepare_fb = drm_gem_fb_prepare_fb, |
488 | 497 | .atomic_check = mxsfb_plane_atomic_check, |
489 | 498 | .atomic_update = mxsfb_plane_primary_atomic_update, |
490 | 499 | }; |
491 | 500 |
|
492 | 501 | static const struct drm_plane_helper_funcs mxsfb_plane_overlay_helper_funcs = { |
| 502 | + .prepare_fb = drm_gem_fb_prepare_fb, |
493 | 503 | .atomic_check = mxsfb_plane_atomic_check, |
494 | 504 | .atomic_update = mxsfb_plane_overlay_atomic_update, |
495 | 505 | }; |
496 | 506 |
|
497 | 507 | static const struct drm_plane_funcs mxsfb_plane_funcs = { |
| 508 | + .format_mod_supported = mxsfb_format_mod_supported, |
498 | 509 | .update_plane = drm_atomic_helper_update_plane, |
499 | 510 | .disable_plane = drm_atomic_helper_disable_plane, |
500 | 511 | .destroy = drm_plane_cleanup, |
|
0 commit comments