Re: [Intel-gfx] [PATCH] drm/atomic: Fix double free in drm_atomic_state_default_clear

2017-01-31 Thread Gustavo Padovan
or TEST_ONLY too. > + * Free the allocated event. drm_atomic_helper_setup_commit > + * can allocate an event too, so only free it if it's ours > + * to prevent a double free in drm_atomic_state_clear. >

Re: [PATCH] drm/vc4: simplify exit path of a failed allocation of dsi_connector

2017-02-06 Thread Gustavo Padovan
504 ("Logicall Dead Code") > > Signed-off-by: Colin Ian King <colin.k...@canonical.com> > --- > drivers/gpu/drm/vc4/vc4_dsi.c | 16 ---- > 1 file changed, 4 insertions(+), 12 deletions(-) Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com>

Re: [PATCH -next] drm: mxsfb: fix error return code in mxsfb_load()

2017-02-06 Thread Gustavo Padovan
>fbdev)) { > + ret = PTR_ERR(mxsfb->fbdev); > mxsfb->fbdev = NULL; > dev_err(drm->dev, "Failed to init FB CMA area\n"); > goto err_cma; Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.co

Re: [PATCH] MAINTAINERS: add dma-fence* files to Sync File maintainership

2017-01-30 Thread Gustavo Padovan
2017-01-30 Sumit Semwal <sumit.sem...@linaro.org>: > Hi Gustavo, Daniel, > > On 30 January 2017 at 14:07, Daniel Vetter <dan...@ffwll.ch> wrote: > > > On Fri, Jan 27, 2017 at 03:54:44PM -0200, Gustavo Padovan wrote: > > > From: Gustavo Padovan <gustavo.

Re: [Intel-gfx] [PATCH 06/15] drm/doc: Clarify connector overview

2017-01-25 Thread Gustavo Padovan
th a pointer to the > + * connector functions and a connector type, and then exposed to userspace > with _connector_funcs Other than that: Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [Intel-gfx] [PATCH 01/15] drm/kms-helpers: Use recommened kerneldoc for struct member refs

2017-01-25 Thread Gustavo Padovan
gt; * mode_fixup encoder and CRTC helper operations to adjust the requested > mode, > @@ -493,8 +493,7 @@ drm_crtc_helper_disable(struct drm_crtc *crtc) > * > * If the adjusted mode is identical to the current mode but changes to the > * frame buffer need to be applied, the drm_crtc_helper_set_config() function > - * will call the CRTC ->mode_set_base() ( drm_crtc_helper_funcs) > helper > - * operation. > + * will call the CRTC _crtc_helper_funcs.mode_set_base helper operation. > * > * If the adjusted mode differs from the current mode, or if the > * ->mode_set_base() helper operation is not provided, the helper function > @@ -851,14 +850,15 @@ static int drm_helper_choose_crtc_dpms(struct drm_crtc > *crtc) > * @connector: affected connector > * @mode: DPMS mode > * > - * The drm_helper_connector_dpms() helper function implements the ->dpms() > - * callback of drm_connector_funcs for drivers using the legacy CRTC > helpers. > + * The drm_helper_connector_dpms() helper function implements the > + * _connector_funcs.dpms() callback for drivers using the legacy CRTC > + * helpers. You didn't use () in any of the others. Otherwise looks good to me: Rewiewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> Gustavo ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [Intel-gfx] [PATCH 04/15] drm/gem|prime|mm: Use recommened kerneldoc for struct member refs

2017-01-25 Thread Gustavo Padovan
.@intel.com> > --- > drivers/gpu/drm/drm_gem.c | 24 > drivers/gpu/drm/drm_mm.c| 4 ++-- > drivers/gpu/drm/drm_prime.c | 2 +- > include/drm/drm_gem.h | 16 ---- > 4 files changed, 23 insertions(+), 23 deletion

Re: [PATCH 07/15] drm/gma500: Nuke device_is_agp callback

2017-01-25 Thread Gustavo Padovan
drivers/gpu/drm/gma500/psb_drv.c | 6 -- > 1 file changed, 6 deletions(-) Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH 05/15] drm/core: Use recommened kerneldoc for struct member refs

2017-01-25 Thread Gustavo Padovan
ead and remove your ->load() callback. > + * drm_dev_register() instead and remove your _driver.load() callback. _driver.load? > * > * Return: 0 on success or a negative error code on failure. > */ > diff --git a/drivers/gpu/drm/drm_platform.c b/drivers/gpu/drm/drm_plat

Re: [Intel-gfx] [PATCH 06/15] drm/doc: Clarify connector overview

2017-01-25 Thread Gustavo Padovan
2017-01-25 Daniel Vetter <dan...@ffwll.ch>: > On Wed, Jan 25, 2017 at 10:57:17AM -0200, Gustavo Padovan wrote: > > Hi Daniel, > > > > 2017-01-25 Daniel Vetter <daniel.vet...@ffwll.ch>: > > > > > There was a bit of mix-up between initialization and

