search for: drm_atomic_helper_damage_merg

Displaying 18 results from an estimated 18 matches for "drm_atomic_helper_damage_merg".

2019 Dec 11
1
[PATCH 3/3] virtio-gpu: use damage info for display updates.
...io_gpu_framebuffer *vgfb; struct virtio_gpu_object *bo; + struct drm_rect rect; if (plane->state->crtc) output = drm_crtc_to_virtio_gpu_output(plane->state->crtc); @@ -146,12 +151,14 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane, return; } + if (!drm_atomic_helper_damage_merged(old_state, plane->state, &rect)) + return; + virtio_gpu_disable_notify(vgdev); - vgfb = to_virtio_gpu_framebuffer(plane->state->fb); - bo = gem_to_virtio_gpu_obj(vgfb->base.obj[0]); + bo = gem_to_virtio_gpu_obj(plane->state->fb->obj[0]); if (bo->dumb) - virtio_...
2023 Mar 20
0
[PATCH AUTOSEL 6.2 01/30] drm/cirrus: NULL-check pipe->plane.state->fb in cirrus_pipe_update()
.../drivers/gpu/drm/tiny/cirrus.c +++ b/drivers/gpu/drm/tiny/cirrus.c @@ -455,7 +455,7 @@ static void cirrus_pipe_update(struct drm_simple_display_pipe *pipe, if (state->fb && cirrus->cpp != cirrus_cpp(state->fb)) cirrus_mode_set(cirrus, &crtc->mode, state->fb); - if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + if (state->fb && drm_atomic_helper_damage_merged(old_state, state, &rect)) cirrus_fb_blit_rect(state->fb, &shadow_plane_state->data[0], &rect); } -- 2.39.2
2023 Mar 20
0
[PATCH AUTOSEL 6.1 01/29] drm/cirrus: NULL-check pipe->plane.state->fb in cirrus_pipe_update()
.../drivers/gpu/drm/tiny/cirrus.c +++ b/drivers/gpu/drm/tiny/cirrus.c @@ -455,7 +455,7 @@ static void cirrus_pipe_update(struct drm_simple_display_pipe *pipe, if (state->fb && cirrus->cpp != cirrus_cpp(state->fb)) cirrus_mode_set(cirrus, &crtc->mode, state->fb); - if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + if (state->fb && drm_atomic_helper_damage_merged(old_state, state, &rect)) cirrus_fb_blit_rect(state->fb, &shadow_plane_state->data[0], &rect); } -- 2.39.2
2023 Mar 20
0
[PATCH AUTOSEL 5.15 01/17] drm/cirrus: NULL-check pipe->plane.state->fb in cirrus_pipe_update()
.../drivers/gpu/drm/tiny/cirrus.c +++ b/drivers/gpu/drm/tiny/cirrus.c @@ -450,7 +450,7 @@ static void cirrus_pipe_update(struct drm_simple_display_pipe *pipe, if (state->fb && cirrus->cpp != cirrus_cpp(state->fb)) cirrus_mode_set(cirrus, &crtc->mode, state->fb); - if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + if (state->fb && drm_atomic_helper_damage_merged(old_state, state, &rect)) cirrus_fb_blit_rect(state->fb, &shadow_plane_state->data[0], &rect); } -- 2.39.2
2019 Dec 12
0
[PATCH v2 3/3] virtio-gpu: use damage info for display updates.
v2: remove shift by src_{x,y}, drm_atomic_helper_damage_merged() handles that for us (Chia-I Wu). Signed-off-by: Gerd Hoffmann <kraxel at redhat.com> --- drivers/gpu/drm/virtio/virtgpu_plane.c | 41 +++++++++++++++----------- 1 file changed, 24 insertions(+), 17 deletions(-) diff --git a/drivers/gpu/drm/virtio/virtgpu_plane.c b/drivers/gpu/drm/v...
2019 Apr 03
2
[PATCH] drm/cirrus: rewrite and modernize driver.
...pe *pipe, > > + struct drm_plane_state *old_state) > > +{ > > + struct drm_plane_state *state = pipe->plane.state; > > + struct drm_crtc *crtc = &pipe->crtc; > > + struct drm_rect rect; > > + > > + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) > > + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); > > + > > + if (crtc->state->event) { > > + spin_lock_irq(&crtc->dev->event_lock); > > + drm_crtc_send_vbl...
2019 Apr 03
2
[PATCH] drm/cirrus: rewrite and modernize driver.
...pe *pipe, > > + struct drm_plane_state *old_state) > > +{ > > + struct drm_plane_state *state = pipe->plane.state; > > + struct drm_crtc *crtc = &pipe->crtc; > > + struct drm_rect rect; > > + > > + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) > > + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); > > + > > + if (crtc->state->event) { > > + spin_lock_irq(&crtc->dev->event_lock); > > + drm_crtc_send_vbl...
2023 Feb 15
17
[PATCH 00/17] cirrus: Modernize the cirrus driver
Update the cirrus driver to follow current best practices. While the driver's hardware is obsolete, the cirrus driver is still one of the go-to modules to learn about writing a DRM driver. So keep it in good shape. Patches 1 to 3 simplify blitting and convert it to the DRM's current helpers. Patches 4 to 8 replace simple-KMS helpers with DRM's regular atomic helpers. The former are
2019 Apr 03
0
[PATCH] drm/cirrus: rewrite and modernize driver.
...; + struct drm_plane_state *old_state) >>> +{ >>> + struct drm_plane_state *state = pipe->plane.state; >>> + struct drm_crtc *crtc = &pipe->crtc; >>> + struct drm_rect rect; >>> + >>> + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) >>> + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); >>> + >>> + if (crtc->state->event) { >>> + spin_lock_irq(&crtc->dev->event_lock); >>> + dr...
2020 Feb 11
1
[PATCH] drm/virtio: rework batching
...s/gpu/drm/virtio/virtgpu_plane.c b/drivers/gpu/drm/virtio/virtgpu_plane.c index ac42c84d2d7f..fd6487fb0855 100644 --- a/drivers/gpu/drm/virtio/virtgpu_plane.c +++ b/drivers/gpu/drm/virtio/virtgpu_plane.c @@ -154,8 +154,6 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane, if (!drm_atomic_helper_damage_merged(old_state, plane->state, &rect)) return; - virtio_gpu_disable_notify(vgdev); - bo = gem_to_virtio_gpu_obj(plane->state->fb->obj[0]); if (bo->dumb) virtio_gpu_update_dumb_bo(vgdev, plane->state, &rect); @@ -187,7 +185,7 @@ static void virtio_gpu_primary_plane_...
2020 Feb 12
1
[PATCH v2] drm/virtio: rework batching
...s/gpu/drm/virtio/virtgpu_plane.c b/drivers/gpu/drm/virtio/virtgpu_plane.c index ac42c84d2d7f..fd6487fb0855 100644 --- a/drivers/gpu/drm/virtio/virtgpu_plane.c +++ b/drivers/gpu/drm/virtio/virtgpu_plane.c @@ -154,8 +154,6 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane, if (!drm_atomic_helper_damage_merged(old_state, plane->state, &rect)) return; - virtio_gpu_disable_notify(vgdev); - bo = gem_to_virtio_gpu_obj(plane->state->fb->obj[0]); if (bo->dumb) virtio_gpu_update_dumb_bo(vgdev, plane->state, &rect); @@ -187,7 +185,7 @@ static void virtio_gpu_primary_plane_...
2020 Feb 13
0
[PATCH v3 1/4] drm/virtio: rework notification for better batching
...s/gpu/drm/virtio/virtgpu_plane.c b/drivers/gpu/drm/virtio/virtgpu_plane.c index d1c3f5fbfee4..08b2e4127eb3 100644 --- a/drivers/gpu/drm/virtio/virtgpu_plane.c +++ b/drivers/gpu/drm/virtio/virtgpu_plane.c @@ -154,8 +154,6 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane, if (!drm_atomic_helper_damage_merged(old_state, plane->state, &rect)) return; - virtio_gpu_disable_notify(vgdev); - bo = gem_to_virtio_gpu_obj(plane->state->fb->obj[0]); if (bo->dumb) virtio_gpu_update_dumb_bo(vgdev, plane->state, &rect); @@ -186,8 +184,6 @@ static void virtio_gpu_primary_plane_...
2020 Feb 14
0
[PATCH v4 1/6] drm/virtio: rework notification for better batching
...s/gpu/drm/virtio/virtgpu_plane.c b/drivers/gpu/drm/virtio/virtgpu_plane.c index d1c3f5fbfee4..08b2e4127eb3 100644 --- a/drivers/gpu/drm/virtio/virtgpu_plane.c +++ b/drivers/gpu/drm/virtio/virtgpu_plane.c @@ -154,8 +154,6 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane, if (!drm_atomic_helper_damage_merged(old_state, plane->state, &rect)) return; - virtio_gpu_disable_notify(vgdev); - bo = gem_to_virtio_gpu_obj(plane->state->fb->obj[0]); if (bo->dumb) virtio_gpu_update_dumb_bo(vgdev, plane->state, &rect); @@ -186,8 +184,6 @@ static void virtio_gpu_primary_plane_...
2019 Apr 04
1
[PATCH v2 6/6] drm/cirrus: rewrite and modernize driver.
...ate = pipe->plane.state; + struct drm_crtc *crtc = &pipe->crtc; + struct drm_rect rect; + + if (pipe->plane.state->fb && + cirrus->cpp != cirrus_cpp(pipe->plane.state->fb)) + cirrus_mode_set(cirrus, &crtc->mode, + pipe->plane.state->fb); + + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); + + if (crtc->state->event) { + spin_lock_irq(&crtc->dev->event_lock); + drm_crtc_send_vblank_event(crtc, crtc->state->event); + spin_unlock_irq(&crtc->dev->event_lock)...
2019 Apr 03
5
[PATCH] drm/cirrus: rewrite and modernize driver.
...tate); + cirrus_fb_blit_fullscreen(plane_state->fb); +} + +void cirrus_pipe_update(struct drm_simple_display_pipe *pipe, + struct drm_plane_state *old_state) +{ + struct drm_plane_state *state = pipe->plane.state; + struct drm_crtc *crtc = &pipe->crtc; + struct drm_rect rect; + + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); + + if (crtc->state->event) { + spin_lock_irq(&crtc->dev->event_lock); + drm_crtc_send_vblank_event(crtc, crtc->state->event); + spin_unlock_irq(&crtc->dev->event_lock)...
2019 Apr 03
5
[PATCH] drm/cirrus: rewrite and modernize driver.
...tate); + cirrus_fb_blit_fullscreen(plane_state->fb); +} + +void cirrus_pipe_update(struct drm_simple_display_pipe *pipe, + struct drm_plane_state *old_state) +{ + struct drm_plane_state *state = pipe->plane.state; + struct drm_crtc *crtc = &pipe->crtc; + struct drm_rect rect; + + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); + + if (crtc->state->event) { + spin_lock_irq(&crtc->dev->event_lock); + drm_crtc_send_vblank_event(crtc, crtc->state->event); + spin_unlock_irq(&crtc->dev->event_lock)...
2019 Apr 03
0
[PATCH] drm/cirrus: rewrite and modernize driver.
...update(struct drm_simple_display_pipe *pipe, > + struct drm_plane_state *old_state) > +{ > + struct drm_plane_state *state = pipe->plane.state; > + struct drm_crtc *crtc = &pipe->crtc; > + struct drm_rect rect; > + > + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) > + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); > + > + if (crtc->state->event) { > + spin_lock_irq(&crtc->dev->event_lock); > + drm_crtc_send_vblank_event(crtc, crtc->...
2019 Apr 05
1
[PATCH v3 5/5] drm/cirrus: rewrite and modernize driver.
...ate = pipe->plane.state; + struct drm_crtc *crtc = &pipe->crtc; + struct drm_rect rect; + + if (pipe->plane.state->fb && + cirrus->cpp != cirrus_cpp(pipe->plane.state->fb)) + cirrus_mode_set(cirrus, &crtc->mode, + pipe->plane.state->fb); + + if (drm_atomic_helper_damage_merged(old_state, state, &rect)) + cirrus_fb_blit_rect(pipe->plane.state->fb, &rect); + + if (crtc->state->event) { + spin_lock_irq(&crtc->dev->event_lock); + drm_crtc_send_vblank_event(crtc, crtc->state->event); + crtc->state->event = NULL; + spin_unlock_i...