The name of ivi_controller_interface is changed to ivi_layout_interface
with this patch.

This name is better suited to the interface, because it is implemented
in ivi-layout.c and its methods are linked to ivi_layout* functions.

Furthermore, the controller modules (e.g. hmi-controller) are the users
of this interface and they have their own interfaces,
which are called *_controller_interface,
e.g.: ivi_hmi_controller_interface.

This causes confusion about the software architecture.

Signed-off-by: Emre Ucan <eu...@de.adit-jv.com>
---
 ivi-shell/hmi-controller.c       |  168 ++++++------
 ivi-shell/ivi-layout-export.h    |    2 +-
 ivi-shell/ivi-layout.c           |    8 +-
 tests/ivi_layout-internal-test.c |  562 +++++++++++++++++++-------------------
 tests/ivi_layout-test-plugin.c   |  364 ++++++++++++------------
 5 files changed, 552 insertions(+), 552 deletions(-)

diff --git a/ivi-shell/hmi-controller.c b/ivi-shell/hmi-controller.c
index 5cc76d3..d1ed872 100644
--- a/ivi-shell/hmi-controller.c
+++ b/ivi-shell/hmi-controller.c
@@ -132,12 +132,12 @@ struct launcher_info {
        int32_t index;
 };
 
-const struct ivi_controller_interface *ivi_controller_interface;
+const struct ivi_layout_interface *ivi_layout_interface;
 
 int
 controller_module_init(struct weston_compositor *ec,
                       int *argc, char *argv[],
-                      const struct ivi_controller_interface *interface,
+                      const struct ivi_layout_interface *interface,
                       size_t interface_version);
 
 /*****************************************************************************
@@ -166,7 +166,7 @@ static int32_t
 is_surf_in_ui_widget(struct hmi_controller *hmi_ctrl,
                     struct ivi_layout_surface *ivisurf)
 {
-       uint32_t id = ivi_controller_interface->get_id_of_surface(ivisurf);
+       uint32_t id = ivi_layout_interface->get_id_of_surface(ivisurf);
 
        uint32_t *ui_widget_id = NULL;
        wl_array_for_each(ui_widget_id, &hmi_ctrl->ui_widgets) {
@@ -247,11 +247,11 @@ mode_divided_into_tiling(struct hmi_controller *hmi_ctrl,
                                surface_y = (int32_t)surface_height;
                        }
 
-                       
ivi_controller_interface->surface_set_transition(ivisurf,
+                       ivi_layout_interface->surface_set_transition(ivisurf,
                                        IVI_LAYOUT_TRANSITION_VIEW_DEFAULT,
                                        duration);
-                       
ivi_controller_interface->surface_set_visibility(ivisurf, true);
-                       
ivi_controller_interface->surface_set_destination_rectangle(ivisurf,
+                       ivi_layout_interface->surface_set_visibility(ivisurf, 
true);
+                       
ivi_layout_interface->surface_set_destination_rectangle(ivisurf,
                                        surface_x, surface_y,
                                        (int32_t)surface_width,
                                        (int32_t)surface_height);
@@ -259,11 +259,11 @@ mode_divided_into_tiling(struct hmi_controller *hmi_ctrl,
                        num++;
                        continue;
                }
-               ivi_controller_interface->surface_set_visibility(ivisurf, 
false);
+               ivi_layout_interface->surface_set_visibility(ivisurf, false);
        }
 
        if (surf_num > 0) {
-               ivi_controller_interface->layer_set_transition(layer->ivilayer,
+               ivi_layout_interface->layer_set_transition(layer->ivilayer,
                                IVI_LAYOUT_TRANSITION_LAYER_VIEW_ORDER,
                                duration);
        }
@@ -294,11 +294,11 @@ mode_divided_into_sidebyside(struct hmi_controller 
*hmi_ctrl,
                        continue;
 
                if (num == 1) {
-                       
ivi_controller_interface->surface_set_transition(ivisurf,
+                       ivi_layout_interface->surface_set_transition(ivisurf,
                                        IVI_LAYOUT_TRANSITION_VIEW_DEFAULT,
                                        duration);
-                       
ivi_controller_interface->surface_set_visibility(ivisurf, true);
-                       
ivi_controller_interface->surface_set_destination_rectangle(ivisurf,
+                       ivi_layout_interface->surface_set_visibility(ivisurf, 
true);
+                       
ivi_layout_interface->surface_set_destination_rectangle(ivisurf,
                                                        0, 0,
                                                        surface_width,
                                                        surface_height);
@@ -306,11 +306,11 @@ mode_divided_into_sidebyside(struct hmi_controller 
*hmi_ctrl,
                        num++;
                        continue;
                } else if (num == 2) {
-                       
ivi_controller_interface->surface_set_transition(ivisurf,
+                       ivi_layout_interface->surface_set_transition(ivisurf,
                                        IVI_LAYOUT_TRANSITION_VIEW_DEFAULT,
                                        duration);
-                       
ivi_controller_interface->surface_set_visibility(ivisurf, true);
-                       
ivi_controller_interface->surface_set_destination_rectangle(ivisurf,
+                       ivi_layout_interface->surface_set_visibility(ivisurf, 
true);
+                       
ivi_layout_interface->surface_set_destination_rectangle(ivisurf,
                                                        surface_width, 0,
                                                        surface_width,
                                                        surface_height);
@@ -318,10 +318,10 @@ mode_divided_into_sidebyside(struct hmi_controller 
*hmi_ctrl,
                        num++;
                        continue;
                }
-               ivi_controller_interface->surface_set_transition(ivisurf,
+               ivi_layout_interface->surface_set_transition(ivisurf,
                                        IVI_LAYOUT_TRANSITION_VIEW_FADE_ONLY,
                                        duration);
-               ivi_controller_interface->surface_set_visibility(ivisurf, 
false);
+               ivi_layout_interface->surface_set_visibility(ivisurf, false);
        }
 }
 
@@ -344,11 +344,11 @@ mode_fullscreen_someone(struct hmi_controller *hmi_ctrl,
                if (is_surf_in_ui_widget(hmi_ctrl, ivisurf))
                        continue;
 
-               ivi_controller_interface->surface_set_transition(ivisurf,
+               ivi_layout_interface->surface_set_transition(ivisurf,
                                        IVI_LAYOUT_TRANSITION_VIEW_DEFAULT,
                                        duration);
-               ivi_controller_interface->surface_set_visibility(ivisurf, true);
-               
ivi_controller_interface->surface_set_destination_rectangle(ivisurf, 0, 0,
+               ivi_layout_interface->surface_set_visibility(ivisurf, true);
+               
ivi_layout_interface->surface_set_destination_rectangle(ivisurf, 0, 0,
                                                             surface_width,
                                                             surface_height);
        }
@@ -375,14 +375,14 @@ mode_random_replace(struct hmi_controller *hmi_ctrl,
                if (is_surf_in_ui_widget(hmi_ctrl, ivisurf))
                        continue;
 
-               ivi_controller_interface->surface_set_transition(ivisurf,
+               ivi_layout_interface->surface_set_transition(ivisurf,
                                        IVI_LAYOUT_TRANSITION_VIEW_DEFAULT,
                                        duration);
-               ivi_controller_interface->surface_set_visibility(ivisurf, true);
+               ivi_layout_interface->surface_set_visibility(ivisurf, true);
                surface_x = rand() % (layer->width - surface_width);
                surface_y = rand() % (layer->height - surface_height);
 
-               
ivi_controller_interface->surface_set_destination_rectangle(ivisurf,
+               ivi_layout_interface->surface_set_destination_rectangle(ivisurf,
                                                             surface_x,
                                                             surface_y,
                                                             surface_width,
@@ -429,7 +429,7 @@ switch_mode(struct hmi_controller *hmi_ctrl,
 
        hmi_ctrl->layout_mode = layout_mode;
 
-       ret = ivi_controller_interface->get_surfaces(&surface_length, 
&pp_surface);
+       ret = ivi_layout_interface->get_surfaces(&surface_length, &pp_surface);
        assert(!ret);
 
        if (!has_application_surface(hmi_ctrl, pp_surface, surface_length)) {
@@ -457,7 +457,7 @@ switch_mode(struct hmi_controller *hmi_ctrl,
                break;
        }
 
-       ivi_controller_interface->commit_changes();
+       ivi_layout_interface->commit_changes();
        free(pp_surface);
 }
 
@@ -475,10 +475,10 @@ hmi_controller_fade_run(struct hmi_controller *hmi_ctrl, 
uint32_t is_fade_in,
        fade->is_fade_in = is_fade_in;
 
        wl_list_for_each(linklayer, &fade->layer_list, link) {
-               
ivi_controller_interface->layer_set_transition(linklayer->layout_layer,
+               
ivi_layout_interface->layer_set_transition(linklayer->layout_layer,
                                        IVI_LAYOUT_TRANSITION_LAYER_FADE,
                                        duration);
-               
ivi_controller_interface->layer_set_fade_info(linklayer->layout_layer,
+               
ivi_layout_interface->layer_set_fade_info(linklayer->layout_layer,
                                        is_fade_in, 1.0 - tint, tint);
        }
 }
@@ -494,21 +494,21 @@ create_layer(struct ivi_layout_screen *iviscrn,
        int32_t ret = 0;
 
        layer->ivilayer =
-               
ivi_controller_interface->layer_create_with_dimension(layer->id_layer,
+               
ivi_layout_interface->layer_create_with_dimension(layer->id_layer,
                                                       layer->width,
                                                       layer->height);
        assert(layer->ivilayer != NULL);
 
-       ret = ivi_controller_interface->screen_add_layer(iviscrn, 
layer->ivilayer);
+       ret = ivi_layout_interface->screen_add_layer(iviscrn, layer->ivilayer);
        assert(!ret);
 
-       ret = 
ivi_controller_interface->layer_set_destination_rectangle(layer->ivilayer,
+       ret = 
ivi_layout_interface->layer_set_destination_rectangle(layer->ivilayer,
                                                         layer->x, layer->y,
                                                         layer->width,
                                                         layer->height);
        assert(!ret);
 
-       ret = ivi_controller_interface->layer_set_visibility(layer->ivilayer, 
true);
+       ret = ivi_layout_interface->layer_set_visibility(layer->ivilayer, true);
        assert(!ret);
 }
 
@@ -528,7 +528,7 @@ set_notification_create_surface(struct ivi_layout_surface 
*ivisurf,
        if (is_surf_in_ui_widget(hmi_ctrl, ivisurf))
                return;
 
-       ret = ivi_controller_interface->layer_add_surface(application_layer, 
ivisurf);
+       ret = ivi_layout_interface->layer_add_surface(application_layer, 
ivisurf);
        assert(!ret);
 }
 
@@ -562,9 +562,9 @@ set_notification_configure_surface(struct 
ivi_layout_surface *ivisurf,
         * if application changes size of wl_buffer. The source rectangle shall 
be
         * fit to the size.
         */
