e_plane: do not execute layer_commit if output is disconnected 18/197418/2
authorJunkyeong Kim <jk0430.kim@samsung.com>
Fri, 11 Jan 2019 05:27:39 +0000 (14:27 +0900)
committerSooChan Lim <sc1.lim@samsung.com>
Mon, 14 Jan 2019 00:14:18 +0000 (00:14 +0000)
if output is disconnected, cannot use output resources.
so do not execute commit function.

Change-Id: Idbf3262b7edfd87f6c7dbe6ebc456a1ed9c8c1d4
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
src/bin/e_plane.c

index 00a6d8d..031725a 100644 (file)
@@ -1073,10 +1073,7 @@ _e_plane_pp_layer_commit_handler(tdm_layer *layer, unsigned int sequence,
         _e_plane_pp_pending_data_remove(plane);
 
         if (plane->is_external)
-          {
-             tdm_layer_unset_buffer(plane->tlayer);
-             tdm_layer_commit(plane->tlayer, NULL, NULL);
-          }
+          tdm_layer_unset_buffer(plane->tlayer);
 
         return;
      }
@@ -1200,7 +1197,10 @@ _e_plane_pp_layer_data_commit(E_Plane *plane, E_Plane_Commit_Data *data)
    if (plane->is_external)
      {
         if (!e_output_connected(output))
-          tdm_layer_unset_buffer(tlayer);
+          {
+             tdm_layer_unset_buffer(tlayer);
+             goto fail;
+          }
      }
 
    aligned_width = _e_plane_aligned_width_get(data->tsurface);
@@ -1423,10 +1423,7 @@ _e_plane_ex_commit_handler(tdm_layer *layer, unsigned int sequence,
    output = plane->output;
 
    if (!e_output_connected(output))
-     {
-        tdm_layer_unset_buffer(plane->tlayer);
-        tdm_layer_commit(plane->tlayer, NULL, NULL);
-     }
+     tdm_layer_unset_buffer(plane->tlayer);
 }
 
 static void