Re: [PATCH] dma/fence: Export enable-signaling tracepoint for emission by drivers

2017-01-27 Thread Gustavo Padovan
> > Signed-off-by: Chris Wilson <ch...@chris-wilson.co.uk> > Cc: Sumit Semwal <sumit.sem...@linaro.org> > Cc: Daniel Vetter <daniel.vet...@ffwll.ch> > --- > drivers/dma-buf/dma-fence.c | 1 + > 1 file changed, 1 insertion(+) Reviewed-by: Gu

Re: [PATCH] dma/fence: Export enable-signaling tracepoint for emission by drivers

2017-01-27 Thread Gustavo Padovan
Hi Chris, 2017-01-24 Chris Wilson : > Currently this tracepoint is solely used by dma_fence_enable_sw_signaling, > however I have a need to manually perform the hw enabling of the > signaling and would like to emit this tracepoint for completeness. > > Signed-off-by:

[PATCH] MAINTAINERS: add dma-fence* files to Sync File maintainership

2017-01-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.com> As Sync File is highly dependent on dma-fence* tracks it under SYNC FILE_FRAMEWORK as well. Signed-off-by: Gustavo Padovan <gustavo.pado...@collabora.com> --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/M

Re: [PATCH 02/14] drm: qxl: Consolidate bo reservation when pinning

2017-02-17 Thread Gustavo Padovan
-- > drivers/gpu/drm/qxl/qxl_fb.c | 25 ++- > drivers/gpu/drm/qxl/qxl_object.c | 41 -- > 3 files changed, 54 insertions(+), 64 deletions(-) Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> Gustavo _

Re: [PATCH 01/14] drm: qxl: Drop device flags attribute

2017-02-17 Thread Gustavo Padovan
xl_drv.c | 2 +- > drivers/gpu/drm/qxl/qxl_drv.h | 3 +-- > drivers/gpu/drm/qxl/qxl_kms.c | 5 + > 3 files changed, 3 insertions(+), 7 deletions(-) Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> Gustavo ___ dri-devel maili

Re: [PATCH] dma-buf/fence: Avoid use of uninitialised timestamp

2017-02-14 Thread Gustavo Padovan
ite is not atomic. Instead use a new bit to record the > presence of the timestamp, and teach the readers to wait until it is set > if the fence is complete. There still remains a race where the timestamp > for the signaled fence may be shown before the fence is reported as > signaled, but that's

Re: [PATCH] dma-buf/fence: Avoid use of uninitialised timestamp

2017-02-14 Thread Gustavo Padovan
2017-02-14 Chris Wilson <ch...@chris-wilson.co.uk>: > On Tue, Feb 14, 2017 at 11:40:38AM -0200, Gustavo Padovan wrote: > > Hi Chris, > > > > 2017-02-14 Chris Wilson <ch...@chris-wilson.co.uk>: > > > diff --git a/drivers/dma-buf/sync_debug.c b/drivers/dma

[PATCH] dma-buf/dma-fence: improve doc for dma_fence_add_callback()

2017-02-15 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.com> Document return values for this function. Signed-off-by: Gustavo Padovan <gustavo.pado...@collabora.com> --- drivers/dma-buf/dma-fence.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/dma-buf/dma-fence.c b/drivers

[PATCH] drm/virtio: call drm_plane_cleanup() at destroy phase

2017-02-15 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> virtio was missing this call to clean up core plane usage. Signed-off-by: Gustavo Padovan <gustavo.pado...@collabora.co.uk> --- drivers/gpu/drm/virtio/virtgpu_plane.c | 1 + 1 file changed, 1 insertion(+) diff --git a/dri

Re: [PATCH v2] drm/exynos: use atomic helper commit

2017-01-19 Thread Gustavo Padovan
are enabled. > > Signed-off-by: Inki Dae <inki@samsung.com> > Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> > --- > drivers/gpu/drm/exynos/exynos_drm_crtc.c | 10 ++- > drivers/gpu/drm/exynos/exynos_drm_drv.c | 109 > --- >

[PATCH v5 4/4] drm/fence: add out-fences support

2016-10-20 Thread Gustavo Padovan
2016-10-20 Ville Syrjälä : > On Thu, Oct 20, 2016 at 12:50:05PM -0200, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > Support DRM out-fences by creating a sync_file with a fence for each CRTC > > that sets the OUT_FENCE_PTR property. > > I still m

[PATCH] dma-buf/sw_sync: put fence reference from the fence creation

2016-10-26 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Once sw_sync_ioctl_create_fence() returns we no longer have the *pt pointer to the fence base object thus we need to put the reference we have from the fence creation to keep a correct reference accounting. Signed-off-by: Gustavo P

[PATCH] MAINTAINERS: update Sync File Framework files

2016-10-26 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Signed-off-by: Gustavo Padovan --- MAINTAINERS | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index e60e0a1..10f1bc0 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3913,8 +3913,1

[RFC PATCH v2 7/9] drm: atomic: factor out common out-fence operations

2016-10-26 Thread Gustavo Padovan
2016-10-26 Brian Starkey : > Some parts of setting up the CRTC out-fence can be re-used for > writeback out-fences. Factor this out into a separate function. > > Signed-off-by: Brian Starkey > --- > drivers/gpu/drm/drm_atomic.c | 64 > +++--- > 1 file

[RFC PATCH v2 8/9] drm: writeback: Add out-fences for writeback connectors

2016-10-26 Thread Gustavo Padovan
2016-10-26 Brian Starkey : > Add the OUT_FENCE_PTR property to writeback connectors, to enable > userspace to get a fence which will signal once the writeback is > complete. > > A timeline is added to drm_connector for use by the writeback > out-fences. It is up to drivers to check for a fence

[RFC PATCH v2 9/9] drm: mali-dp: Add writeback out-fence support

2016-10-26 Thread Gustavo Padovan
2016-10-26 Brian Starkey : > If userspace has asked for an out-fence for the writeback, we add a > fence to malidp_mw_job, to be signaled when the writeback job has > completed. > > Signed-off-by: Brian Starkey > --- > drivers/gpu/drm/arm/malidp_hw.c |5 - >

[RFC PATCH v2 7/9] drm: atomic: factor out common out-fence operations

2016-10-26 Thread Gustavo Padovan
2016-10-26 Brian Starkey : > Some parts of setting up the CRTC out-fence can be re-used for > writeback out-fences. Factor this out into a separate function. > > Signed-off-by: Brian Starkey > --- > drivers/gpu/drm/drm_atomic.c | 64 > +++--- > 1 file

[RFC PATCH v2 9/9] drm: mali-dp: Add writeback out-fence support

2016-10-27 Thread Gustavo Padovan
2016-10-27 Brian Starkey : > On Wed, Oct 26, 2016 at 07:43:57PM -0200, Gustavo Padovan wrote: > > 2016-10-26 Brian Starkey : > > > > > If userspace has asked for an out-fence for the writeback, we add a > > > fence to malidp_mw_job, to be signaled when the

[PATCH v6 0/6] drm: add explict fencing

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> This is yet another version of the DRM fences patches. Please refer to the cover letter[1] in previous version to check the fences details. For v6 we create drm_atomic_set_fence_for_plane() that tries to abstract from drivers

[PATCH v6 1/6] drm/atomic: add drm_atomic_set_fence_for_plane()

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> This new function should be used by drivers when setting a implicit fence for the plane. It abstracts the fact that the user might have chosen explicit fencing instead. Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/drm_atomic.

[PATCH v6 2/6] drm/imx: use drm_atomic_set_fence_for_plane() to set the fence

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> drm_atomic_set_fence_for_plane() is smart and won't overwrite plane_state->fence if the user already set an explicit fence there. Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/imx/imx-drm-core.c | 6 -- 1 file c

[PATCH v6 3/6] drm/msm: use drm_atomic_set_fence_for_plane() to set the fence

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> drm_atomic_set_fence_for_plane() is smart and won't overwrite plane_state->fence if the user already set an explicit fence there. Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/msm/msm_atomic.c | 3 ++- 1 file changed, 2 i

[PATCH v6 4/6] drm/fence: add in-fences support

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> There is now a new property called FENCE_FD attached to every plane state that receives the sync_file fd from userspace via the atomic commit IOCTL. The fd is then translated to a fence (that may be a fence_collection subclass o

[PATCH v6 5/6] drm/fence: add fence timeline to drm_crtc

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Create one timeline context for each CRTC to be able to handle out-fences and signal them. It adds a few members to struct drm_crtc: fence_context, where we store the context we get from fence_context_alloc(), the fence seqno and the

[PATCH v6 6/6] drm/fence: add out-fences support

2016-10-27 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Support DRM out-fences by creating a sync_file with a fence for each CRTC that sets the OUT_FENCE_PTR property. We use the out_fence pointer received in the OUT_FENCE_PTR prop to send the sync_file fd back to userspace. The syn

[PATCH v6 4/6] drm/fence: add in-fences support

2016-10-28 Thread Gustavo Padovan
2016-10-28 Daniel Vetter : > On Thu, Oct 27, 2016 at 05:37:09PM -0200, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > There is now a new property called FENCE_FD attached to every plane > > state that receives the sync_file fd from userspace via

[PATCH libdrm] add libsync.h helper

2016-10-31 Thread Gustavo Padovan
2016-10-31 Rob Clark : > On Mon, Oct 31, 2016 at 9:55 AM, Chris Wilson > wrote: > > On Mon, Oct 31, 2016 at 09:44:07AM -0400, Rob Clark wrote: > >> From: Rob Clark > >> > >> Rather than cut/pasting these couple ioctl wrappers everywhere, just > >> stuff them as static-inline into a header. >

[RFC v4 1/3] drm/fence: add in-fences support

2016-09-01 Thread Gustavo Padovan
Hi Maarten, 2016-09-01 Maarten Lankhorst : > Op 31-08-16 om 21:07 schreef Gustavo Padovan: > > From: Gustavo Padovan > > > > There is now a new property called FENCE_FD attached to every plane > > state that receives the sync_file fd from userspace via

[PATCH v3] drm/fence: allow fence waiting to be interrupted by userspace

2016-09-12 Thread Gustavo Padovan
Hi Sean, 2016-09-12 Sean Paul : > On Thu, Aug 25, 2016 at 12:47 PM, Gustavo Padovan > wrote: > > From: Gustavo Padovan > > > > If userspace is running an synchronously atomic commit and interrupts the > > atomic operation during fence_wait() it will hang until

[PATCH v4] drm/fence: allow fence waiting to be interrupted by userspace

2016-09-12 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> If userspace is running an synchronously atomic commit and interrupts the atomic operation during fence_wait() it will hang until the timer expires, so here we change the wait to be interruptible so it stop immediately when userspace

[PATCH] dma-buf/sync_file: Always increment refcount when merging fences.

2016-09-13 Thread Gustavo Padovan
igt_assert_f(sw_sync_wait(fence, -1) > 0, > "Failure waiting on fence\n"); >sw_sync_fence_destroy(fence); >} > >sw_sync_fence_destroy(fence_expired); > } > > drivers/dma-buf/sync_file.c | 7 ++- > 1 file changed, 2 insertions(+), 5 deletions(-) Thanks for spotting this. Reviewed-by: Gustavo Padovan Gustavo

