diff options
author | Erik Gilling <konkers@android.com> | 2013-03-01 00:42:59 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-04 09:40:08 (GMT) |
commit | 97a84843ac4a1b81c36ccf35ee26cd19c5b8d873 (patch) | |
tree | e97d72a60ce7ab82d95e483a98f82cea322b3f2d /drivers/staging/android/sync.c | |
parent | 9d1906e61dda982070e3910a04d9cce050f7f1a4 (diff) | |
download | linux-fsl-qoriq-97a84843ac4a1b81c36ccf35ee26cd19c5b8d873.tar.xz |
staging: sync: Add timestamps to sync_pts
Add ktime timestamps to sync_pt structure and
update them when signaled
Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Cc: Erik Gilling <konkers@android.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Rob Clark <robclark@gmail.com>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Cc: dri-devel@lists.freedesktop.org
Cc: Android Kernel Team <kernel-team@android.com>
Signed-off-by: Erik Gilling <konkers@android.com>
[jstultz: Added commit message]
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/android/sync.c')
-rw-r--r-- | drivers/staging/android/sync.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/staging/android/sync.c b/drivers/staging/android/sync.c index 4a9e63d..88d7e66 100644 --- a/drivers/staging/android/sync.c +++ b/drivers/staging/android/sync.c @@ -155,12 +155,17 @@ void sync_pt_free(struct sync_pt *pt) /* call with pt->parent->active_list_lock held */ static int _sync_pt_has_signaled(struct sync_pt *pt) { + int old_status = pt->status; + if (!pt->status) pt->status = pt->parent->ops->has_signaled(pt); if (!pt->status && pt->parent->destroyed) pt->status = -ENOENT; + if (pt->status != old_status) + pt->timestamp = ktime_get(); + return pt->status; } |