summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/drm_syncobj.c
diff options
context:
space:
mode:
authorSean Paul <seanpaul@chromium.org>2018-10-24 14:26:04 -0400
committerSean Paul <seanpaul@chromium.org>2018-10-24 14:26:04 -0400
commit6542e9adc0da1e23d81ff9314265a029b961906d (patch)
tree35ba360a7150d8b042a9fd75ab54ef83b34a2b95 /drivers/gpu/drm/drm_syncobj.c
parent2b02a05bdc3a62d36e0d0b015351897109e25991 (diff)
parentf2bfc71aee75feff33ca659322b72ffeed5a243d (diff)
Merge drm/drm-next into drm-misc-next
4.19 is out, Lyude asked for a backmerge, and it's been a while. All very good reasons on their own :-) Signed-off-by: Sean Paul <seanpaul@chromium.org>
Diffstat (limited to 'drivers/gpu/drm/drm_syncobj.c')
-rw-r--r--drivers/gpu/drm/drm_syncobj.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_syncobj.c b/drivers/gpu/drm/drm_syncobj.c
index b7eaa603f368..c8252cd4c02d 100644
--- a/drivers/gpu/drm/drm_syncobj.c
+++ b/drivers/gpu/drm/drm_syncobj.c
@@ -157,6 +157,8 @@ static void drm_syncobj_fence_get_or_add_callback(struct drm_syncobj *syncobj,
{
u64 pt_value = 0;
+ WARN_ON(*fence);
+
if (syncobj->type == DRM_SYNCOBJ_TYPE_BINARY) {
/*BINARY syncobj always wait on last pt */
pt_value = syncobj->signal_point;
@@ -935,6 +937,9 @@ static signed long drm_syncobj_array_wait_timeout(struct drm_syncobj **syncobjs,
if (flags & DRM_SYNCOBJ_WAIT_FLAGS_WAIT_FOR_SUBMIT) {
for (i = 0; i < count; ++i) {
+ if (entries[i].fence)
+ continue;
+
drm_syncobj_fence_get_or_add_callback(syncobjs[i],
&entries[i].fence,
&entries[i].syncobj_cb,