[PATCH] dma-buf/sync_file: Always increment refcount when merging fences.

2016-09-14 Thread Gustavo Padovan
2016-09-14 Chris Wilson : > On Tue, Sep 13, 2016 at 04:24:27PM -0700, Rafael Antognolli wrote: > > The refcount of a fence should be increased whenever it is added to a merged > > fence, since it will later be decreased when the merged fence is destroyed. > > Failing to do so will cause the

[PATCH] dma-buf/sync_file: Always increment refcount when merging fences.

2016-09-14 Thread Gustavo Padovan
2016-09-14 Rafael Antognolli : > On Wed, Sep 14, 2016 at 11:04:01AM -0300, Gustavo Padovan wrote: > > 2016-09-14 Chris Wilson : > > > > > On Tue, Sep 13, 2016 at 04:24:27PM -0700, Rafael Antognolli wrote: > > > > The refcount of a fence shou

[PATCH v2 4/5] drm/qxl: squash lines for simple wrapper functions

2016-09-15 Thread Gustavo Padovan
s(-) For patches 1 to 4: Reviewed-by: Gustavo Padovan Gustavo

[PATCH] dma-buf/sync_file: Increment refcount of fence when all are signaled.

2016-09-15 Thread Gustavo Padovan
fence's refcount go to zero. > > Signed-off-by: Rafael Antognolli > --- > drivers/dma-buf/sync_file.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) Yes, mention the igt test case would be good. Otherwise: Reviewed-by: Gustavo Padovan Gustavo

[PATCH v2 4/5] drm/qxl: squash lines for simple wrapper functions

2016-09-15 Thread Gustavo Padovan
0 deletions(-) Reviewed-by: Gustavo Padovan Gustavo

[PATCH] dma-buf/sync_file: fix documentation error

2016-09-19 Thread Gustavo Padovan
nces. If num_fences is > 0, the system will > + * use the pointer provided on sync_fence_info to return up to num_fences of > + * struct sync_fence_info, with detailed fence information. > */ Reviewed-by: Gustavo Padovan Gustavo

[PATCH] dma-buf/sync-file: Avoid enable fence signaling if poll(.timeout=0)

2016-09-21 Thread Gustavo Padovan
iting. > > As we only install the callback once, the overhead comes from the atomic > > bit test that also causes serialisation between threads. > > > > Signed-off-by: Chris Wilson > > Cc: Sumit Semwal > > Cc: Gustavo Padovan > > Cc: linux-media at vg

[PATCH] dma-buf/sync_file: free fences array in num_fences is 1

2016-09-21 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> When merging sync_files there is a case when we can end up with only one fence in the merged sync_file: when all fences belong to the same timeline. So for this case a fence_array is not created instead we just assigned the

[PATCH] dma-buf/sw_sync: mark sync_timeline_create() static

2016-09-20 Thread Gustavo Padovan
red and don't need a declaration, but can be made static. > So this patch marks it 'static'. > > Signed-off-by: Baoyou Xie > --- > drivers/dma-buf/sw_sync.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Thanks for finding this. Reviewed-by: Gustavo Padovan Gustavo

[PATCH] dma-buf/fence-array: get signaled state when signaling is disabled

2016-09-21 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> If the fences in the fence_array signal on the fence_array does not have signalling enabled num_pending will not be updated accordingly. So when signaling is disabled check the signal of every fence with fence_is_signaled() and then c

