Bool DRI2SwapLimit(DrawablePtr pDraw, int swap_limit) { DRI2DrawablePtr pPriv = DRI2GetDrawable(pDraw); DRI2ScreenPtr ds; if (!pPriv) return FALSE; ds = pPriv->dri2_screen; if (!ds->SwapLimitValidate || !ds->SwapLimitValidate(pDraw, swap_limit)) return FALSE; pPriv->swap_limit = swap_limit; /* Check throttling */ if (pPriv->swapsPending >= pPriv->swap_limit) return TRUE; if (pPriv->target_sbc == -1 && !pPriv->blockedOnMsc) { if (pPriv->blockedClient) { AttendClient(pPriv->blockedClient); pPriv->blockedClient = NULL; } } return TRUE; }
static void sync_callback(void *data, struct wl_callback *callback, uint32_t serial) { struct xwl_auth_state *state = data; dri3_send_open_reply(state->client, state->fd); AttendClient(state->client); free(state); wl_callback_destroy(callback); }
void glxResumeClients(void) { __GLXcontext *cx, *next; int i; glxBlockClients = FALSE; for (i = 1; i < currentMaxClients; i++) { if (clients[i] && glxGetClient(clients[i])->inUse) AttendClient(clients[i]); } __glXleaveServer(GL_FALSE); for (cx = glxPendingDestroyContexts; cx != NULL; cx = next) { next = cx->next; cx->destroy(cx); } glxPendingDestroyContexts = NULL; __glXenterServer(GL_FALSE); }
static void ClientAwaken(ClientPtr client, void *closure) { if (!client->clientGone) AttendClient(client); }