summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@gmail.com>2013-09-13 20:52:31 +0200
committerFrediano Ziglio <fziglio@redhat.com>2015-11-02 09:46:41 +0000
commit9e42647101ef3683a3318ba2baaae7e4edd58baf (patch)
tree13b41b6cbf48836cead9b4bbe826a7ef58706c96
parent0eedafaf0c83c87a14485f6ee42f23338ed73e00 (diff)
downloadspice-9e42647101ef3683a3318ba2baaae7e4edd58baf.tar.gz
spice-9e42647101ef3683a3318ba2baaae7e4edd58baf.tar.xz
spice-9e42647101ef3683a3318ba2baaae7e4edd58baf.zip
worker: s/repoll/poll_tries
Acked-by: Frediano Ziglio <fziglio@redhat.com>
-rw-r--r--server/red_worker.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/server/red_worker.c b/server/red_worker.c
index fb1d69e8..68cb153c 100644
--- a/server/red_worker.c
+++ b/server/red_worker.c
@@ -576,10 +576,10 @@ typedef struct RedWorker {
unsigned int event_timeout;
DisplayChannel *display_channel;
- uint32_t repoll_cmd_ring;
+ uint32_t display_poll_tries;
CursorChannel *cursor_channel;
- uint32_t repoll_cursor_ring;
+ uint32_t cursor_poll_tries;
uint32_t num_renderers;
uint32_t renderers[RED_RENDERER_LAST];
@@ -4160,19 +4160,19 @@ static int red_process_cursor(RedWorker *worker, uint32_t max_pipe_size, int *ri
red_channel_min_pipe_size(&worker->cursor_channel->common.base) <= max_pipe_size) {
if (!worker->qxl->st->qif->get_cursor_command(worker->qxl, &ext_cmd)) {
*ring_is_empty = TRUE;
- if (worker->repoll_cursor_ring < CMD_RING_POLL_RETRIES) {
- worker->repoll_cursor_ring++;
+ if (worker->cursor_poll_tries < CMD_RING_POLL_RETRIES) {
+ worker->cursor_poll_tries++;
worker->event_timeout = MIN(worker->event_timeout, CMD_RING_POLL_TIMEOUT);
return n;
}
- if (worker->repoll_cursor_ring > CMD_RING_POLL_RETRIES ||
+ if (worker->cursor_poll_tries > CMD_RING_POLL_RETRIES ||
worker->qxl->st->qif->req_cursor_notification(worker->qxl)) {
- worker->repoll_cursor_ring++;
+ worker->cursor_poll_tries++;
return n;
}
continue;
}
- worker->repoll_cursor_ring = 0;
+ worker->cursor_poll_tries = 0;
switch (ext_cmd.cmd.type) {
case QXL_CMD_CURSOR: {
RedCursorCmd *cursor = spice_new0(RedCursorCmd, 1);
@@ -4222,14 +4222,14 @@ static int red_process_commands(RedWorker *worker, uint32_t max_pipe_size, int *
red_channel_min_pipe_size(&worker->display_channel->common.base) <= max_pipe_size) {
if (!worker->qxl->st->qif->get_command(worker->qxl, &ext_cmd)) {
*ring_is_empty = TRUE;;
- if (worker->repoll_cmd_ring < CMD_RING_POLL_RETRIES) {
- worker->repoll_cmd_ring++;
+ if (worker->display_poll_tries < CMD_RING_POLL_RETRIES) {
+ worker->display_poll_tries++;
worker->event_timeout = MIN(worker->event_timeout, CMD_RING_POLL_TIMEOUT);
return n;
}
- if (worker->repoll_cmd_ring > CMD_RING_POLL_RETRIES ||
+ if (worker->display_poll_tries > CMD_RING_POLL_RETRIES ||
worker->qxl->st->qif->req_cmd_notification(worker->qxl)) {
- worker->repoll_cmd_ring++;
+ worker->display_poll_tries++;
return n;
}
continue;
@@ -4240,7 +4240,7 @@ static int red_process_commands(RedWorker *worker, uint32_t max_pipe_size, int *
stat_now(worker));
stat_inc_counter(worker->command_counter, 1);
- worker->repoll_cmd_ring = 0;
+ worker->display_poll_tries = 0;
switch (ext_cmd.cmd.type) {
case QXL_CMD_DRAW: {
RedDrawable *red_drawable = red_drawable_new(worker); // returns with 1 ref