[PATCH] dma-buf/fence-array: get signaled state when signaling is disabled

2016-09-22 Thread Gustavo Padovan
2016-09-22 Christian König : > Dropping the rest of the patch, cause that really doesn't make sense any > more. > > Am 22.09.2016 um 12:40 schrieb Gustavo Padovan: > > > E.g. for example it is illegal to do something like > > > >"while(!fence_is_signaled(f)

[PATCH] dma-buf/fence-array: get signaled state when signaling is disabled

2016-09-22 Thread Gustavo Padovan
Hi Christian, 2016-09-21 Christian König : > Am 21.09.2016 um 13:36 schrieb Gustavo Padovan: > > From: Gustavo Padovan > > > > If the fences in the fence_array signal on the fence_array does not have > > signalling enabled num_pending will not be updated ac

[PATCH v2] drm/fb-helper: add DRM_FB_HELPER_DEFAULT_OPS for fb_ops

2016-10-05 Thread Gustavo Padovan
Hi Stefan, 2016-10-04 Stefan Christ : > The define DRM_FB_HELPER_DEFAULT_OPS provides the drm_fb_helper default > implementations for functions in struct fb_ops. A drm driver can use it > like: > > static struct fb_ops drm_fbdev_cma_ops = { > .owner = THIS_MODULE, >

[PATCH] drm/bridge: Call drm_connector_cleanup directly

2016-10-05 Thread Gustavo Padovan
7 +-- > drivers/gpu/drm/bridge/parade-ps8622.c| 7 +-- > 3 files changed, 3 insertions(+), 18 deletions(-) Reviewed-by: Gustavo Padovan Gustavo

[PATCH 0/6] R-Car DU fixes and cleanups

2016-10-05 Thread Gustavo Padovan
kms.c | 10 +- > drivers/gpu/drm/rcar-du/rcar_du_lvdscon.c | 2 +- > drivers/gpu/drm/rcar-du/rcar_du_lvdscon.h | 2 +- > drivers/gpu/drm/rcar-du/rcar_du_lvdsenc.c | 4 +--- > drivers/video/of_display_timing.c | 6 +++--- > include/video/of_display_timing.h

[PATCH] drm/bridge: Call drm_connector_cleanup directly

2016-10-05 Thread Gustavo Padovan
Hi Marek, 2016-10-05 Marek Vasut : > On 10/05/2016 03:21 PM, Daniel Vetter wrote: > > On Wed, Oct 05, 2016 at 11:03:20AM +0200, Gustavo Padovan wrote: > >> Hi Marek, > >> > >> 2016-10-05 Marek Vasut : > >> > >>> Remove the u

[PATCH] dma-buf/fence-array: fix deadlock in fence-array

2016-10-17 Thread Gustavo Padovan
2016-10-17 Rob Clark : > Currently with fence-array, we have a potential deadlock situation. If we > fence_add_callback() on an array-fence, the array-fence's lock is acquired > first, and in it's ->enable_signaling() callback, it will install cb's on > it's array-member fences, so the

[PATCH] dma-buf/fence-array: fix deadlock in fence-array

2016-10-17 Thread Gustavo Padovan
2016-10-17 Rob Clark : > On Mon, Oct 17, 2016 at 2:52 PM, Gustavo Padovan > wrote: > > 2016-10-17 Rob Clark : > > > >> Currently with fence-array, we have a potential deadlock situation. If we > >> fence_add_callback() on an array-fence, the array

[PATCH] dma-buf/fence-array: fix deadlock in fence-array

2016-10-17 Thread Gustavo Padovan
2016-10-17 Chris Wilson : > On Mon, Oct 17, 2016 at 02:59:52PM -0400, Rob Clark wrote: > > On Mon, Oct 17, 2016 at 2:52 PM, Gustavo Padovan > > wrote: > > > 2016-10-17 Rob Clark : > > > > > >> Currently with fence-array, we have a

[PATCH v2] virtio-gpu: fix vblank events

2016-10-18 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> virtio-gpu sends vblank events in virtio_gpu_crtc_atomic_flush, and because of that it must be called for disabled planes too. Ask drm_atomic_helper_commit_planes to do that. v2: update to use new drm_atomic_helper_commit_planes

[PATCH v2] virtio-gpu: fix vblank events

2016-10-18 Thread Gustavo Padovan
ed-off-by: Gerd Hoffmann Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/virtio/virtgpu_display.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/virtio/virtgpu_display.c b/drivers/gpu/drm/virtio/virtgpu_display.c index 6848651..64facc8 100644 --- a/drivers/g

[PATCH v2] virtio-gpu: fix vblank events

2016-10-18 Thread Gustavo Padovan
2016-10-18 Gustavo Padovan : > From: Gustavo Padovan Author info is wrong. It should be Gerd, I'll send another patch. > > virtio-gpu sends vblank events in virtio_gpu_crtc_atomic_flush, and > because of that it must be called for disabled planes too. Ask > drm_atomic_helpe

[PATCH v2] virtio-gpu: fix vblank events

2016-10-18 Thread Gustavo Padovan
ed-off-by: Gerd Hoffmann Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/virtio/virtgpu_display.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/virtio/virtgpu_display.c b/drivers/gpu/drm/virtio/virtgpu_display.c index 6848651..64facc8 100644 --- a/drivers/g

[PATCH 1/2] dma-buf/sync_file: hold reference to fence when creating sync_file

2016-10-19 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> fence referencing was out of balance. It was not taking any ref to the fence at creating time, but it was putting a reference when freeing the sync file. This patch fixes the balancing issue by getting a reference for the fenc

[PATCH 2/2] dma-buf/fence-array: hold fences reference when creating an array

2016-10-19 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> When creating fence arrays we were not holding references to the fences in the array, however when destroy the array we were putting away a reference to these fences. This patch hold the ref for all fences in the array when cr

[PATCH 2/2] dma-buf/fence-array: hold fences reference when creating an array

2016-10-19 Thread Gustavo Padovan
2016-10-19 Christian König : > Am 19.10.2016 um 19:48 schrieb Gustavo Padovan: > > From: Gustavo Padovan > > > > When creating fence arrays we were not holding references to the fences > > in the array, however when destroy the array we were putting away a &g

[PATCH 2/2] dma-buf/fence-array: hold fences reference when creating an array

2016-10-20 Thread Gustavo Padovan
2016-10-20 Christian König : > Am 19.10.2016 um 20:35 schrieb Gustavo Padovan: > > 2016-10-19 Christian König : > > > > > Am 19.10.2016 um 19:48 schrieb Gustavo Padovan: > > > > From: Gustavo Padovan > > > > > > > > When creati

[PATCH] dma-buf: Rename struct fence to dma_fence

2016-10-20 Thread Gustavo Padovan
| 4 +- > include/linux/{fence-array.h => dma-fence-array.h} | 43 ++-- > include/linux/{fence.h => dma-fence.h} | 235 > +++------ > include/linux/reservation.h| 28 +-- > include/linux/seqno-fence.h| 16 +- > include/linux/sync_file.h | 14 +- > include/trace/events/{fence.h => dma_fence.h} | 44 ++-- > 107 files changed, 1174 insertions(+), 1136 deletions(-) > rename drivers/dma-buf/{fence-array.c => dma-fence-array.c} (53%) > rename drivers/dma-buf/{fence.c => dma-fence.c} (65%) > rename include/linux/{fence-array.h => dma-fence-array.h} (62%) > rename include/linux/{fence.h => dma-fence.h} (59%) > rename include/trace/events/{fence.h => dma_fence.h} (72%) Reviewed-by: Gustavo Padovan Gustavo

[PATCH v3 2/3] drm: zte: add initial vou drm driver

2016-10-20 Thread Gustavo Padovan
2016-10-20 Shawn Guo : > It adds the initial ZTE VOU display controller DRM driver. There are > still some features to be added, like overlay plane, scaling, and more > output devices support. But it's already useful with dual CRTCs and > HDMI monitor working. > > Signed-off-by: Shawn Guo >

[PATCH v5 0/4] drm: add explicit fencing

2016-10-20 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Hi, Currently the Linux Kernel only have an implicit fencing mechanism, through reservation objects, in which the fences are attached directly to buffers operations and userspace is unaware of what is happening. On the other hand ex

[PATCH v5 3/4] drm/fence: add fence timeline to drm_crtc

2016-10-20 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Create one timeline context for each CRTC to be able to handle out-fences and signal them. It adds a few members to struct drm_crtc: fence_context, where we store the context we get from fence_context_alloc(), the fence seqno and the

[PATCH v5 4/4] drm/fence: add out-fences support

2016-10-20 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> Support DRM out-fences by creating a sync_file with a fence for each CRTC that sets the OUT_FENCE_PTR property. We use the out_fence pointer received in the OUT_FENCE_PTR prop to send the sync_file fd back to userspace. The syn

[PATCH v5 1/4] drm/fence: add in-fences support

2016-10-20 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> There is now a new property called FENCE_FD attached to every plane state that receives the sync_file fd from userspace via the atomic commit IOCTL. The fd is then translated to a fence (that may be a fence_collection subclass o

[PATCH v5 2/4] drm/fence: release fence reference when canceling event

2016-10-20 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.co.uk> If the event gets canceled we also need to put away the fence reference it holds. Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/drm_fops.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/drm_fops.c b/d

[PATCH v5 3/4] drm/fence: add fence timeline to drm_crtc

2016-10-20 Thread Gustavo Padovan
2016-10-20 Brian Starkey : > Hi Gustavo, > > On Thu, Oct 20, 2016 at 12:50:04PM -0200, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > Create one timeline context for each CRTC to be able to handle out-fences > > and signal them. It adds a few members

[PATCH v5 4/4] drm/fence: add out-fences support

2016-10-20 Thread Gustavo Padovan
out-fence patch because we already hold the ref when we create the fence. The sync_file refcount patch will remain. > > Couple more comments below. > > On Thu, Oct 20, 2016 at 12:50:05PM -0200, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > Support DRM ou

[PATCH v5 4/4] drm/fence: add out-fences support

2016-10-21 Thread Gustavo Padovan
2016-10-21 Daniel Vetter : > On Thu, Oct 20, 2016 at 10:15:20PM +0300, Ville Syrjälä wrote: > > On Thu, Oct 20, 2016 at 07:34:44PM +0300, Ville Syrjälä wrote: > > > On Thu, Oct 20, 2016 at 01:55:38PM -0200, Gustavo Padovan wrote: > > > > 2016-10-20 Ville Syrjäl

[PATCH 1/2] drm/exynos/vidi: use timer for vblanks instead of sleeping worker

2016-09-23 Thread Gustavo Padovan
1 file changed, 20 insertions(+), 46 deletions(-) Reviewed-by: Gustavo Padovan Gustavo

[PATCH 2/2] drm/exynos: fix pending update handling

2016-09-23 Thread Gustavo Padovan
drm/exynos/exynos_drm_drv.c | 44 > +--- > drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 -- > 3 files changed, 2 insertions(+), 60 deletions(-) Reviewed-by: Gustavo Padovan Gustavo

[PATCH] dma-buf/sw_sync: mark sync_timeline_create() static

2016-09-25 Thread Gustavo Padovan
Hi Baoyou, 2016-09-22 Greg Kroah-Hartman : > On Tue, Sep 20, 2016 at 06:23:33PM +0530, Sumit Semwal wrote: > > Hi Baoyou, > > > > On 20 September 2016 at 16:43, Gustavo Padovan > > wrote: > > > 2016-09-18 Baoyou Xie : > > > > > >> We ge

[PATCH] dma-buf/fence-array: get signaled state when signaling is disabled

2016-09-25 Thread Gustavo Padovan
2016-09-23 Christian König : > Am 23.09.2016 um 13:30 schrieb Gustavo Padovan: > > 2016-09-22 Christian König : > > > > > Am 22.09.2016 um 13:16 schrieb Gustavo Padovan: > > > > 2016-09-22 Christian König : > > > > > > > > >

[PATCH] dma-buf/fence-array: get signaled state when signaling is disabled

2016-09-23 Thread Gustavo Padovan
2016-09-22 Christian König : > Am 22.09.2016 um 13:16 schrieb Gustavo Padovan: > > 2016-09-22 Christian König : > > > > > Dropping the rest of the patch, cause that really doesn't make sense any > > > more. > > > > > > Am 22.09.2016 um 12:40

[PATCH] uapi: add missing install of sync_file.h

2016-09-27 Thread Gustavo Padovan
net/lists/linux-kselftest/msg00457.html > > include/uapi/linux/Kbuild | 1 + > 1 file changed, 1 insertion(+) Reviewed-by: Gustavo Padovan Gustavo

[PATCH 00/20] Introduce DRM_FB_HELPER_DEFAULT_OPS for struct fb_ops

2016-09-30 Thread Gustavo Padovan
ivers/gpu/drm/virtio/virtgpu_fb.c | 6 +- > include/drm/drm_fb_helper.h | 13 + > 20 files changed, 35 insertions(+), 101 deletions(-) This looks good to me. Reviewed-by: Gustavo Padovan I wonder if we shouldn't start doing the same to drm_crtc_funcs and drm_plane_funcs after we added the atomic helpers. Gustavo

Re: [PATCH 1/3] drm: qxl: Let DRM core handle connector registering

2017-01-17 Thread Gustavo Padovan
Hi Gabriel, 2017-01-12 Gabriel Krisman Bertazi : > Registering the connector explicitly right after creation is not > necessary for modesetting drivers, because drm_dev_register already takes > care of this on the core side, by calling drm_modeset_register_all. > > In

Re: [PATCH] drm/exynos: use atomic helper commit

2017-01-16 Thread Gustavo Padovan
state); > + > + drm_atomic_helper_wait_for_vblanks(dev, state); > + > + drm_atomic_helper_cleanup_planes(dev, state); > +} > + > +static struct drm_mode_config_helper_funcs exynos_drm_mode_config_helpers = { > + .atomic_commit_tail = exynos_drm_atomic_commit_tail, > +}; &g