-       surface = ivi_controller_interface->surface_get_weston_surface(ivisurf);
+       surface = ivi_layout_interface->surface_get_weston_surface(ivisurf);
        if (surface) {
-               ivi_controller_interface->surface_set_source_rectangle(
+               ivi_layout_interface->surface_set_source_rectangle(
                        ivisurf, 0, 0, surface->width,
                        surface->height);
        }
@@ -573,7 +573,7 @@ set_notification_configure_surface(struct 
ivi_layout_surface *ivisurf,
         *  search if the surface is already added to layer.
         *  If not yet, it is newly invoded application to go to switch_mode.
         */
-       ivi_controller_interface->get_surfaces_on_layer(application_layer,
+       ivi_layout_interface->get_surfaces_on_layer(application_layer,
                                                        &length, &ivisurfs);
        for (i = 0; i < length; i++) {
                if (ivisurf == ivisurfs[i]) {
@@ -581,7 +581,7 @@ set_notification_configure_surface(struct 
ivi_layout_surface *ivisurf,
                         * if it is non new invoked application, just call
                         * commit_changes to apply source_rectangle.
                         */
-                       ivi_controller_interface->commit_changes();
+                       ivi_layout_interface->commit_changes();
                        return;
                }
        }
@@ -681,11 +681,11 @@ hmi_controller_create(struct weston_compositor *ec)
        hmi_ctrl->hmi_setting = hmi_server_setting_create(ec);
        hmi_ctrl->compositor = ec;
 
-       ivi_controller_interface->get_screens(&screen_length, &pp_screen);
+       ivi_layout_interface->get_screens(&screen_length, &pp_screen);
 
        iviscrn = pp_screen[0];
 
-       ivi_controller_interface->get_screen_resolution(iviscrn, &screen_width,
+       ivi_layout_interface->get_screen_resolution(iviscrn, &screen_width,
                                         &screen_height);
 
        /* init base ivi_layer*/
@@ -720,9 +720,9 @@ hmi_controller_create(struct weston_compositor *ec)
                hmi_ctrl->hmi_setting->workspace_background_layer_id;
 
        create_layer(iviscrn, &hmi_ctrl->workspace_background_layer);
-       ivi_controller_interface->layer_set_opacity(
+       ivi_layout_interface->layer_set_opacity(
                hmi_ctrl->workspace_background_layer.ivilayer, 0);
-       ivi_controller_interface->layer_set_visibility(
+       ivi_layout_interface->layer_set_visibility(
                hmi_ctrl->workspace_background_layer.ivilayer, false);
 
 
@@ -733,11 +733,11 @@ hmi_controller_create(struct weston_compositor *ec)
        wl_list_insert(&hmi_ctrl->workspace_fade.layer_list,
                       &tmp_link_layer->link);
 
-       ivi_controller_interface->add_notification_create_surface(
+       ivi_layout_interface->add_notification_create_surface(
                set_notification_create_surface, hmi_ctrl);
-       ivi_controller_interface->add_notification_remove_surface(
+       ivi_layout_interface->add_notification_remove_surface(
                set_notification_remove_surface, hmi_ctrl);
-       ivi_controller_interface->add_notification_configure_surface(
+       ivi_layout_interface->add_notification_configure_surface(
                set_notification_configure_surface, hmi_ctrl);
 
        hmi_ctrl->destroy_listener.notify = hmi_controller_destroy;
@@ -777,17 +777,17 @@ ivi_hmi_controller_set_background(struct hmi_controller 
*hmi_ctrl,
                                                sizeof(*add_surface_id));
        *add_surface_id = id_surface;
 
-       ivisurf = ivi_controller_interface->get_surface_from_id(id_surface);
+       ivisurf = ivi_layout_interface->get_surface_from_id(id_surface);
        assert(ivisurf != NULL);
 
-       ret = ivi_controller_interface->layer_add_surface(ivilayer, ivisurf);
+       ret = ivi_layout_interface->layer_add_surface(ivilayer, ivisurf);
        assert(!ret);
 
-       ret = 
ivi_controller_interface->surface_set_destination_rectangle(ivisurf,
+       ret = ivi_layout_interface->surface_set_destination_rectangle(ivisurf,
                                        dstx, dsty, width, height);
        assert(!ret);
 
-       ret = ivi_controller_interface->surface_set_visibility(ivisurf, true);
+       ret = ivi_layout_interface->surface_set_visibility(ivisurf, true);
        assert(!ret);
 }
 
@@ -814,21 +814,21 @@ ivi_hmi_controller_set_panel(struct hmi_controller 
*hmi_ctrl,
                                                sizeof(*add_surface_id));
        *add_surface_id = id_surface;
 
-       ivisurf = ivi_controller_interface->get_surface_from_id(id_surface);
+       ivisurf = ivi_layout_interface->get_surface_from_id(id_surface);
        assert(ivisurf != NULL);
 
-       ret = ivi_controller_interface->layer_add_surface(ivilayer, ivisurf);
+       ret = ivi_layout_interface->layer_add_surface(ivilayer, ivisurf);
        assert(!ret);
 
        panel_height = hmi_ctrl->hmi_setting->panel_height;
 
        dsty = hmi_ctrl->base_layer.height - panel_height;
 
-       ret = ivi_controller_interface->surface_set_destination_rectangle(
+       ret = ivi_layout_interface->surface_set_destination_rectangle(
                ivisurf, dstx, dsty, width, panel_height);
        assert(!ret);
 
-       ret = ivi_controller_interface->surface_set_visibility(ivisurf, true);
+       ret = ivi_layout_interface->surface_set_visibility(ivisurf, true);
        assert(!ret);
 }
 
@@ -857,10 +857,10 @@ ivi_hmi_controller_set_button(struct hmi_controller 
*hmi_ctrl,
                                                sizeof(*add_surface_id));
        *add_surface_id = id_surface;
 
-       ivisurf = ivi_controller_interface->get_surface_from_id(id_surface);
+       ivisurf = ivi_layout_interface->get_surface_from_id(id_surface);
        assert(ivisurf != NULL);
 
-       ret = ivi_controller_interface->layer_add_surface(ivilayer, ivisurf);
+       ret = ivi_layout_interface->layer_add_surface(ivilayer, ivisurf);
        assert(!ret);
 
        panel_height = hmi_ctrl->hmi_setting->panel_height;
@@ -868,11 +868,11 @@ ivi_hmi_controller_set_button(struct hmi_controller 
*hmi_ctrl,
        dstx = (60 * number) + 15;
        dsty = (hmi_ctrl->base_layer.height - panel_height) + 5;
 
-       ret = ivi_controller_interface->surface_set_destination_rectangle(
+       ret = ivi_layout_interface->surface_set_destination_rectangle(
                ivisurf,dstx, dsty, width, height);
        assert(!ret);
 
-       ret = ivi_controller_interface->surface_set_visibility(ivisurf, true);
+       ret = ivi_layout_interface->surface_set_visibility(ivisurf, true);
        assert(!ret);
 }
 
@@ -899,17 +899,17 @@ ivi_hmi_controller_set_home_button(struct hmi_controller 
*hmi_ctrl,
                                                sizeof(*add_surface_id));
        *add_surface_id = id_surface;
 
-       ivisurf = ivi_controller_interface->get_surface_from_id(id_surface);
+       ivisurf = ivi_layout_interface->get_surface_from_id(id_surface);
        assert(ivisurf != NULL);
 
-       ret = ivi_controller_interface->layer_add_surface(ivilayer, ivisurf);
+       ret = ivi_layout_interface->layer_add_surface(ivilayer, ivisurf);
        assert(!ret);
 
-       ret = ivi_controller_interface->surface_set_destination_rectangle(
+       ret = ivi_layout_interface->surface_set_destination_rectangle(
                        ivisurf, dstx, dsty, size, size);
        assert(!ret);
 
-       ret = ivi_controller_interface->surface_set_visibility(ivisurf, true);
+       ret = ivi_layout_interface->surface_set_visibility(ivisurf, true);
        assert(!ret);
 }
 
@@ -935,17 +935,17 @@ ivi_hmi_controller_set_workspacebackground(struct 
hmi_controller *hmi_ctrl,
        *add_surface_id = id_surface;
        ivilayer = hmi_ctrl->workspace_background_layer.ivilayer;
 
-       ivisurf = ivi_controller_interface->get_surface_from_id(id_surface);
+       ivisurf = ivi_layout_interface->get_surface_from_id(id_surface);
        assert(ivisurf != NULL);
 
-       ret = ivi_controller_interface->layer_add_surface(ivilayer, ivisurf);
+       ret = ivi_layout_interface->layer_add_surface(ivilayer, ivisurf);
        assert(!ret);
 
-       ret = 
ivi_controller_interface->surface_set_destination_rectangle(ivisurf,
+       ret = ivi_layout_interface->surface_set_destination_rectangle(ivisurf,
                                                           0, 0, width, height);
        assert(!ret);
 
-       ret = ivi_controller_interface->surface_set_visibility(ivisurf, true);
+       ret = ivi_layout_interface->surface_set_visibility(ivisurf, true);
        assert(!ret);
 }
 
@@ -1074,10 +1074,10 @@ ivi_hmi_controller_add_launchers(struct hmi_controller 
*hmi_ctrl,
                y = ny * fcell_size_y  + space_y;
 
                layout_surface =
-                       
ivi_controller_interface->get_surface_from_id(data->surface_id);
+                       
ivi_layout_interface->get_surface_from_id(data->surface_id);
                assert(layout_surface);
 
-               ret = 
ivi_controller_interface->surface_set_destination_rectangle(
+               ret = ivi_layout_interface->surface_set_destination_rectangle(
                                layout_surface, x, y, icon_size, icon_size);
                assert(!ret);
 
@@ -1099,12 +1099,12 @@ ivi_hmi_controller_add_launchers(struct hmi_controller 
*hmi_ctrl,
        hmi_ctrl->workspace_layer.id_layer =
                hmi_ctrl->hmi_setting->workspace_layer_id;
 
-       ivi_controller_interface->get_screens(&screen_length, &pp_screen);
+       ivi_layout_interface->get_screens(&screen_length, &pp_screen);
        iviscrn = pp_screen[0];
        free(pp_screen);
        create_layer(iviscrn, &hmi_ctrl->workspace_layer);
-       
ivi_controller_interface->layer_set_opacity(hmi_ctrl->workspace_layer.ivilayer, 
0);
-       
ivi_controller_interface->layer_set_visibility(hmi_ctrl->workspace_layer.ivilayer,
+       
ivi_layout_interface->layer_set_opacity(hmi_ctrl->workspace_layer.ivilayer, 0);
+       
ivi_layout_interface->layer_set_visibility(hmi_ctrl->workspace_layer.ivilayer,
                                        false);
 
        tmp_link_layer = MEM_ALLOC(sizeof(*tmp_link_layer));
@@ -1115,19 +1115,19 @@ ivi_hmi_controller_add_launchers(struct hmi_controller 
*hmi_ctrl,
        /* Add surface to layer */
        wl_array_for_each(data, &launchers) {
                layout_surface =
-                       
ivi_controller_interface->get_surface_from_id(data->surface_id);
+                       
ivi_layout_interface->get_surface_from_id(data->surface_id);
                assert(layout_surface);
 
-               ret = 
ivi_controller_interface->layer_add_surface(hmi_ctrl->workspace_layer.ivilayer,
+               ret = 
ivi_layout_interface->layer_add_surface(hmi_ctrl->workspace_layer.ivilayer,
                                                                  
layout_surface);
                assert(!ret);
 
-               ret = 
ivi_controller_interface->surface_set_visibility(layout_surface, true);
+               ret = 
ivi_layout_interface->surface_set_visibility(layout_surface, true);
                assert(!ret);
        }
 
        wl_array_release(&launchers);
-       ivi_controller_interface->commit_changes();
+       ivi_layout_interface->commit_changes();
 }
 
 static void
@@ -1144,7 +1144,7 @@ ivi_hmi_controller_UI_ready(struct wl_client *client,
        ivi_hmi_controller_set_button(hmi_ctrl, hmi_ctrl->ui_setting.random_id, 
3);
        ivi_hmi_controller_set_home_button(hmi_ctrl, 
hmi_ctrl->ui_setting.home_id);
        ivi_hmi_controller_set_workspacebackground(hmi_ctrl, 
hmi_ctrl->ui_setting.workspace_background_id);
-       ivi_controller_interface->commit_changes();
+       ivi_layout_interface->commit_changes();
 
        ivi_hmi_controller_add_launchers(hmi_ctrl, 256);
        hmi_ctrl->is_initialized = 1;
@@ -1262,7 +1262,7 @@ move_workspace_grab_end(struct move_grab *move, struct 
wl_resource* resource,
        if (200 < from_motion_time)
                pointer_v = 0.0;
 
-       ivi_controller_interface->layer_get_position(layer, &pos_x, &pos_y);
+       ivi_layout_interface->layer_get_position(layer, &pos_x, &pos_y);
 
 
        if (is_flick) {
@@ -1282,14 +1282,14 @@ move_workspace_grab_end(struct move_grab *move, struct 
wl_resource* resource,
 
        duration = hmi_ctrl->hmi_setting->transition_duration;
        ivi_hmi_controller_send_workspace_end_control(resource, move->is_moved);
-       ivi_controller_interface->layer_set_transition(layer,
+       ivi_layout_interface->layer_set_transition(layer,
                                        IVI_LAYOUT_TRANSITION_LAYER_MOVE,
                                        duration);
-       ivi_controller_interface->layer_set_destination_rectangle(layer,
+       ivi_layout_interface->layer_set_destination_rectangle(layer,
                                end_pos, pos_y,
                                hmi_ctrl->workspace_layer.width,
                                hmi_ctrl->workspace_layer.height);
-       ivi_controller_interface->commit_changes();
+       ivi_layout_interface->commit_changes();
 }
 
 static void
@@ -1367,8 +1367,8 @@ layer_set_pos(struct ivi_layout_layer *layer, wl_fixed_t 
pos_x,
 
        layout_pos_x = wl_fixed_to_int(pos_x);
        layout_pos_y = wl_fixed_to_int(pos_y);
-       ivi_controller_interface->layer_set_position(layer, layout_pos_x, 
layout_pos_y);
-       ivi_controller_interface->commit_changes();
+       ivi_layout_interface->layer_set_position(layer, layout_pos_x, 
layout_pos_y);
+       ivi_layout_interface->commit_changes();
 }
 
 static void
@@ -1534,7 +1534,7 @@ move_grab_init_workspace(struct move_grab* move,
        wl_fixed_t rgn[2][2] = {{0}};
        wl_fixed_t grab_pos[2] = { grab_x, grab_y };
 
-       ivi_controller_interface->layer_get_position(layer, &layer_pos_x, 
&layer_pos_y);
+       ivi_layout_interface->layer_get_position(layer, &layer_pos_x, 
&layer_pos_y);
 
        start_pos[0] = wl_fixed_from_int(layer_pos_x);
        start_pos[1] = wl_fixed_from_int(layer_pos_y);
@@ -1605,7 +1605,7 @@ ivi_hmi_controller_workspace_control(struct wl_client 
*client,
 
        layer = hmi_ctrl->workspace_layer.ivilayer;
 
-       ivi_controller_interface->transition_move_layer_cancel(layer);
+       ivi_layout_interface->transition_move_layer_cancel(layer);
 
        switch (device) {
        case HMI_GRAB_DEVICE_POINTER:
@@ -1667,7 +1667,7 @@ ivi_hmi_controller_home(struct wl_client *client,
                                        &hmi_ctrl->workspace_fade);
        }
 
-       ivi_controller_interface->commit_changes();
+       ivi_layout_interface->commit_changes();
 }
 
 /**
@@ -1773,18 +1773,18 @@ launch_hmi_client_process(void *data)
 WL_EXPORT int
 controller_module_init(struct weston_compositor *ec,
                       int *argc, char *argv[],
-                      const struct ivi_controller_interface *interface,
+                      const struct ivi_layout_interface *interface,
                       size_t interface_version)
 {
        struct hmi_controller *hmi_ctrl = NULL;
        struct wl_event_loop *loop = NULL;
 
-       if (interface_version < sizeof(struct ivi_controller_interface)) {
+       if (interface_version < sizeof(struct ivi_layout_interface)) {
                weston_log("ivi-shell: version mismatch of controller 
interface\n");
                return -1;
        }
 
-       ivi_controller_interface = interface;
+       ivi_layout_interface = interface;
 
        hmi_ctrl = hmi_controller_create(ec);
 
diff --git a/ivi-shell/ivi-layout-export.h b/ivi-shell/ivi-layout-export.h
index 8a92009..54af286 100644
--- a/ivi-shell/ivi-layout-export.h
+++ b/ivi-shell/ivi-layout-export.h
@@ -173,7 +173,7 @@ typedef void (*ivi_controller_surface_content_callback)(
                        int32_t content,
                        void *userdata);
 
-struct ivi_controller_interface {
+struct ivi_layout_interface {
 
        /**
         * \brief Commit all changes and execute all enqueued commands since
diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
index 33d7143..c6d4b90 100644
--- a/ivi-shell/ivi-layout.c
+++ b/ivi-shell/ivi-layout.c
@@ -2682,7 +2682,7 @@ ivi_layout_surface_add_configured_listener(struct 
ivi_layout_surface* ivisurf,
        wl_signal_add(&ivisurf->configured, listener);
 }
 
-static struct ivi_controller_interface ivi_controller_interface = {
+static struct ivi_layout_interface ivi_layout_interface = {
        /**
         * commit all changes
         */
@@ -2798,7 +2798,7 @@ load_controller_modules(struct weston_compositor 
*compositor, const char *module
        char buffer[256];
        int (*controller_module_init)(struct weston_compositor *compositor,
                                      int *argc, char *argv[],
-                                     const struct ivi_controller_interface 
*interface,
+                                     const struct ivi_layout_interface 
*interface,
                                      size_t interface_version);
 
        if (modules == NULL)
@@ -2814,8 +2814,8 @@ load_controller_modules(struct weston_compositor 
*compositor, const char *module
                        return -1;
 
                if (controller_module_init(compositor, argc, argv,
-                                          &ivi_controller_interface,
-                               sizeof(struct ivi_controller_interface)) != 0) {
+                                          &ivi_layout_interface,
+                               sizeof(struct ivi_layout_interface)) != 0) {
                        weston_log("ivi-shell: Initialization of controller 
module fails");
                        return -1;
                }
diff --git a/tests/ivi_layout-internal-test.c b/tests/ivi_layout-internal-test.c
index bb9cce9..d0c759b 100644
--- a/tests/ivi_layout-internal-test.c
+++ b/tests/ivi_layout-internal-test.c
@@ -38,7 +38,7 @@
 
 struct test_context {
        struct weston_compositor *compositor;
-       const struct ivi_controller_interface *controller_interface;
+       const struct ivi_layout_interface *layout_interface;
        uint32_t user_flags;
 };
 
@@ -67,270 +67,270 @@ iassert_fail(const char *cond, const char *file, int line,
 static void
 test_surface_bad_visibility(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        bool visibility;
 
-       iassert(ctl->surface_set_visibility(NULL, true) == IVI_FAILED);
+       iassert(lyt->surface_set_visibility(NULL, true) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       visibility = ctl->surface_get_visibility(NULL);
+       visibility = lyt->surface_get_visibility(NULL);
        iassert(visibility == false);
 }
 
 static void
 test_surface_bad_destination_rectangle(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->surface_set_destination_rectangle(NULL, 20, 30, 200, 300) 
== IVI_FAILED);
+       iassert(lyt->surface_set_destination_rectangle(NULL, 20, 30, 200, 300) 
== IVI_FAILED);
 }
 
 static void
 test_surface_bad_orientation(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->surface_set_orientation(NULL, WL_OUTPUT_TRANSFORM_90) == 
IVI_FAILED);
+       iassert(lyt->surface_set_orientation(NULL, WL_OUTPUT_TRANSFORM_90) == 
IVI_FAILED);
 
-       iassert(ctl->surface_get_orientation(NULL) == 
WL_OUTPUT_TRANSFORM_NORMAL);
+       iassert(lyt->surface_get_orientation(NULL) == 
WL_OUTPUT_TRANSFORM_NORMAL);
 }
 
 static void
 test_surface_bad_dimension(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf = NULL;
        int32_t dest_width;
        int32_t dest_height;
 
-       iassert(ctl->surface_set_dimension(NULL, 200, 300) == IVI_FAILED);
+       iassert(lyt->surface_set_dimension(NULL, 200, 300) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->surface_get_dimension(NULL, &dest_width, &dest_height) == 
IVI_FAILED);
-       iassert(ctl->surface_get_dimension(ivisurf, NULL, &dest_height) == 
IVI_FAILED);
-       iassert(ctl->surface_get_dimension(ivisurf, &dest_width, NULL) == 
IVI_FAILED);
+       iassert(lyt->surface_get_dimension(NULL, &dest_width, &dest_height) == 
IVI_FAILED);
+       iassert(lyt->surface_get_dimension(ivisurf, NULL, &dest_height) == 
IVI_FAILED);
+       iassert(lyt->surface_get_dimension(ivisurf, &dest_width, NULL) == 
IVI_FAILED);
 }
 
 static void
 test_surface_bad_position(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf = NULL;
        int32_t dest_x;
        int32_t dest_y;
 
-       iassert(ctl->surface_set_position(NULL, 20, 30) == IVI_FAILED);
+       iassert(lyt->surface_set_position(NULL, 20, 30) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->surface_get_position(NULL, &dest_x, &dest_y) == 
IVI_FAILED);
-       iassert(ctl->surface_get_position(ivisurf, NULL, &dest_y) == 
IVI_FAILED);
-       iassert(ctl->surface_get_position(ivisurf, &dest_x, NULL) == 
IVI_FAILED);
+       iassert(lyt->surface_get_position(NULL, &dest_x, &dest_y) == 
IVI_FAILED);
+       iassert(lyt->surface_get_position(ivisurf, NULL, &dest_y) == 
IVI_FAILED);
+       iassert(lyt->surface_get_position(ivisurf, &dest_x, NULL) == 
IVI_FAILED);
 }
 
 static void
 test_surface_bad_source_rectangle(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->surface_set_source_rectangle(NULL, 20, 30, 200, 300) == 
IVI_FAILED);
+       iassert(lyt->surface_set_source_rectangle(NULL, 20, 30, 200, 300) == 
IVI_FAILED);
 }
 
 static void
 test_surface_bad_properties(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->get_properties_of_surface(NULL) == NULL);
+       iassert(lyt->get_properties_of_surface(NULL) == NULL);
 }
 
 static void
 test_layer_create(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        uint32_t id1;
        uint32_t id2;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_layer *new_ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(IVI_TEST_LAYER_ID(0) == ctl->get_id_of_layer(ivilayer));
+       iassert(IVI_TEST_LAYER_ID(0) == lyt->get_id_of_layer(ivilayer));
 
-       new_ivilayer = ctl->get_layer_from_id(IVI_TEST_LAYER_ID(0));
+       new_ivilayer = lyt->get_layer_from_id(IVI_TEST_LAYER_ID(0));
        iassert(ivilayer == new_ivilayer);
 
-       id1 = ctl->get_id_of_layer(ivilayer);
-       id2 = ctl->get_id_of_layer(new_ivilayer);
+       id1 = lyt->get_id_of_layer(ivilayer);
+       id2 = lyt->get_id_of_layer(new_ivilayer);
        iassert(id1 == id2);
 
-       ctl->layer_destroy(ivilayer);
-       iassert(ctl->get_layer_from_id(IVI_TEST_LAYER_ID(0)) == NULL);
+       lyt->layer_destroy(ivilayer);
+       iassert(lyt->get_layer_from_id(IVI_TEST_LAYER_ID(0)) == NULL);
 }
 
 static void
 test_layer_visibility(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_get_visibility(ivilayer) == false);
+       iassert(lyt->layer_get_visibility(ivilayer) == false);
 
-       iassert(ctl->layer_set_visibility(ivilayer, true) == IVI_SUCCEEDED);
+       iassert(lyt->layer_set_visibility(ivilayer, true) == IVI_SUCCEEDED);
 
-       iassert(ctl->layer_get_visibility(ivilayer) == false);
+       iassert(lyt->layer_get_visibility(ivilayer) == false);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_visibility(ivilayer) == true);
+       iassert(lyt->layer_get_visibility(ivilayer) == true);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->visibility == true);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_opacity(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_get_opacity(ivilayer) == wl_fixed_from_double(1.0));
+       iassert(lyt->layer_get_opacity(ivilayer) == wl_fixed_from_double(1.0));
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                ivilayer, wl_fixed_from_double(0.5)) == IVI_SUCCEEDED);
 
-       iassert(ctl->layer_get_opacity(ivilayer) == wl_fixed_from_double(1.0));
+       iassert(lyt->layer_get_opacity(ivilayer) == wl_fixed_from_double(1.0));
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_opacity(ivilayer) == wl_fixed_from_double(0.5));
+       iassert(lyt->layer_get_opacity(ivilayer) == wl_fixed_from_double(0.5));
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->opacity == wl_fixed_from_double(0.5));
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_orientation(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_get_orientation(ivilayer) == 
WL_OUTPUT_TRANSFORM_NORMAL);
+       iassert(lyt->layer_get_orientation(ivilayer) == 
WL_OUTPUT_TRANSFORM_NORMAL);
 
-       iassert(ctl->layer_set_orientation(
+       iassert(lyt->layer_set_orientation(
                ivilayer, WL_OUTPUT_TRANSFORM_90) == IVI_SUCCEEDED);
 
-       iassert(ctl->layer_get_orientation(ivilayer) == 
WL_OUTPUT_TRANSFORM_NORMAL);
+       iassert(lyt->layer_get_orientation(ivilayer) == 
WL_OUTPUT_TRANSFORM_NORMAL);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_orientation(ivilayer) == WL_OUTPUT_TRANSFORM_90);
+       iassert(lyt->layer_get_orientation(ivilayer) == WL_OUTPUT_TRANSFORM_90);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->orientation == WL_OUTPUT_TRANSFORM_90);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_dimension(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
        int32_t dest_width;
        int32_t dest_height;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_get_dimension(
+       iassert(lyt->layer_get_dimension(
                ivilayer, &dest_width, &dest_height) == IVI_SUCCEEDED);
        iassert(dest_width == 200);
        iassert(dest_height == 300);
 
-       iassert(ctl->layer_set_dimension(ivilayer, 400, 600) == IVI_SUCCEEDED);
+       iassert(lyt->layer_set_dimension(ivilayer, 400, 600) == IVI_SUCCEEDED);
 
-       iassert(ctl->layer_get_dimension(
+       iassert(lyt->layer_get_dimension(
                ivilayer, &dest_width, &dest_height) == IVI_SUCCEEDED);
        iassert(dest_width == 200);
        iassert(dest_height == 300);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(IVI_SUCCEEDED == ctl->layer_get_dimension(
+       iassert(IVI_SUCCEEDED == lyt->layer_get_dimension(
                ivilayer, &dest_width, &dest_height));
        iassert(dest_width == 400);
        iassert(dest_height == 600);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->dest_width == 400);
        iassert(prop->dest_height == 600);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_position(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
        int32_t dest_x;
        int32_t dest_y;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_get_position(
+       iassert(lyt->layer_get_position(
                ivilayer, &dest_x, &dest_y) == IVI_SUCCEEDED);
        iassert(dest_x == 0);
        iassert(dest_y == 0);
 
-       iassert(ctl->layer_set_position(ivilayer, 20, 30) == IVI_SUCCEEDED);
+       iassert(lyt->layer_set_position(ivilayer, 20, 30) == IVI_SUCCEEDED);
 
-       iassert(ctl->layer_get_position(
+       iassert(lyt->layer_get_position(
                ivilayer, &dest_x, &dest_y) == IVI_SUCCEEDED);
        iassert(dest_x == 0);
        iassert(dest_y == 0);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_position(
+       iassert(lyt->layer_get_position(
                ivilayer, &dest_x, &dest_y) == IVI_SUCCEEDED);
        iassert(dest_x == 20);
        iassert(dest_y == 30);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->dest_x == 20);
        iassert(prop->dest_y == 30);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_destination_rectangle(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
        int32_t dest_width;
@@ -338,384 +338,384 @@ test_layer_destination_rectangle(struct test_context 
*ctx)
        int32_t dest_x;
        int32_t dest_y;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->dest_width == 200);
        iassert(prop->dest_height == 300);
        iassert(prop->dest_x == 0);
        iassert(prop->dest_y == 0);
 
-       iassert(ctl->layer_set_destination_rectangle(
+       iassert(lyt->layer_set_destination_rectangle(
                ivilayer, 20, 30, 400, 600) == IVI_SUCCEEDED);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->dest_width == 200);
        iassert(prop->dest_height == 300);
        iassert(prop->dest_x == 0);
        iassert(prop->dest_y == 0);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_dimension(
+       iassert(lyt->layer_get_dimension(
                ivilayer, &dest_width, &dest_height) == IVI_SUCCEEDED);
        iassert(dest_width == 400);
        iassert(dest_height == 600);
 
-       iassert(ctl->layer_get_position(
+       iassert(lyt->layer_get_position(
                ivilayer, &dest_x, &dest_y) == IVI_SUCCEEDED);
        iassert(dest_x == 20);
        iassert(dest_y == 30);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->dest_width == 400);
        iassert(prop->dest_height == 600);
        iassert(prop->dest_x == 20);
        iassert(prop->dest_y == 30);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_source_rectangle(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        const struct ivi_layout_layer_properties *prop;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->source_width == 200);
        iassert(prop->source_height == 300);
        iassert(prop->source_x == 0);
        iassert(prop->source_y == 0);
 
-       iassert(ctl->layer_set_source_rectangle(
+       iassert(lyt->layer_set_source_rectangle(
                ivilayer, 20, 30, 400, 600) == IVI_SUCCEEDED);
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->source_width == 200);
        iassert(prop->source_height == 300);
        iassert(prop->source_x == 0);
        iassert(prop->source_y == 0);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       prop = ctl->get_properties_of_layer(ivilayer);
+       prop = lyt->get_properties_of_layer(ivilayer);
        iassert(prop->source_width == 400);
        iassert(prop->source_height == 600);
        iassert(prop->source_x == 20);
        iassert(prop->source_y == 30);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_bad_remove(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
-       ctl->layer_destroy(NULL);
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
+       lyt->layer_destroy(NULL);
 }
 
 static void
 test_layer_bad_visibility(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->layer_set_visibility(NULL, true) == IVI_FAILED);
+       iassert(lyt->layer_set_visibility(NULL, true) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_visibility(NULL) == false);
+       iassert(lyt->layer_get_visibility(NULL) == false);
 }
 
 static void
 test_layer_bad_opacity(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                NULL, wl_fixed_from_double(0.3)) == IVI_FAILED);
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                ivilayer, wl_fixed_from_double(0.3)) == IVI_SUCCEEDED);
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                ivilayer, wl_fixed_from_double(-1)) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_opacity(ivilayer) == wl_fixed_from_double(0.3));
+       iassert(lyt->layer_get_opacity(ivilayer) == wl_fixed_from_double(0.3));
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                ivilayer, wl_fixed_from_double(1.1)) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_opacity(ivilayer) == wl_fixed_from_double(0.3));
+       iassert(lyt->layer_get_opacity(ivilayer) == wl_fixed_from_double(0.3));
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                NULL, wl_fixed_from_double(0.5)) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_opacity(NULL) == wl_fixed_from_double(0.0));
+       iassert(lyt->layer_get_opacity(NULL) == wl_fixed_from_double(0.0));
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_bad_destination_rectangle(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->layer_set_destination_rectangle(
+       iassert(lyt->layer_set_destination_rectangle(
                NULL, 20, 30, 200, 300) == IVI_FAILED);
 }
 
 static void
 test_layer_bad_orientation(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->layer_set_orientation(
+       iassert(lyt->layer_set_orientation(
                NULL, WL_OUTPUT_TRANSFORM_90) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_orientation(NULL) == WL_OUTPUT_TRANSFORM_NORMAL);
+       iassert(lyt->layer_get_orientation(NULL) == WL_OUTPUT_TRANSFORM_NORMAL);
 }
 
 static void
 test_layer_bad_dimension(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        int32_t dest_width;
        int32_t dest_height;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_dimension(NULL, 200, 300) == IVI_FAILED);
+       iassert(lyt->layer_set_dimension(NULL, 200, 300) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_dimension(
+       iassert(lyt->layer_get_dimension(
                NULL, &dest_width, &dest_height) == IVI_FAILED);
-       iassert(ctl->layer_get_dimension(
+       iassert(lyt->layer_get_dimension(
                ivilayer, NULL, &dest_height) == IVI_FAILED);
-       iassert(ctl->layer_get_dimension(
+       iassert(lyt->layer_get_dimension(
                ivilayer, &dest_width, NULL) == IVI_FAILED);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_bad_position(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        int32_t dest_x;
        int32_t dest_y;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_position(NULL, 20, 30) == IVI_FAILED);
+       iassert(lyt->layer_set_position(NULL, 20, 30) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->layer_get_position(NULL, &dest_x, &dest_y) == IVI_FAILED);
-       iassert(ctl->layer_get_position(ivilayer, NULL, &dest_y) == IVI_FAILED);
-       iassert(ctl->layer_get_position(ivilayer, &dest_x, NULL) == IVI_FAILED);
+       iassert(lyt->layer_get_position(NULL, &dest_x, &dest_y) == IVI_FAILED);
+       iassert(lyt->layer_get_position(ivilayer, NULL, &dest_y) == IVI_FAILED);
+       iassert(lyt->layer_get_position(ivilayer, &dest_x, NULL) == IVI_FAILED);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_layer_bad_source_rectangle(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->layer_set_source_rectangle(
+       iassert(lyt->layer_set_source_rectangle(
                NULL, 20, 30, 200, 300) == IVI_FAILED);
 }
 
 static void
 test_layer_bad_properties(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->get_properties_of_layer(NULL) == NULL);
+       iassert(lyt->get_properties_of_layer(NULL) == NULL);
 }
 
 static void
 test_commit_changes_after_visibility_set_layer_destroy(struct test_context 
*ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_visibility(ivilayer, true) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       iassert(lyt->layer_set_visibility(ivilayer, true) == IVI_SUCCEEDED);
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_commit_changes_after_opacity_set_layer_destroy(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_opacity(
+       iassert(lyt->layer_set_opacity(
                    ivilayer, wl_fixed_from_double(0.5)) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_commit_changes_after_orientation_set_layer_destroy(struct test_context 
*ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_orientation(
+       iassert(lyt->layer_set_orientation(
                    ivilayer, WL_OUTPUT_TRANSFORM_90) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_commit_changes_after_dimension_set_layer_destroy(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_dimension(ivilayer, 200, 300) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       iassert(lyt->layer_set_dimension(ivilayer, 200, 300) == IVI_SUCCEEDED);
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_commit_changes_after_position_set_layer_destroy(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_position(ivilayer, 20, 30) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       iassert(lyt->layer_set_position(ivilayer, 20, 30) == IVI_SUCCEEDED);
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_commit_changes_after_source_rectangle_set_layer_destroy(struct 
test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_source_rectangle(
+       iassert(lyt->layer_set_source_rectangle(
                    ivilayer, 20, 30, 200, 300) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_commit_changes_after_destination_rectangle_set_layer_destroy(struct 
test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       iassert(ctl->layer_set_destination_rectangle(
+       iassert(lyt->layer_set_destination_rectangle(
                    ivilayer, 20, 30, 200, 300) == IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayer);
-       ctl->commit_changes();
+       lyt->layer_destroy(ivilayer);
+       lyt->commit_changes();
 }
 
 static void
 test_layer_create_duplicate(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_layer *duplicatelayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
        if (ivilayer != NULL)
                iassert(ivilayer->ref_count == 1);
 
-       duplicatelayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 
200, 300);
+       duplicatelayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 
200, 300);
        iassert(ivilayer == duplicatelayer);
 
        if (ivilayer != NULL)
                iassert(ivilayer->ref_count == 2);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 
        if (ivilayer != NULL)
                iassert(ivilayer->ref_count == 1);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_get_layer_after_destory_layer(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
        iassert(ivilayer != NULL);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 
-       ivilayer = ctl->get_layer_from_id(IVI_TEST_LAYER_ID(0));
+       ivilayer = lyt->get_layer_from_id(IVI_TEST_LAYER_ID(0));
        iassert(ivilayer == NULL);
 }
 
 static void
 test_screen_id(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_screen **iviscrns;
        int32_t screen_length = 0;
        uint32_t id_screen;
        int32_t i;
 
-       iassert(ctl->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
+       iassert(lyt->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
        iassert(screen_length > 0);
 
        for (i = 0; i < screen_length; ++i) {
-               id_screen = ctl->get_id_of_screen(iviscrns[i]);
-               iassert(ctl->get_screen_from_id(id_screen) == iviscrns[i]);
+               id_screen = lyt->get_id_of_screen(iviscrns[i]);
+               iassert(lyt->get_screen_from_id(id_screen) == iviscrns[i]);
        }
 
        if (screen_length > 0)
@@ -725,7 +725,7 @@ test_screen_id(struct test_context *ctx)
 static void
 test_screen_resolution(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_screen **iviscrns;
        int32_t screen_length = 0;
        struct weston_output *output;
@@ -733,13 +733,13 @@ test_screen_resolution(struct test_context *ctx)
        int32_t height;
        int32_t i;
 
-       iassert(ctl->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
+       iassert(lyt->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
        iassert(screen_length > 0);
 
        for (i = 0; i < screen_length; ++i) {
-               output = ctl->screen_get_output(iviscrns[i]);
+               output = lyt->screen_get_output(iviscrns[i]);
                iassert(output != NULL);
-               iassert(ctl->get_screen_resolution(
+               iassert(lyt->get_screen_resolution(
                            iviscrns[i], &width, &height) == IVI_SUCCEEDED);
                iassert(width == output->current_mode->width);
                iassert(height == output->current_mode->height);
@@ -753,7 +753,7 @@ static void
 test_screen_render_order(struct test_context *ctx)
 {
 #define LAYER_NUM (3)
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_screen **iviscrns;
        int32_t screen_length = 0;
        struct ivi_layout_screen *iviscrn;
@@ -762,7 +762,7 @@ test_screen_render_order(struct test_context *ctx)
        int32_t length = 0;
        uint32_t i;
 
-       iassert(ctl->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
+       iassert(lyt->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
        iassert(screen_length > 0);
 
        if (screen_length <= 0)
@@ -771,13 +771,13 @@ test_screen_render_order(struct test_context *ctx)
        iviscrn = iviscrns[0];
 
        for (i = 0; i < LAYER_NUM; i++)
-               ivilayers[i] = 
ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(i), 200, 300);
+               ivilayers[i] = 
lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(i), 200, 300);
 
-       iassert(ctl->screen_set_render_order(iviscrn, ivilayers, LAYER_NUM) == 
IVI_SUCCEEDED);
+       iassert(lyt->screen_set_render_order(iviscrn, ivilayers, LAYER_NUM) == 
IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->get_layers_on_screen(iviscrn, &length, &array) == 
IVI_SUCCEEDED);
+       iassert(lyt->get_layers_on_screen(iviscrn, &length, &array) == 
IVI_SUCCEEDED);
        iassert(length == LAYER_NUM);
        for (i = 0; i < LAYER_NUM; i++)
                iassert(array[i] == ivilayers[i]);
@@ -787,15 +787,15 @@ test_screen_render_order(struct test_context *ctx)
 
        array = NULL;
 
-       iassert(ctl->screen_set_render_order(iviscrn, NULL, 0) == 
IVI_SUCCEEDED);
+       iassert(lyt->screen_set_render_order(iviscrn, NULL, 0) == 
IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->get_layers_on_screen(iviscrn, &length, &array) == 
IVI_SUCCEEDED);
+       iassert(lyt->get_layers_on_screen(iviscrn, &length, &array) == 
IVI_SUCCEEDED);
        iassert(length == 0 && array == NULL);
 
        for (i = 0; i < LAYER_NUM; i++)
-               ctl->layer_destroy(ivilayers[i]);
+               lyt->layer_destroy(ivilayers[i]);
 
        free(iviscrns);
 #undef LAYER_NUM
@@ -804,23 +804,23 @@ test_screen_render_order(struct test_context *ctx)
 static void
 test_screen_bad_resolution(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_screen **iviscrns;
        int32_t screen_length = 0;
        struct ivi_layout_screen *iviscrn;
        int32_t width;
        int32_t height;
 
-       iassert(ctl->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
+       iassert(lyt->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
        iassert(screen_length > 0);
 
        if (screen_length <= 0)
                return;
 
        iviscrn = iviscrns[0];
-       iassert(ctl->get_screen_resolution(NULL, &width, &height) == 
IVI_FAILED);
-       iassert(ctl->get_screen_resolution(iviscrn, NULL, &height) == 
IVI_FAILED);
-       iassert(ctl->get_screen_resolution(iviscrn, &width, NULL) == 
IVI_FAILED);
+       iassert(lyt->get_screen_resolution(NULL, &width, &height) == 
IVI_FAILED);
+       iassert(lyt->get_screen_resolution(iviscrn, NULL, &height) == 
IVI_FAILED);
+       iassert(lyt->get_screen_resolution(iviscrn, &width, NULL) == 
IVI_FAILED);
        free(iviscrns);
 }
 
@@ -828,7 +828,7 @@ static void
 test_screen_bad_render_order(struct test_context *ctx)
 {
 #define LAYER_NUM (3)
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_screen **iviscrns;
        int32_t screen_length;
        struct ivi_layout_screen *iviscrn;
@@ -837,7 +837,7 @@ test_screen_bad_render_order(struct test_context *ctx)
        int32_t length = 0;
        uint32_t i;
 
-       iassert(ctl->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
+       iassert(lyt->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
        iassert(screen_length > 0);
 
        if (screen_length <= 0)
@@ -846,18 +846,18 @@ test_screen_bad_render_order(struct test_context *ctx)
        iviscrn = iviscrns[0];
 
        for (i = 0; i < LAYER_NUM; i++)
-               ivilayers[i] = 
ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(i), 200, 300);
+               ivilayers[i] = 
lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(i), 200, 300);
 
-       iassert(ctl->screen_set_render_order(NULL, ivilayers, LAYER_NUM) == 
IVI_FAILED);
+       iassert(lyt->screen_set_render_order(NULL, ivilayers, LAYER_NUM) == 
IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       iassert(ctl->get_layers_on_screen(NULL, &length, &array) == IVI_FAILED);
-       iassert(ctl->get_layers_on_screen(iviscrn, NULL, &array) == IVI_FAILED);
-       iassert(ctl->get_layers_on_screen(iviscrn, &length, NULL) == 
IVI_FAILED);
+       iassert(lyt->get_layers_on_screen(NULL, &length, &array) == IVI_FAILED);
+       iassert(lyt->get_layers_on_screen(iviscrn, NULL, &array) == IVI_FAILED);
+       iassert(lyt->get_layers_on_screen(iviscrn, &length, NULL) == 
IVI_FAILED);
 
        for (i = 0; i < LAYER_NUM; i++)
-               ctl->layer_destroy(ivilayers[i]);
+               lyt->layer_destroy(ivilayers[i]);
 
        free(iviscrns);
 #undef LAYER_NUM
@@ -868,14 +868,14 @@ test_commit_changes_after_render_order_set_layer_destroy(
        struct test_context *ctx)
 {
 #define LAYER_NUM (3)
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_screen **iviscrns;
        int32_t screen_length;
        struct ivi_layout_screen *iviscrn;
        struct ivi_layout_layer *ivilayers[LAYER_NUM] = {};
        uint32_t i;
 
-       iassert(ctl->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
+       iassert(lyt->get_screens(&screen_length, &iviscrns) == IVI_SUCCEEDED);
        iassert(screen_length > 0);
 
        if (screen_length <= 0)
@@ -884,16 +884,16 @@ test_commit_changes_after_render_order_set_layer_destroy(
        iviscrn = iviscrns[0];
 
        for (i = 0; i < LAYER_NUM; i++)
-               ivilayers[i] = 
ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(i), 200, 300);
+               ivilayers[i] = 
lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(i), 200, 300);
 
-       iassert(ctl->screen_set_render_order(iviscrn, ivilayers, LAYER_NUM) == 
IVI_SUCCEEDED);
+       iassert(lyt->screen_set_render_order(iviscrn, ivilayers, LAYER_NUM) == 
IVI_SUCCEEDED);
 
-       ctl->layer_destroy(ivilayers[1]);
+       lyt->layer_destroy(ivilayers[1]);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       ctl->layer_destroy(ivilayers[0]);
-       ctl->layer_destroy(ivilayers[2]);
+       lyt->layer_destroy(ivilayers[0]);
+       lyt->layer_destroy(ivilayers[2]);
 
        free(iviscrns);
 #undef LAYER_NUM
@@ -906,13 +906,13 @@ 
test_layer_properties_changed_notification_callback(struct ivi_layout_layer *ivi
                                                    void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0));
+       iassert(lyt->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0));
        iassert(prop->source_width == 200);
        iassert(prop->source_height == 300);
 
-       if (ctl->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0) &&
+       if (lyt->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0) &&
            prop->source_width == 200 && prop->source_height == 300)
                ctx->user_flags = 1;
 }
@@ -920,42 +920,42 @@ 
test_layer_properties_changed_notification_callback(struct ivi_layout_layer *ivi
 static void
 test_layer_properties_changed_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
        ctx->user_flags = 0;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
 
-       iassert(ctl->layer_add_notification(ivilayer, 
test_layer_properties_changed_notification_callback, ctx) == IVI_SUCCEEDED);
+       iassert(lyt->layer_add_notification(ivilayer, 
test_layer_properties_changed_notification_callback, ctx) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        iassert(ctx->user_flags == 0);
 
-       iassert(ctl->layer_set_destination_rectangle(
+       iassert(lyt->layer_set_destination_rectangle(
                ivilayer, 20, 30, 200, 300) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        iassert(ctx->user_flags == 1);
 
        ctx->user_flags = 0;
-       iassert(ctl->layer_set_destination_rectangle(
+       iassert(lyt->layer_set_destination_rectangle(
                ivilayer, 20, 30, 200, 300) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        iassert(ctx->user_flags == 0);
 
-       ctl->layer_remove_notification(ivilayer);
+       lyt->layer_remove_notification(ivilayer);
 
        ctx->user_flags = 0;
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        iassert(ctx->user_flags == 0);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
@@ -963,14 +963,14 @@ test_layer_create_notification_callback(struct 
ivi_layout_layer *ivilayer,
                                        void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
-       const struct ivi_layout_layer_properties *prop = 
ctl->get_properties_of_layer(ivilayer);
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
+       const struct ivi_layout_layer_properties *prop = 
lyt->get_properties_of_layer(ivilayer);
 
-       iassert(ctl->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0));
+       iassert(lyt->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0));
        iassert(prop->source_width == 200);
        iassert(prop->source_height == 300);
 
-       if (ctl->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0) &&
+       if (lyt->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0) &&
            prop->source_width == 200 && prop->source_height == 300)
                ctx->user_flags = 1;
 }
@@ -979,27 +979,27 @@ static void
 test_layer_create_notification(struct test_context *ctx)
 {
 #define LAYER_NUM (2)
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        static const uint32_t layers[LAYER_NUM] = {IVI_TEST_LAYER_ID(0), 
IVI_TEST_LAYER_ID(1)};
        struct ivi_layout_layer *ivilayers[LAYER_NUM] = {};
 
        ctx->user_flags = 0;
 
-       iassert(ctl->add_notification_create_layer(
+       iassert(lyt->add_notification_create_layer(
                    test_layer_create_notification_callback, ctx) == 
IVI_SUCCEEDED);
-       ivilayers[0] = ctl->layer_create_with_dimension(layers[0], 200, 300);
+       ivilayers[0] = lyt->layer_create_with_dimension(layers[0], 200, 300);
 
        iassert(ctx->user_flags == 1);
 
        ctx->user_flags = 0;
-       
ctl->remove_notification_create_layer(test_layer_create_notification_callback, 
ctx);
+       
lyt->remove_notification_create_layer(test_layer_create_notification_callback, 
ctx);
 
-       ivilayers[1] = ctl->layer_create_with_dimension(layers[1], 400, 500);
+       ivilayers[1] = lyt->layer_create_with_dimension(layers[1], 400, 500);
 
        iassert(ctx->user_flags == 0);
 
-       ctl->layer_destroy(ivilayers[0]);
-       ctl->layer_destroy(ivilayers[1]);
+       lyt->layer_destroy(ivilayers[0]);
+       lyt->layer_destroy(ivilayers[1]);
 #undef LAYER_NUM
 }
 
@@ -1008,15 +1008,15 @@ test_layer_remove_notification_callback(struct 
ivi_layout_layer *ivilayer,
                                        void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        const struct ivi_layout_layer_properties *prop =
-               ctl->get_properties_of_layer(ivilayer);
+               lyt->get_properties_of_layer(ivilayer);
 
-       iassert(ctl->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0));
+       iassert(lyt->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0));
        iassert(prop->source_width == 200);
        iassert(prop->source_height == 300);
 
-       if (ctl->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0) &&
+       if (lyt->get_id_of_layer(ivilayer) == IVI_TEST_LAYER_ID(0) &&
            prop->source_width == 200 && prop->source_height == 300)
                ctx->user_flags = 1;
 }
@@ -1025,23 +1025,23 @@ static void
 test_layer_remove_notification(struct test_context *ctx)
 {
 #define LAYER_NUM (2)
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        static const uint32_t layers[LAYER_NUM] = {IVI_TEST_LAYER_ID(0), 
IVI_TEST_LAYER_ID(1)};
        struct ivi_layout_layer *ivilayers[LAYER_NUM] = {};
 
        ctx->user_flags = 0;
 
-       ivilayers[0] = ctl->layer_create_with_dimension(layers[0], 200, 300);
-       iassert(ctl->add_notification_remove_layer(
+       ivilayers[0] = lyt->layer_create_with_dimension(layers[0], 200, 300);
+       iassert(lyt->add_notification_remove_layer(
                    test_layer_remove_notification_callback, ctx) == 
IVI_SUCCEEDED);
-       ctl->layer_destroy(ivilayers[0]);
+       lyt->layer_destroy(ivilayers[0]);
 
        iassert(ctx->user_flags == 1);
 
        ctx->user_flags = 0;
-       ivilayers[1] = ctl->layer_create_with_dimension(layers[1], 250, 350);
-       
ctl->remove_notification_remove_layer(test_layer_remove_notification_callback, 
ctx);
-       ctl->layer_destroy(ivilayers[1]);
+       ivilayers[1] = lyt->layer_create_with_dimension(layers[1], 250, 350);
+       
lyt->remove_notification_remove_layer(test_layer_remove_notification_callback, 
ctx);
+       lyt->layer_destroy(ivilayers[1]);
 
        iassert(ctx->user_flags == 0);
 #undef LAYER_NUM
@@ -1058,56 +1058,56 @@ 
test_layer_bad_properties_changed_notification_callback(struct ivi_layout_layer
 static void
 test_layer_bad_properties_changed_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
 
-       iassert(ctl->layer_add_notification(
+       iassert(lyt->layer_add_notification(
                    NULL, 
test_layer_bad_properties_changed_notification_callback, NULL) == IVI_FAILED);
-       iassert(ctl->layer_add_notification(ivilayer, NULL, NULL) == 
IVI_FAILED);
+       iassert(lyt->layer_add_notification(ivilayer, NULL, NULL) == 
IVI_FAILED);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
 test_surface_bad_configure_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->add_notification_configure_surface(NULL, NULL) == 
IVI_FAILED);
+       iassert(lyt->add_notification_configure_surface(NULL, NULL) == 
IVI_FAILED);
 }
 
 static void
 test_layer_bad_create_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->add_notification_create_layer(NULL, NULL) == IVI_FAILED);
+       iassert(lyt->add_notification_create_layer(NULL, NULL) == IVI_FAILED);
 }
 
 static void
 test_surface_bad_create_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->add_notification_create_surface(NULL, NULL) == IVI_FAILED);
+       iassert(lyt->add_notification_create_surface(NULL, NULL) == IVI_FAILED);
 }
 
 static void
 test_layer_bad_remove_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->add_notification_remove_layer(NULL, NULL) == IVI_FAILED);
+       iassert(lyt->add_notification_remove_layer(NULL, NULL) == IVI_FAILED);
 }
 
 static void
 test_surface_bad_remove_notification(struct test_context *ctx)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       iassert(ctl->add_notification_remove_surface(NULL, NULL) == IVI_FAILED);
+       iassert(lyt->add_notification_remove_surface(NULL, NULL) == IVI_FAILED);
 }
 
 /************************ tests end ********************************/
@@ -1176,13 +1176,13 @@ run_internal_tests(void *data)
 int
 controller_module_init(struct weston_compositor *compositor,
                       int *argc, char *argv[],
-                      const struct ivi_controller_interface *iface,
+                      const struct ivi_layout_interface *iface,
                       size_t iface_version);
 
 WL_EXPORT int
 controller_module_init(struct weston_compositor *compositor,
                       int *argc, char *argv[],
-                      const struct ivi_controller_interface *iface,
+                      const struct ivi_layout_interface *iface,
                       size_t iface_version)
 {
        struct wl_event_loop *loop;
@@ -1199,7 +1199,7 @@ controller_module_init(struct weston_compositor 
*compositor,
                return -1;
 
        ctx->compositor = compositor;
-       ctx->controller_interface = iface;
+       ctx->layout_interface = iface;
 
        loop = wl_display_get_event_loop(compositor->wl_display);
        wl_event_loop_add_idle(loop, run_internal_tests, ctx);
diff --git a/tests/ivi_layout-test-plugin.c b/tests/ivi_layout-test-plugin.c
index 5ac0135..f7b6c3c 100644
--- a/tests/ivi_layout-test-plugin.c
+++ b/tests/ivi_layout-test-plugin.c
@@ -76,11 +76,11 @@ struct test_launcher {
        struct weston_compositor *compositor;
        char exe[2048];
        struct weston_process process;
-       const struct ivi_controller_interface *controller_interface;
+       const struct ivi_layout_interface *layout_interface;
 };
 
 struct test_context {
-       const struct ivi_controller_interface *controller_interface;
+       const struct ivi_layout_interface *layout_interface;
        struct wl_resource *runner_resource;
        uint32_t user_flags;
 };
@@ -93,7 +93,7 @@ destroy_runner(struct wl_resource *resource)
        assert(static_context.runner_resource == NULL ||
               static_context.runner_resource == resource);
 
-       static_context.controller_interface = NULL;
+       static_context.layout_interface = NULL;
        static_context.runner_resource = NULL;
 }
 
@@ -114,7 +114,7 @@ runner_run_handler(struct wl_client *client, struct 
wl_resource *resource,
               static_context.runner_resource == resource);
 
        launcher = wl_resource_get_user_data(resource);
-       static_context.controller_interface = launcher->controller_interface;
+       static_context.layout_interface = launcher->layout_interface;
        static_context.runner_resource = resource;
 
        t = find_runner_test(test_name);
@@ -213,13 +213,13 @@ idle_launch_client(void *data)
 int
 controller_module_init(struct weston_compositor *compositor,
                       int *argc, char *argv[],
-                      const struct ivi_controller_interface *iface,
+                      const struct ivi_layout_interface *iface,
                       size_t iface_version);
 
 WL_EXPORT int
 controller_module_init(struct weston_compositor *compositor,
                       int *argc, char *argv[],
-                      const struct ivi_controller_interface *iface,
+                      const struct ivi_layout_interface *iface,
                       size_t iface_version)
 {
        struct wl_event_loop *loop;
@@ -243,7 +243,7 @@ controller_module_init(struct weston_compositor *compositor,
                return -1;
 
        launcher->compositor = compositor;
-       launcher->controller_interface = iface;
+       launcher->layout_interface = iface;
        snprintf(launcher->exe, sizeof launcher->exe,
                 "%s/ivi-layout.ivi", path);
 
@@ -324,145 +324,145 @@ runner_assert_fail(const char *cond, const char *file, 
int line,
 
 RUNNER_TEST(surface_create_p1)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf[2];
        uint32_t ivi_id;
 
-       ivisurf[0] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf[0] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf[0]);
 
-       ivisurf[1] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(1));
+       ivisurf[1] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(1));
        runner_assert(ivisurf[1]);
 
-       ivi_id = ctl->get_id_of_surface(ivisurf[0]);
+       ivi_id = lyt->get_id_of_surface(ivisurf[0]);
        runner_assert(ivi_id == IVI_TEST_SURFACE_ID(0));
 
-       ivi_id = ctl->get_id_of_surface(ivisurf[1]);
+       ivi_id = lyt->get_id_of_surface(ivisurf[1]);
        runner_assert(ivi_id == IVI_TEST_SURFACE_ID(1));
 }
 
 RUNNER_TEST(surface_create_p2)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
        /* the ivi_surface was destroyed by the client */
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf == NULL);
 }
 
 RUNNER_TEST(surface_visibility)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        int32_t ret;
        bool visibility;
        const struct ivi_layout_surface_properties *prop;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf);
 
-       ret = ctl->surface_set_visibility(ivisurf, true);
+       ret = lyt->surface_set_visibility(ivisurf, true);
        runner_assert(ret == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       visibility = ctl->surface_get_visibility(ivisurf);
+       visibility = lyt->surface_get_visibility(ivisurf);
        runner_assert(visibility == true);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert(prop->visibility == true);
 }
 
 RUNNER_TEST(surface_opacity)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        int32_t ret;
        wl_fixed_t opacity;
        const struct ivi_layout_surface_properties *prop;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf);
 
-       runner_assert(ctl->surface_get_opacity(ivisurf) ==
+       runner_assert(lyt->surface_get_opacity(ivisurf) ==
                      wl_fixed_from_double(1.0));
 
-       ret = ctl->surface_set_opacity(ivisurf, wl_fixed_from_double(0.5));
+       ret = lyt->surface_set_opacity(ivisurf, wl_fixed_from_double(0.5));
        runner_assert(ret == IVI_SUCCEEDED);
 
-       runner_assert(ctl->surface_get_opacity(ivisurf) ==
+       runner_assert(lyt->surface_get_opacity(ivisurf) ==
                      wl_fixed_from_double(1.0));
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       opacity = ctl->surface_get_opacity(ivisurf);
+       opacity = lyt->surface_get_opacity(ivisurf);
        runner_assert(opacity == wl_fixed_from_double(0.5));
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert(prop->opacity == wl_fixed_from_double(0.5));
 }
 
 RUNNER_TEST(surface_orientation)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        const struct ivi_layout_surface_properties *prop;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       runner_assert(ctl->surface_get_orientation(ivisurf) ==
+       runner_assert(lyt->surface_get_orientation(ivisurf) ==
                      WL_OUTPUT_TRANSFORM_NORMAL);
 
-       runner_assert(ctl->surface_set_orientation(
+       runner_assert(lyt->surface_set_orientation(
                      ivisurf, WL_OUTPUT_TRANSFORM_90) == IVI_SUCCEEDED);
 
-       runner_assert(ctl->surface_get_orientation(ivisurf) ==
+       runner_assert(lyt->surface_get_orientation(ivisurf) ==
                      WL_OUTPUT_TRANSFORM_NORMAL);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->surface_get_orientation(
+       runner_assert(lyt->surface_get_orientation(
                      ivisurf) == WL_OUTPUT_TRANSFORM_90);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->orientation == WL_OUTPUT_TRANSFORM_90);
 }
 
 RUNNER_TEST(surface_dimension)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        const struct ivi_layout_surface_properties *prop;
        int32_t dest_width;
        int32_t dest_height;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       runner_assert(ctl->surface_get_dimension(
+       runner_assert(lyt->surface_get_dimension(
                      ivisurf, &dest_width, &dest_height) == IVI_SUCCEEDED);
        runner_assert(dest_width == 1);
        runner_assert(dest_height == 1);
 
        runner_assert(IVI_SUCCEEDED ==
-                     ctl->surface_set_dimension(ivisurf, 200, 300));
+                     lyt->surface_set_dimension(ivisurf, 200, 300));
 
-       runner_assert(ctl->surface_get_dimension(
+       runner_assert(lyt->surface_get_dimension(
                      ivisurf, &dest_width, &dest_height) == IVI_SUCCEEDED);
        runner_assert(dest_width == 1);
        runner_assert(dest_height == 1);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->surface_get_dimension(
+       runner_assert(lyt->surface_get_dimension(
                      ivisurf, &dest_width, &dest_height) == IVI_SUCCEEDED);
        runner_assert(dest_width == 200);
        runner_assert(dest_height == 300);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->dest_width == 200);
        runner_assert(prop->dest_height == 300);
@@ -470,36 +470,36 @@ RUNNER_TEST(surface_dimension)
 
 RUNNER_TEST(surface_position)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        const struct ivi_layout_surface_properties *prop;
        int32_t dest_x;
        int32_t dest_y;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       runner_assert(ctl->surface_get_position(
+       runner_assert(lyt->surface_get_position(
                      ivisurf, &dest_x, &dest_y) == IVI_SUCCEEDED);
        runner_assert(dest_x == 0);
        runner_assert(dest_y == 0);
 
-       runner_assert(ctl->surface_set_position(
+       runner_assert(lyt->surface_set_position(
                      ivisurf, 20, 30) == IVI_SUCCEEDED);
 
-       runner_assert(ctl->surface_get_position(
+       runner_assert(lyt->surface_get_position(
                      ivisurf, &dest_x, &dest_y) == IVI_SUCCEEDED);
        runner_assert(dest_x == 0);
        runner_assert(dest_y == 0);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->surface_get_position(
+       runner_assert(lyt->surface_get_position(
                      ivisurf, &dest_x, &dest_y) == IVI_SUCCEEDED);
        runner_assert(dest_x == 20);
        runner_assert(dest_y == 30);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->dest_x == 20);
        runner_assert(prop->dest_y == 30);
@@ -507,7 +507,7 @@ RUNNER_TEST(surface_position)
 
 RUNNER_TEST(surface_destination_rectangle)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        const struct ivi_layout_surface_properties *prop;
        int32_t dest_width;
@@ -515,38 +515,38 @@ RUNNER_TEST(surface_destination_rectangle)
        int32_t dest_x;
        int32_t dest_y;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->dest_width == 1);
        runner_assert(prop->dest_height == 1);
        runner_assert(prop->dest_x == 0);
        runner_assert(prop->dest_y == 0);
 
-       runner_assert(ctl->surface_set_destination_rectangle(
+       runner_assert(lyt->surface_set_destination_rectangle(
                      ivisurf, 20, 30, 200, 300) == IVI_SUCCEEDED);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->dest_width == 1);
        runner_assert(prop->dest_height == 1);
        runner_assert(prop->dest_x == 0);
        runner_assert(prop->dest_y == 0);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->surface_get_dimension(
+       runner_assert(lyt->surface_get_dimension(
                      ivisurf, &dest_width, &dest_height) == IVI_SUCCEEDED);
        runner_assert(dest_width == 200);
        runner_assert(dest_height == 300);
 
-       runner_assert(ctl->surface_get_position(ivisurf, &dest_x, &dest_y) == 
IVI_SUCCEEDED);
+       runner_assert(lyt->surface_get_position(ivisurf, &dest_x, &dest_y) == 
IVI_SUCCEEDED);
        runner_assert(dest_x == 20);
        runner_assert(dest_y == 30);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->dest_width == 200);
        runner_assert(prop->dest_height == 300);
@@ -556,33 +556,33 @@ RUNNER_TEST(surface_destination_rectangle)
 
 RUNNER_TEST(surface_source_rectangle)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        const struct ivi_layout_surface_properties *prop;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->source_width == 0);
        runner_assert(prop->source_height == 0);
        runner_assert(prop->source_x == 0);
        runner_assert(prop->source_y == 0);
 
-       runner_assert(ctl->surface_set_source_rectangle(
+       runner_assert(lyt->surface_set_source_rectangle(
                      ivisurf, 20, 30, 200, 300) == IVI_SUCCEEDED);
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->source_width == 0);
        runner_assert(prop->source_height == 0);
        runner_assert(prop->source_x == 0);
        runner_assert(prop->source_y == 0);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       prop = ctl->get_properties_of_surface(ivisurf);
+       prop = lyt->get_properties_of_surface(ivisurf);
        runner_assert_or_return(prop);
        runner_assert(prop->source_width == 200);
        runner_assert(prop->source_height == 300);
@@ -592,157 +592,157 @@ RUNNER_TEST(surface_source_rectangle)
 
 RUNNER_TEST(surface_bad_opacity)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
        wl_fixed_t opacity;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       runner_assert(ctl->surface_set_opacity(
+       runner_assert(lyt->surface_set_opacity(
                      NULL, wl_fixed_from_double(0.3)) == IVI_FAILED);
 
-       runner_assert(ctl->surface_set_opacity(
+       runner_assert(lyt->surface_set_opacity(
                      ivisurf, wl_fixed_from_double(0.3)) == IVI_SUCCEEDED);
 
-       runner_assert(ctl->surface_set_opacity(
+       runner_assert(lyt->surface_set_opacity(
                      ivisurf, wl_fixed_from_double(-1)) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       opacity = ctl->surface_get_opacity(ivisurf);
+       opacity = lyt->surface_get_opacity(ivisurf);
        runner_assert(opacity == wl_fixed_from_double(0.3));
 
-       runner_assert(ctl->surface_set_opacity(
+       runner_assert(lyt->surface_set_opacity(
                      ivisurf, wl_fixed_from_double(1.1)) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       opacity = ctl->surface_get_opacity(ivisurf);
+       opacity = lyt->surface_get_opacity(ivisurf);
        runner_assert(opacity == wl_fixed_from_double(0.3));
 
-       runner_assert(ctl->surface_set_opacity(
+       runner_assert(lyt->surface_set_opacity(
                      NULL, wl_fixed_from_double(0.5)) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       opacity = ctl->surface_get_opacity(NULL);
+       opacity = lyt->surface_get_opacity(NULL);
        runner_assert(opacity == wl_fixed_from_double(0.0));
 }
 
 RUNNER_TEST(ivi_layout_commit_changes)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 }
 
 RUNNER_TEST(commit_changes_after_visibility_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_visibility(
+       runner_assert(lyt->surface_set_visibility(
                      ivisurf, true) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(commit_changes_after_opacity_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_opacity(
+       runner_assert(lyt->surface_set_opacity(
                      ivisurf, wl_fixed_from_double(0.5)) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(commit_changes_after_orientation_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_orientation(
+       runner_assert(lyt->surface_set_orientation(
                      ivisurf, WL_OUTPUT_TRANSFORM_90) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(commit_changes_after_dimension_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_dimension(
+       runner_assert(lyt->surface_set_dimension(
                      ivisurf, 200, 300) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(commit_changes_after_position_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_position(
+       runner_assert(lyt->surface_set_position(
                      ivisurf, 20, 30) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(commit_changes_after_source_rectangle_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_source_rectangle(
+       runner_assert(lyt->surface_set_source_rectangle(
                      ivisurf, 20, 30, 200, 300) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(commit_changes_after_destination_rectangle_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
-       runner_assert(ctl->surface_set_destination_rectangle(
+       runner_assert(lyt->surface_set_destination_rectangle(
                      ivisurf, 20, 30, 200, 300) == IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(get_surface_after_destroy_surface)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf == NULL);
 }
 
 RUNNER_TEST(layer_render_order)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_surface *ivisurfs[IVI_TEST_SURFACE_COUNT] = {};
        struct ivi_layout_surface **array;
        int32_t length = 0;
        uint32_t i;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
 
        for (i = 0; i < IVI_TEST_SURFACE_COUNT; i++)
-               ivisurfs[i] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
+               ivisurfs[i] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
 
-       runner_assert(ctl->layer_set_render_order(
+       runner_assert(lyt->layer_set_render_order(
                      ivilayer, ivisurfs, IVI_TEST_SURFACE_COUNT) == 
IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      ivilayer, &length, &array) == IVI_SUCCEEDED);
        runner_assert(IVI_TEST_SURFACE_COUNT == length);
        for (i = 0; i < IVI_TEST_SURFACE_COUNT; i++)
@@ -751,40 +751,40 @@ RUNNER_TEST(layer_render_order)
        if (length > 0)
                free(array);
 
-       runner_assert(ctl->layer_set_render_order(
+       runner_assert(lyt->layer_set_render_order(
                      ivilayer, NULL, 0) == IVI_SUCCEEDED);
 
        array = NULL;
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      ivilayer, &length, &array) == IVI_SUCCEEDED);
        runner_assert(length == 0 && array == NULL);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 RUNNER_TEST(test_layer_render_order_destroy_one_surface_p1)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_surface *ivisurfs[IVI_TEST_SURFACE_COUNT] = {};
        struct ivi_layout_surface **array;
        int32_t length = 0;
        int32_t i;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
 
        for (i = 0; i < IVI_TEST_SURFACE_COUNT; i++)
-               ivisurfs[i] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
+               ivisurfs[i] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
 
-       runner_assert(ctl->layer_set_render_order(
+       runner_assert(lyt->layer_set_render_order(
                      ivilayer, ivisurfs, IVI_TEST_SURFACE_COUNT) == 
IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      ivilayer, &length, &array) == IVI_SUCCEEDED);
        runner_assert(IVI_TEST_SURFACE_COUNT == length);
        for (i = 0; i < length; i++)
@@ -796,18 +796,18 @@ 
RUNNER_TEST(test_layer_render_order_destroy_one_surface_p1)
 
 RUNNER_TEST(test_layer_render_order_destroy_one_surface_p2)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_surface *ivisurfs[2] = {};
        struct ivi_layout_surface **array;
        int32_t length = 0;
        int32_t i;
 
-       ivilayer = ctl->get_layer_from_id(IVI_TEST_LAYER_ID(0));
-       ivisurfs[0] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
-       ivisurfs[1] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(2));
+       ivilayer = lyt->get_layer_from_id(IVI_TEST_LAYER_ID(0));
+       ivisurfs[0] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurfs[1] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(2));
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      ivilayer, &length, &array) == IVI_SUCCEEDED);
        runner_assert(2 == length);
        for (i = 0; i < length; i++)
@@ -816,66 +816,66 @@ 
RUNNER_TEST(test_layer_render_order_destroy_one_surface_p2)
        if (length > 0)
                free(array);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 RUNNER_TEST(layer_bad_render_order)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_surface *ivisurfs[IVI_TEST_SURFACE_COUNT] = {};
        struct ivi_layout_surface **array = NULL;
        int32_t length = 0;
        uint32_t i;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
 
        for (i = 0; i < IVI_TEST_SURFACE_COUNT; i++)
-               ivisurfs[i] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
+               ivisurfs[i] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
 
-       runner_assert(ctl->layer_set_render_order(
+       runner_assert(lyt->layer_set_render_order(
                      NULL, ivisurfs, IVI_TEST_SURFACE_COUNT) == IVI_FAILED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      NULL, &length, &array) == IVI_FAILED);
        runner_assert(length == 0 && array == NULL);
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      ivilayer, NULL, &array) == IVI_FAILED);
        runner_assert(array == NULL);
 
-       runner_assert(ctl->get_surfaces_on_layer(
+       runner_assert(lyt->get_surfaces_on_layer(
                      ivilayer, &length, NULL) == IVI_FAILED);
        runner_assert(length == 0);
 
-       ctl->layer_destroy(ivilayer);
+       lyt->layer_destroy(ivilayer);
 }
 
 RUNNER_TEST(commit_changes_after_render_order_set_surface_destroy)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
        struct ivi_layout_surface *ivisurfs[IVI_TEST_SURFACE_COUNT] = {};
        int i;
 
-       ivilayer = ctl->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
+       ivilayer = lyt->layer_create_with_dimension(IVI_TEST_LAYER_ID(0), 200, 
300);
 
        for (i = 0; i < IVI_TEST_SURFACE_COUNT; i++)
-               ivisurfs[i] = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
+               ivisurfs[i] = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(i));
 
-       runner_assert(ctl->layer_set_render_order(
+       runner_assert(lyt->layer_set_render_order(
                      ivilayer, ivisurfs, IVI_TEST_SURFACE_COUNT) == 
IVI_SUCCEEDED);
 }
 
 RUNNER_TEST(cleanup_layer)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_layer *ivilayer;
 
-       ivilayer = ctl->get_layer_from_id(IVI_TEST_LAYER_ID(0));
-       ctl->layer_destroy(ivilayer);
+       ivilayer = lyt->get_layer_from_id(IVI_TEST_LAYER_ID(0));
+       lyt->layer_destroy(ivilayer);
 }
 
 static void
@@ -885,52 +885,52 @@ 
test_surface_properties_changed_notification_callback(struct ivi_layout_surface
                                                      void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert_or_return(ctl->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
+       runner_assert_or_return(lyt->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
 
        ctx->user_flags = 1;
 }
 
 RUNNER_TEST(surface_properties_changed_notification)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        const uint32_t id_surface = IVI_TEST_SURFACE_ID(0);
        struct ivi_layout_surface *ivisurf;
 
        ctx->user_flags = 0;
 
-       ivisurf = ctl->get_surface_from_id(id_surface);
+       ivisurf = lyt->get_surface_from_id(id_surface);
        runner_assert(ivisurf != NULL);
 
-       runner_assert(ctl->surface_add_notification(
+       runner_assert(lyt->surface_add_notification(
                      ivisurf, 
test_surface_properties_changed_notification_callback, ctx) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        runner_assert(ctx->user_flags == 0);
 
-       runner_assert(ctl->surface_set_destination_rectangle(
+       runner_assert(lyt->surface_set_destination_rectangle(
                      ivisurf, 20, 30, 200, 300) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        runner_assert(ctx->user_flags == 1);
 
        ctx->user_flags = 0;
-       runner_assert(ctl->surface_set_destination_rectangle(
+       runner_assert(lyt->surface_set_destination_rectangle(
                      ivisurf, 20, 30, 200, 300) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        runner_assert(ctx->user_flags == 0);
 
-       ctl->surface_remove_notification(ivisurf);
+       lyt->surface_remove_notification(ivisurf);
        ctx->user_flags = 0;
-       runner_assert(ctl->surface_set_destination_rectangle(
+       runner_assert(lyt->surface_set_destination_rectangle(
                      ivisurf, 40, 50, 400, 500) == IVI_SUCCEEDED);
 
-       ctl->commit_changes();
+       lyt->commit_changes();
 
        runner_assert(ctx->user_flags == 0);
 }
@@ -940,38 +940,38 @@ test_surface_configure_notification_callback(struct 
ivi_layout_surface *ivisurf,
                                             void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert_or_return(ctl->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
+       runner_assert_or_return(lyt->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
 
        ctx->user_flags = 1;
 }
 
 RUNNER_TEST(surface_configure_notification_p1)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert(IVI_SUCCEEDED == 
ctl->add_notification_configure_surface(test_surface_configure_notification_callback,
 ctx));
-       ctl->commit_changes();
+       runner_assert(IVI_SUCCEEDED == 
lyt->add_notification_configure_surface(test_surface_configure_notification_callback,
 ctx));
+       lyt->commit_changes();
 
        ctx->user_flags = 0;
 }
 
 RUNNER_TEST(surface_configure_notification_p2)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
        runner_assert(ctx->user_flags == 1);
 
-       
ctl->remove_notification_configure_surface(test_surface_configure_notification_callback,
 ctx);
+       
lyt->remove_notification_configure_surface(test_surface_configure_notification_callback,
 ctx);
        ctx->user_flags = 0;
 }
 
 RUNNER_TEST(surface_configure_notification_p3)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       ctl->commit_changes();
+       lyt->commit_changes();
        runner_assert(ctx->user_flags == 0);
 }
 
@@ -980,18 +980,18 @@ test_surface_create_notification_callback(struct 
ivi_layout_surface *ivisurf,
                                          void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert_or_return(ctl->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
+       runner_assert_or_return(lyt->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
 
        ctx->user_flags = 1;
 }
 
 RUNNER_TEST(surface_create_notification_p1)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert(ctl->add_notification_create_surface(
+       runner_assert(lyt->add_notification_create_surface(
                      test_surface_create_notification_callback, ctx) == 
IVI_SUCCEEDED);
 
        ctx->user_flags = 0;
@@ -999,11 +999,11 @@ RUNNER_TEST(surface_create_notification_p1)
 
 RUNNER_TEST(surface_create_notification_p2)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
        runner_assert(ctx->user_flags == 1);
 
-       ctl->remove_notification_create_surface(
+       lyt->remove_notification_create_surface(
                test_surface_create_notification_callback, ctx);
        ctx->user_flags = 0;
 }
@@ -1018,18 +1018,18 @@ test_surface_remove_notification_callback(struct 
ivi_layout_surface *ivisurf,
                                          void *userdata)
 {
        struct test_context *ctx = userdata;
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert_or_return(ctl->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
+       runner_assert_or_return(lyt->get_id_of_surface(ivisurf) == 
IVI_TEST_SURFACE_ID(0));
 
        ctx->user_flags = 1;
 }
 
 RUNNER_TEST(surface_remove_notification_p1)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
-       runner_assert(ctl->add_notification_remove_surface(
+       runner_assert(lyt->add_notification_remove_surface(
                      test_surface_remove_notification_callback, ctx) == 
IVI_SUCCEEDED);
 
        ctx->user_flags = 0;
@@ -1037,11 +1037,11 @@ RUNNER_TEST(surface_remove_notification_p1)
 
 RUNNER_TEST(surface_remove_notification_p2)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
 
        runner_assert(ctx->user_flags == 1);
 
-       
ctl->remove_notification_remove_surface(test_surface_remove_notification_callback,
 ctx);
+       
lyt->remove_notification_remove_surface(test_surface_remove_notification_callback,
 ctx);
        ctx->user_flags = 0;
 }
 
@@ -1060,14 +1060,14 @@ 
test_surface_bad_properties_changed_notification_callback(struct ivi_layout_surf
 
 RUNNER_TEST(surface_bad_properties_changed_notification)
 {
-       const struct ivi_controller_interface *ctl = ctx->controller_interface;
+       const struct ivi_layout_interface *lyt = ctx->layout_interface;
        struct ivi_layout_surface *ivisurf;
 
-       ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+       ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
        runner_assert(ivisurf != NULL);
 
-       runner_assert(ctl->surface_add_notification(
+       runner_assert(lyt->surface_add_notification(
                      NULL, 
test_surface_bad_properties_changed_notification_callback, NULL) == IVI_FAILED);
-       runner_assert(ctl->surface_add_notification(
+       runner_assert(lyt->surface_add_notification(
                      ivisurf, NULL, NULL) == IVI_FAILED);
 }
-- 
1.7.9.5

_______________________________________________
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel

Reply via email to