--- src/qxl_surface.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-)
diff --git a/src/qxl_surface.c b/src/qxl_surface.c index 1ce6fe5..73a44b3 100644 --- a/src/qxl_surface.c +++ b/src/qxl_surface.c @@ -431,10 +431,9 @@ make_drawable (qxl_screen_t *qxl, int surface, uint8_t type, } static void -push_drawable (qxl_screen_t *qxl, struct QXLDrawable *drawable) +push_drawable (qxl_screen_t *qxl, struct QXLDrawable *drawable, + struct QXLImage *image) { - struct QXLCommand cmd; - /* When someone runs "init 3", the device will be * switched into VGA mode and there is nothing we * can do about it. We get no notification. @@ -446,10 +445,7 @@ push_drawable (qxl_screen_t *qxl, struct QXLDrawable *drawable) */ if (qxl->pScrn->vtSema) { - cmd.type = QXL_CMD_DRAW; - cmd.data = physical_address (qxl, drawable, qxl->main_mem_slot); - - qxl_ring_push (qxl->command_ring, &cmd); + qxlhw_push_drawable (qxl->hw, drawable, image); } } @@ -469,7 +465,7 @@ submit_fill (qxl_screen_t *qxl, int id, drawable->u.fill.mask.pos.y = 0; drawable->u.fill.mask.bitmap = 0; - push_drawable (qxl, drawable); + push_drawable (qxl, drawable, NULL); } static qxl_surface_t * @@ -904,7 +900,7 @@ real_upload_box (qxl_surface_t *surface, int x1, int y1, int x2, int y2) drawable->u.copy.src_bitmap = physical_address (qxl, image, qxl->main_mem_slot); - push_drawable (qxl, drawable); + push_drawable (qxl, drawable, image); } #define TILE_WIDTH 512 @@ -1156,6 +1152,7 @@ qxl_surface_copy (qxl_surface_t *dest, qxl_screen_t *qxl = dest->cache->qxl; struct QXLDrawable *drawable; struct QXLRect qrect; + struct QXLImage *image = NULL; #ifdef DEBUG_REGIONS print_region (" copy src", &(dest->u.copy_src->access_region)); @@ -1176,7 +1173,7 @@ qxl_surface_copy (qxl_surface_t *dest, } else { - struct QXLImage *image = qxl_allocnf (qxl, sizeof *image); + image = qxl_allocnf (qxl, sizeof *image); dest->u.copy_src->ref_count++; @@ -1216,7 +1213,7 @@ qxl_surface_copy (qxl_surface_t *dest, assert (height <= pixman_image_get_height (dest->u.copy_src->host_image)); } - push_drawable (qxl, drawable); + push_drawable (qxl, drawable, image); } Bool @@ -1254,7 +1251,7 @@ qxl_surface_put_image (qxl_surface_t *dest, drawable->u.copy.src_bitmap = physical_address (qxl, image, qxl->main_mem_slot); - push_drawable (qxl, drawable); + push_drawable (qxl, drawable, image); return TRUE; } -- 1.7.9.3 _______________________________________________ Spice-devel mailing list Spice-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/spice-devel