Re: [PATCH 1/4] drm/atomic: Save flip flags in drm_plane_state

2017-01-16 Thread Gustavo Padovan
Hi Andrey, 2017-01-16 Andrey Grodzovsky : > Allows using atomic flip helpers for drivers > using ASYNC flip. > Remove ASYNC_FLIP restriction in helpers and > caches the page flip flags in drm_plane_state > to be used in the low level drivers. > > Signed-off-by: Andrey

Re: [PATCH] drm: Clean up the 1366x768 fixup codes

2017-01-16 Thread Gustavo Padovan
Hi Takashi, 2017-01-16 Takashi Iwai : > This is just a cleanup, no functional change. > > The fixup code for 1366x768 in drm_mode_create_from_cmdline_mode() is > basically a copy of the existing code in drm_edid.c. Make the latter > code public so that it can be called from the

[PATCH] drm/armada: Include current dir on CFLAGS for armada trace

2017-01-16 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.com> Otherwise compilation fails like this: In file included from drivers/gpu/drm/armada/armada_trace.h:66:0, from drivers/gpu/drm/armada/armada_trace.c:3: ./include/trace/define_trace.h:88:43: fatal error: ./armada_t

Re: [PATCH] drm/fence: fix memory overwrite when setting out_fence fd

2017-01-16 Thread Gustavo Padovan
2017-01-13 Chad Versace <chadvers...@chromium.org>: > On Fri 13 Jan 2017, Gustavo Padovan wrote: > > From: Gustavo Padovan <gustavo.pado...@collabora.com> > > > > Currently if the userspace declares a int variable to store the out_fence > > fd

