On Sat, Jul 29, 2017 at 12:18:32PM -0300, Gustavo Padovan wrote: > Hi Chris, > > 2017-07-28 Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>: > > > Up until recently sync_file were create to export a single dma-fence to > > userspace, and so we could canabalise a bit insie dma-fence to mark > > whether or not we had enable polling for the sync_file itself. However, > > with the advent of syncobj, we do allow userspace to create multiple > > sync_files for a single dma-fence. (Similarly, that the sw-sync > > validation framework also started returning multiple sync-files wrapping > > a single dma-fence for a syncpt also triggering the problem.) > > > > This patch reverts my suggestion in commit e24165537312 > > ("dma-buf/sync_file: only enable fence signalling on poll()") to use a > > single bit in the shared dma-fence and restores the sync_file->flags for > > tracking the bits individually. > > > > Reported-by: Gustavo Padovan <gustavo@xxxxxxxxxxx> > > Fixes: f1e8c67123cf ("dma-buf/sw-sync: Use an rbtree to sort fences in the timeline") > > Fixes: e9083420bbac ("drm: introduce sync objects (v4)") > > Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> > > Cc: Sumit Semwal <sumit.semwal@xxxxxxxxxx> > > Cc: Sean Paul <seanpaul@xxxxxxxxxxxx> > > Cc: Gustavo Padovan <gustavo@xxxxxxxxxxx> > > Cc: dri-devel@xxxxxxxxxxxxxxxxxxxxx > > Cc: <drm-intel-fixes@xxxxxxxxxxxxxxxxxxxxx> # v4.13-rc1+ > > --- > > drivers/dma-buf/sync_file.c | 5 +++-- > > include/linux/sync_file.h | 3 ++- > > 2 files changed, 5 insertions(+), 3 deletions(-) > > I confirm the patch fixes the sync kselftests for me. Pushed to > drm-misc-next. You need to cherry-pick this to drm-misc-fixes (using cherry-pick -x to make it clear we applied this twice), since the bug is in 4.13. drm-misc-next is for stuff that's only needed in 4.14. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx