On 04/22/2010 10:26 AM, Coolper Chen wrote:
Hi,I build the spice from git, and do some test. I find one issue when I playing video in windows xp(sp2), here's the steps to reproduce: 1.use KMPlayer to play a video,wait for some time,the spice server will be stuck; 2.use "top" command to watch qemu process, find the process's cpu usage rate is 100%; So, I use gdb to see what happened, I found why it stucks, static void fill_cursor(CursorChannel *cursor_channel, SpiceCursor *red_cursor, CursorItem *cursor) { RedChannel *channel = &cursor_channel->base; if (!cursor) { red_cursor->flags = SPICE_CURSOR_FLAGS_NONE; return; } if (cursor->type == CURSOR_TYPE_DEV) { QXLCursorCmd *cursor_cmd; QXLCursor *qxl_cursor; cursor_cmd = cursor->qxl_cursor; qxl_cursor = (QXLCursor *)get_virt(&channel->worker->mem_slots, cursor_cmd->u.set.shape, sizeof(QXLCursor), cursor->group_id); red_cursor->flags = 0; red_cursor->header = qxl_cursor->header; if (red_cursor->header.unique) { if (red_cursor_cache_find(cursor_channel, red_cursor->header.unique)) { red_cursor->flags |= SPICE_CURSOR_FLAGS_FROM_CACHE; return; } if (red_cursor_cache_add(cursor_channel, red_cursor->header.unique, 1)) { red_cursor->flags |= SPICE_CURSOR_FLAGS_CACHE_ME; } } if (qxl_cursor->data_size) { // QXLDataChunk *chunk = (QXLDataChunk *)&qxl_cursor->chunk; // chunk->data_size is different from qxl_cursor->data_size, here is why spice server stuck, // in my case,qxl_cursor->data_size is 4224, chunk->data_size is 128, so in red_send_data() function, it enters infinite loop. add_buf(channel, BUF_TYPE_CHUNK, &qxl_cursor->chunk, qxl_cursor->data_size, get_memslot_id(&channel->worker->mem_slots, cursor_cmd->u.set.shape), cursor->group_id); } } else { LocalCursor *local_cursor; ASSERT(cursor->type == CURSOR_TYPE_LOCAL); local_cursor = (LocalCursor *)cursor; *red_cursor = local_cursor->red_cursor; add_buf(channel, BUF_TYPE_RAW, local_cursor->red_cursor.data, local_cursor->data_size, 0, 0); } } Welcome for giving some comments. Best Regards, Coolper _______________________________________________ Spice-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/spice-devel
Hi, I fixed this in the qxl driver. It was caused due to not supporting device surfaces in cursors. So using the newest driver code should solve this.
Yonit. _______________________________________________ Spice-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/spice-devel