Re: [PATCH] drm/armada: Include current dir on CFLAGS for armada trace

2017-01-16 Thread Gustavo Padovan
2017-01-16 Laurent Pinchart <laurent.pinch...@ideasonboard.com>: > Hi Gustavo, > > Thank you for the patch. > > On Monday 16 Jan 2017 18:13:30 Gustavo Padovan wrote: > > From: Gustavo Padovan <gustavo.pado...@collabora.com> > > > > Otherwise

Re: [PATCH 2/3] drm: qxl: Open code probing sequence for qxl

2017-01-16 Thread Gustavo Padovan
Hi Gabriel, 2017-01-12 Gabriel Krisman Bertazi : > This avoids using the deprecated drm_get_pci_dev() and load() hook > interfaces in the qxl driver. > > The only tricky part is to ensure TTM debugfs initialization > happens after the debugfs root node is created, which

Re: [PATCH -next] drm/hisilicon/hibmc: Fix wrong pointer passed to PTR_ERR()

2017-01-16 Thread Gustavo Padovan
support for frame buffer") > Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> Gustavo ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH -next] drm/atomic: make release_crtc_commit() static

2017-01-16 Thread Gustavo Padovan
tatic? > > Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> > --- > drivers/gpu/drm/drm_atomic_helper.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Gustavo Padovan <gustavo.pado...@collabora.com> Gustavo ___

