search for: drm_crtc_vblank_put

Displaying 20 results from an estimated 32 matches for "drm_crtc_vblank_put".

Did you mean: drm_crtc_vblank_get
2016 Jun 07
0
[PATCH 01/10] drm/nouveau: replace legacy vblank helpers
...drm_crtc_vblank_get(crtc); /* Emit a page flip */ if (drm->device.info.family >= NV_DEVICE_INFO_V0_TESLA) { @@ -810,7 +809,7 @@ nouveau_crtc_page_flip(struct drm_crtc *crtc, struct drm_framebuffer *fb, return 0; fail_unreserve: - drm_vblank_put(dev, nouveau_crtc(crtc)->index); + drm_crtc_vblank_put(crtc); ttm_bo_unreserve(&old_bo->bo); fail_unpin: mutex_unlock(&cli->mutex); @@ -842,17 +841,17 @@ nouveau_finish_page_flip(struct nouveau_channel *chan, s = list_first_entry(&fctx->flip, struct nouveau_page_flip_state, head); if (s->event) { if (drm->device.i...
2017 Jan 16
4
[PATCH 3/4] drm/amd/display: Switch to using atomic_helper for flip.
...g legacy flip\n", > - crtc->base.id); > - ret = -EINVAL; > - goto fail; > - } > - acrtc->flip_flags = flags; > - > - ret = drm_atomic_nonblocking_commit(state); > - > -fail: > - if (ret == -EDEADLK) > - goto backoff; > - > - if (ret) > - drm_crtc_vblank_put(crtc); > - > - drm_atomic_state_put(state); > - > - return ret; > -backoff: > - drm_atomic_state_clear(state); > - drm_atomic_legacy_backoff(state); > - > - /* > - * Someone might have exchanged the framebuffer while we dropped locks > - * in the backoff code. We...
2016 Sep 23
0
[PATCH] drivers: drm: nouveau: Fix brace coding style error
.../gpu/drm/nouveau/nouveau_display.c index afbf557..0d39e17 100644 --- a/drivers/gpu/drm/nouveau/nouveau_display.c +++ b/drivers/gpu/drm/nouveau/nouveau_display.c @@ -851,8 +851,7 @@ nouveau_finish_page_flip(struct nouveau_channel *chan, /* Give up ownership of vblank for page-flipped crtc */ drm_crtc_vblank_put(s->crtc); } - } - else { + } else { /* Give up ownership of vblank for page-flipped crtc */ drm_crtc_vblank_put(s->crtc); } -- 2.10.0
2016 Jun 06
4
[PATCH 01/14] drm/nouveau: use drm_crtc_send_vblank_event() v2
From: Gustavo Padovan <gustavo.padovan at collabora.co.uk> Replace the legacy drm_send_vblank_event() with the new helper function. v2: add crtc to nouveau_page_flip_state (comment from Mario Kleiner) Cc: Mario Kleiner <mario.kleiner.de at gmail.com> Signed-off-by: Gustavo Padovan <gustavo.padovan at collabora.co.uk> --- drivers/gpu/drm/nouveau/nouveau_display.c | 19
2016 Jun 06
4
[PATCH 01/14] drm/nouveau: use drm_crtc_send_vblank_event() v2
From: Gustavo Padovan <gustavo.padovan at collabora.co.uk> Replace the legacy drm_send_vblank_event() with the new helper function. v2: add crtc to nouveau_page_flip_state (comment from Mario Kleiner) Cc: Mario Kleiner <mario.kleiner.de at gmail.com> Signed-off-by: Gustavo Padovan <gustavo.padovan at collabora.co.uk> --- drivers/gpu/drm/nouveau/nouveau_display.c | 19
2016 Jun 06
4
[PATCH 01/14] drm/nouveau: use drm_crtc_send_vblank_event() v2
From: Gustavo Padovan <gustavo.padovan at collabora.co.uk> Replace the legacy drm_send_vblank_event() with the new helper function. v2: add crtc to nouveau_page_flip_state (comment from Mario Kleiner) Cc: Mario Kleiner <mario.kleiner.de at gmail.com> Signed-off-by: Gustavo Padovan <gustavo.padovan at collabora.co.uk> --- drivers/gpu/drm/nouveau/nouveau_display.c | 19
2017 Jan 18
1
[PATCH 3/4] drm/amd/display: Switch to using atomic_helper for flip.
...e fact that drm_atomic_helper_page_flip doesn't > call drm_crtc_vblank_get is a bit alarming. From the > DRM_IOCTL_MODE_PAGE_FLIP POV, drm_crtc_vblank_get must be called > when userspace calls the ioctl (either by drm_mode_page_flip_ioctl or the > page_flip hook implementation), and drm_crtc_vblank_put must be called > when the flip completes and the event is sent to userspace. How is this > supposed to be handled with atomic? First let me ask you - why we have to enable vlbank as part of pflip, I understand why it has to be enbbled in WAIT_FOR_VBLANK IOCTL but not sure about PFLIP IOCTL...
2017 Jul 12
2
[PATCH 15/16] drm/nouveau: Convert nouveau to use new iterator macros
...->event_lock, flags); - drm_crtc_send_vblank_event(crtc, crtc->state->event); + drm_crtc_send_vblank_event(crtc, new_crtc_state->event); spin_unlock_irqrestore(&crtc->dev->event_lock, flags); - crtc->state->event = NULL; + new_crtc_state->event = NULL; drm_crtc_vblank_put(crtc); } } @@ -4096,7 +4096,7 @@ nv50_disp_atomic_commit(struct drm_device *dev, { struct nouveau_drm *drm = nouveau_drm(dev); struct nv50_disp *disp = nv50_disp(dev); - struct drm_plane_state *plane_state; + struct drm_plane_state *old_plane_state; struct drm_plane *plane; struct drm...
2017 Jan 18
0
[PATCH 3/4] drm/amd/display: Switch to using atomic_helper for flip.
...right though that the fact that drm_atomic_helper_page_flip doesn't call drm_crtc_vblank_get is a bit alarming. From the DRM_IOCTL_MODE_PAGE_FLIP POV, drm_crtc_vblank_get must be called when userspace calls the ioctl (either by drm_mode_page_flip_ioctl or the page_flip hook implementation), and drm_crtc_vblank_put must be called when the flip completes and the event is sent to userspace. How is this supposed to be handled with atomic? Andrey, did you check via code audit and/or testing that the vblank reference count is still balanced after this change? >> @@ -3143,8 +3064,7 @@ int amdgpu_dm_atomic_...
2017 Jan 16
0
[PATCH 3/4] drm/amd/display: Switch to using atomic_helper for flip.
...te->active) { - DRM_DEBUG_ATOMIC("[CRTC:%d] disabled, rejecting legacy flip\n", - crtc->base.id); - ret = -EINVAL; - goto fail; - } - acrtc->flip_flags = flags; - - ret = drm_atomic_nonblocking_commit(state); - -fail: - if (ret == -EDEADLK) - goto backoff; - - if (ret) - drm_crtc_vblank_put(crtc); - - drm_atomic_state_put(state); - - return ret; -backoff: - drm_atomic_state_clear(state); - drm_atomic_legacy_backoff(state); - - /* - * Someone might have exchanged the framebuffer while we dropped locks - * in the backoff code. We need to fix up the fb refcount tracking the - * core d...
2017 Jul 19
1
[PATCH v2 6/7] drm/nouveau: Convert nouveau to use new iterator macros, v2.
...->event_lock, flags); - drm_crtc_send_vblank_event(crtc, crtc->state->event); + drm_crtc_send_vblank_event(crtc, new_crtc_state->event); spin_unlock_irqrestore(&crtc->dev->event_lock, flags); - crtc->state->event = NULL; + new_crtc_state->event = NULL; drm_crtc_vblank_put(crtc); } } @@ -4097,7 +4097,7 @@ nv50_disp_atomic_commit(struct drm_device *dev, { struct nouveau_drm *drm = nouveau_drm(dev); struct nv50_disp *disp = nv50_disp(dev); - struct drm_plane_state *plane_state; + struct drm_plane_state *old_plane_state; struct drm_plane *plane; struct drm...
2017 Jan 29
0
[v3 PATCH 3/3] drm/amd/display: Switch to using atomic_helper for flip.
...te->active) { - DRM_DEBUG_ATOMIC("[CRTC:%d] disabled, rejecting legacy flip\n", - crtc->base.id); - ret = -EINVAL; - goto fail; - } - acrtc->flip_flags = flags; - - ret = drm_atomic_nonblocking_commit(state); - -fail: - if (ret == -EDEADLK) - goto backoff; - - if (ret) - drm_crtc_vblank_put(crtc); - - drm_atomic_state_put(state); - - return ret; -backoff: - drm_atomic_state_clear(state); - drm_atomic_legacy_backoff(state); - - /* - * Someone might have exchanged the framebuffer while we dropped locks - * in the backoff code. We need to fix up the fb refcount tracking the - * core d...
2017 Jul 13
0
[Intel-gfx] [PATCH 15/16] drm/nouveau: Convert nouveau to use new iterator macros
...- drm_crtc_send_vblank_event(crtc, crtc->state->event); > + drm_crtc_send_vblank_event(crtc, new_crtc_state->event); > spin_unlock_irqrestore(&crtc->dev->event_lock, flags); > - crtc->state->event = NULL; > + new_crtc_state->event = NULL; > drm_crtc_vblank_put(crtc); > } > } > @@ -4096,7 +4096,7 @@ nv50_disp_atomic_commit(struct drm_device *dev, > { > struct nouveau_drm *drm = nouveau_drm(dev); > struct nv50_disp *disp = nv50_disp(dev); > - struct drm_plane_state *plane_state; > + struct drm_plane_state *old_plane_state;...
2017 Jan 30
1
[v3 PATCH 3/3] drm/amd/display: Switch to using atomic_helper for flip.
...ng legacy flip\n", > - crtc->base.id); > - ret = -EINVAL; > - goto fail; > - } > - acrtc->flip_flags = flags; > - > - ret = drm_atomic_nonblocking_commit(state); > - > -fail: > - if (ret == -EDEADLK) > - goto backoff; > - > - if (ret) > - drm_crtc_vblank_put(crtc); > - > - drm_atomic_state_put(state); > - > - return ret; > -backoff: > - drm_atomic_state_clear(state); > - drm_atomic_legacy_backoff(state); > - > - /* > - * Someone might have exchanged the framebuffer while we dropped locks > - * in the backoff code. We...
2017 Jan 29
7
[v3 PATCH 0/3] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patch 2 is to use this in AMDGPU/DC. Patch 3 is possible cleanup in nouveau/kms who seems to have to duplicate the helper as we did to support ASYNC flips. v2: Resend drm/atomic: Save flip flags in drm_plane_state
2017 Jan 16
12
[PATCH 0/4] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patches 2 and 3 are to use this in AMDGPU/DC and patch 4 is possible cleanup in nouveau/kms who seems to have the duplicate the helper as we did to support ASYNC flips. Andrey Grodzovsky (4): drm/atomic: Save flip
2017 Jan 17
4
[PATCH v2 0/3] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patch 2 is to use this in AMDGPU/DC. Patch 3 is possible cleanup in nouveau/kms who seems to have to duplicate the helper as we did to support ASYNC flips. v2: Resend drm/atomic: Save flip flags in drm_plane_state
2017 Feb 02
5
[PATCH v5 0/3] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patch 2 is to use this in AMDGPU/DC. Patch 3 is possible cleanup in nouveau/kms who seems to have to duplicate the helper as we did to support ASYNC flips. v2: Resend drm/atomic: Save flip flags in drm_plane_state
2017 Feb 01
6
[PATCH v4 0/3] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patch 2 is to use this in AMDGPU/DC. Patch 3 is possible cleanup in nouveau/kms who seems to have to duplicate the helper as we did to support ASYNC flips. v2: Resend drm/atomic: Save flip flags in drm_plane_state
2020 Jun 24
0
[RFC v7 03/11] drm/vblank: Add vblank works
...MISS) && drm_vblank_passed(seq, req_seq)) req_seq = seq + 1; e->pipe = pipe; @@ -2125,7 +2145,7 @@ int drm_crtc_queue_sequence_ioctl(struct drm_device *dev, void *data, e->sequence = req_seq; - if (vblank_passed(seq, req_seq)) { + if (drm_vblank_passed(seq, req_seq)) { drm_crtc_vblank_put(crtc); send_vblank_event(dev, e, seq, now); queue_seq->sequence = seq; @@ -2145,3 +2165,4 @@ int drm_crtc_queue_sequence_ioctl(struct drm_device *dev, void *data, kfree(e); return ret; } + diff --git a/drivers/gpu/drm/drm_vblank_internal.h b/drivers/gpu/drm/drm_vblank_internal.h new f...