]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commitdiff
tegra: dc: ext: fix Coverity dead code issue
authorDaniel Solomon <daniels@nvidia.com>
Tue, 1 Sep 2015 23:14:35 +0000 (16:14 -0700)
committerMitch Luban <mluban@nvidia.com>
Sat, 5 Sep 2015 18:26:22 +0000 (11:26 -0700)
Forcing has_timestamp to flase on Android causes
dead code.
Fix for Coverity CID 19586.

Bug 200116059

Change-Id: I3082f660d0a3d3c63d2d37e0cbbb80230e57a431
Signed-off-by: Daniel Solomon <daniels@nvidia.com>
Reviewed-on: http://git-master/r/792742
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Mitch Luban <mluban@nvidia.com>
drivers/video/tegra/dc/ext/dev.c

index 3a6d103ddcc272cdd522a5b946cebe099057bead..e7e801ee013020da6c57f9e3eeb42045abc59647 100644 (file)
@@ -1138,8 +1138,6 @@ static int tegra_dc_ext_flip(struct tegra_dc_ext_user *user,
        }
 #ifdef CONFIG_ANDROID
        work_index = 0;
-       /* Avoid queueing timestamps, to disable skipping flips */
-       has_timestamp = false;
 #endif
 
        if (syncpt_fd) {
@@ -1161,11 +1159,14 @@ static int tegra_dc_ext_flip(struct tegra_dc_ext_user *user,
 
        trace_flip_rcvd_syncpt_upd(post_sync_val);
 
+       /* Avoid queueing timestamps on Android, to disable skipping flips */
+#ifndef CONFIG_ANDROID
        if (has_timestamp) {
                mutex_lock(&ext->win[work_index].queue_lock);
                list_add_tail(&data->timestamp_node, &ext->win[work_index].timestamp_queue);
                mutex_unlock(&ext->win[work_index].queue_lock);
        }
+#endif
        data->flags = flip_flags;
        queue_work(ext->win[work_index].flip_wq, &data->work);