Re: [PATCH v2 1/2] drm: qxl: Open code probing sequence for qxl

2017-01-18 Thread Gustavo Padovan
kris...@collabora.co.uk> > Cc: Dave Airlie <airl...@redhat.com> > Cc: Daniel Vetter <daniel.vet...@ffwll.ch> > Cc: Gustavo Padovan <gustavo.pado...@collabora.com> > --- > drivers/gpu/drm/qxl/qxl_debugfs.c | 10 +++ > drivers/gpu/drm/qxl/qxl_drv.c |

Re: [PATCH v3 2/2] drm: qxl: Open code teardown function for qxl

2017-01-19 Thread Gustavo Padovan
rl...@redhat.com> > Cc: Daniel Vetter <daniel.vet...@ffwll.ch> > Cc: Gustavo Padovan <gustavo.pado...@collabora.com> > --- > drivers/gpu/drm/qxl/qxl_drv.c | 11 +-- > drivers/gpu/drm/qxl/qxl_drv.h | 2 -- > drivers/gpu/drm/qxl/qxl_kms.c | 16

Re: [PATCH] drm/fence: fix memory overwrite when setting out_fence fd

2017-01-13 Thread Gustavo Padovan
2017-01-13 Laurent Pinchart <laurent.pinch...@ideasonboard.com>: > Hi Gustavo, > > Thank you for the patch. > > On Friday 13 Jan 2017 12:22:09 Gustavo Padovan wrote: > > From: Gustavo Padovan <gustavo.pado...@collabora.com> > > > > Currently if t

[PATCH] drm/fence: fix memory overwrite when setting out_fence fd

2017-01-13 Thread Gustavo Padovan
From: Gustavo Padovan <gustavo.pado...@collabora.com> Currently if the userspace declares a int variable to store the out_fence fd and pass it to OUT_FENCE_PTR the kernel will overwrite the 32 bits above the int variable on 64 bits systems. Fix this by making the internal storage of out

[PATCH 2/3] kernel.h: add u64_to_user_ptr()

2016-04-21 Thread Gustavo Padovan
2016-04-20 Joe Perches : > On Wed, 2016-04-20 at 16:18 -0300, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > This function had copies in 3 different files. Unify them in kernel.h. > [] > > diff --git a/include/linux/kernel.h b/include/linux/ker

  1   2   3   4   5   6   7   8   9   10   >