On 1/11/19 2:12 PM, Noralf Trønnes wrote:
This switches to drm_atomic_helper_dirtyfb() as the framebuffer dirty
handler. All flushing will now happen in the pipe functions.

Also enable the damage plane property for all except repaper which can
only do full updates.

ili9225:
This change made ili9225_init() equal to mipi_dbi_init() so use it.

v2: Remove fb check in mipi_dbi_enable_flush() it can't be NULL
     (kbuild test robot)

Cc: David Lechner <da...@lechnology.com>
Cc: Eric Anholt <e...@anholt.net>
Signed-off-by: Noralf Trønnes <nor...@tronnes.org>
Acked-by: Sam Ravnborg <s...@ravnborg.org>
Acked-by: Daniel Vetter <daniel.vet...@ffwll.ch>
---


...

diff --git a/drivers/gpu/drm/tinydrm/st7586.c b/drivers/gpu/drm/tinydrm/st7586.c
index a52bc3b02606..50e370ce5a59 100644
--- a/drivers/gpu/drm/tinydrm/st7586.c
+++ b/drivers/gpu/drm/tinydrm/st7586.c
@@ -17,6 +17,7 @@
  #include <linux/spi/spi.h>
  #include <video/mipi_display.h>
+#include <drm/drm_damage_helper.h>
  #include <drm/drm_drv.h>
  #include <drm/drm_fb_cma_helper.h>
  #include <drm/drm_gem_cma_helper.h>
@@ -112,23 +113,15 @@ static int st7586_buf_copy(void *dst, struct 
drm_framebuffer *fb,
        return ret;
  }
-static int st7586_fb_dirty(struct drm_framebuffer *fb,
-                          struct drm_file *file_priv, unsigned int flags,
-                          unsigned int color, struct drm_clip_rect *clips,
-                          unsigned int num_clips)
+static void st7586_fb_dirty(struct drm_framebuffer *fb, struct drm_rect *rect)
  {
        struct tinydrm_device *tdev = fb->dev->dev_private;
        struct mipi_dbi *mipi = mipi_dbi_from_tinydrm(tdev);
-       struct drm_rect clip;
-       struct drm_rect *rect = &clip;

This function later modifies the fields of the struct pointed to by rect.
Are all callers of this function OK with having it modified or should we
make a local copy of rect and modify that instead?
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Reply via email to