Lines Matching defs:state

62  * @state:      Global state.
67 * left. The returned pointer is only valid while @state is locked, to
68 * used it again after unlocking @state, spmc_shmem_obj_lookup must be
72 spmc_shmem_obj_alloc(struct spmc_shmem_obj_state *state, size_t desc_size)
75 size_t free = state->data_size - state->allocated;
78 if (state->data == NULL) {
104 obj = (struct spmc_shmem_obj *)(state->data + state->allocated);
109 state->allocated += obj_size;
115 * @state: Global state.
126 static void spmc_shmem_obj_free(struct spmc_shmem_obj_state *state,
132 size_t shift_size = state->allocated - (shift_src - state->data);
137 state->allocated -= free_size;
142 * @state: Global state.
146 * %NULL, if not object in @state->data has a matching handle.
149 spmc_shmem_obj_lookup(struct spmc_shmem_obj_state *state, uint64_t handle)
151 uint8_t *curr = state->data;
153 while (curr - state->data < state->allocated) {
174 spmc_shmem_obj_get_next(struct spmc_shmem_obj_state *state, size_t *offset)
176 uint8_t *curr = state->data + *offset;
178 if (curr - state->data < state->allocated) {
954 * the memory is not in a valid state for lending.
958 * state.
1167 * @client: Client state.
1263 * @client: Client state.
1349 * the state of memory dynamically. Therefore we can always set
1430 if (mbox->state != MAILBOX_STATE_EMPTY) {
1431 WARN("%s: RX Buffer is full! %d\n", __func__, mbox->state);
1591 mbox->state = MAILBOX_STATE_FULL;
1634 * @client: Client state.
1706 if (mbox->state != MAILBOX_STATE_EMPTY) {
1714 mbox->state = MAILBOX_STATE_FULL;
1756 * @client: Client state.
1864 * @client: Client state.