]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commitdiff
tegra: dc: ext: use work_index 0 for Android
authorDaniel Solomon <daniels@nvidia.com>
Wed, 24 Jun 2015 04:09:31 +0000 (21:09 -0700)
committerDaniel Solomon <daniels@nvidia.com>
Mon, 20 Jul 2015 20:22:56 +0000 (13:22 -0700)
Flip data and flip timestamps are expected to be queued
on a single window's timestamp queue and flip wq. That window
corresponds to work_index, determined at the start of
tegra_dc_ext_flip().

On Android, the work_index mechanism isn't supported - only
Window A's flip and timestamp queues should be used. Currently
this is true for flips, but timestamps can be queued to
different windows' queues depending on work_index.

This change sets work_index for _both_ flip and timestamp
queueing for Android.

Bug 1654135

Change-Id: I3744c151f48f36e8db45ef5edd2c08e8fbbbd13e
Signed-off-by: Daniel Solomon <daniels@nvidia.com>
Reviewed-on: http://git-master/r/761542
(cherry picked from commit 7e14db5a4ee3e922445083ad71bd5bfe76bd9047)
Reviewed-on: http://git-master/r/771176
GVS: Gerrit_Virtual_Submit
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
drivers/video/tegra/dc/ext/dev.c

index 3967cf7ed8116b73486c227871592d8add222ca0..fd6bbf39e1a4a3a1c6a4c9d2d618011d5e3c4fa2 100644 (file)
@@ -1112,6 +1112,9 @@ static int tegra_dc_ext_flip(struct tegra_dc_ext_user *user,
                ret = -EINVAL;
                goto unlock;
        }
+#ifdef CONFIG_ANDROID
+       work_index = 0;
+#endif
 
        if (syncpt_fd) {
                if (post_sync_id != NVSYNCPT_INVALID) {
@@ -1137,9 +1140,6 @@ static int tegra_dc_ext_flip(struct tegra_dc_ext_user *user,
                list_add_tail(&data->timestamp_node, &ext->win[work_index].timestamp_queue);
                mutex_unlock(&ext->win[work_index].queue_lock);
        }
-#ifdef CONFIG_ANDROID
-       work_index = 0;
-#endif
        data->flags = flip_flags;
        queue_work(ext->win[work_index].flip_wq, &data->work);