Home
last modified time | relevance | path

Searched refs:state (Results 1 – 25 of 3308) sorted by relevance

12345678910>>...133

/freebsd-12.1/sys/contrib/zstd/zlibWrapper/
H A Dgzread.c65 if (state.state->err != Z_OK && state.state->err != Z_BUF_ERROR)
104 if (state.state->in == NULL || state.state->out == NULL) {
110 state.state->size = state.state->want;
163 state.state->x.next = state.state->out;
217 state.state->x.next = strm->next_out - state.state->x.have;
247 if (gz_load(state, state.state->out, state.state->size << 1, &(state.state->x.have))
250 state.state->x.next = state.state->out;
529 state.state->x.next = state.state->out + (state.state->size << 1) - 1;
537 if (state.state->x.have == (state.state->size << 1)) {
543 if (state.state->x.next == state.state->out) {
[all …]
H A Dgzwrite.c27 state.state->in = (unsigned char *)malloc(state.state->want << 1);
36 state.state->out = (unsigned char *)malloc(state.state->want);
59 state.state->size = state.state->want;
123 state.state->x.next = state.state->out;
210 state.state->strm.next_in = state.state->in;
262 if (state.state->mode != GZ_WRITE || state.state->err != Z_OK)
292 if (state.state->mode != GZ_WRITE || state.state->err != Z_OK)
323 if (state.state->mode != GZ_WRITE || state.state->err != Z_OK)
369 if (state.state->mode != GZ_WRITE || state.state->err != Z_OK)
447 memcpy(state.state->in, state.state->in + state.state->size, left); in gzvprintf()
[all …]
H A Dgzlib.c261 state.state->start = LSEEK(state.state->fd, 0, SEEK_CUR);
262 if (state.state->start == -1) state.state->start = 0;
329 if (state.state->mode != GZ_READ && state.state->mode != GZ_WRITE)
362 if (LSEEK(state.state->fd, state.state->start, SEEK_SET) == -1)
382 if (state.state->mode != GZ_READ && state.state->mode != GZ_WRITE)
386 if (state.state->err != Z_OK && state.state->err != Z_BUF_ERROR)
401 if (state.state->mode == GZ_READ && state.state->how == COPY &&
467 if (state.state->mode != GZ_READ && state.state->mode != GZ_WRITE)
471 return state.state->x.pos + (state.state->seek ? state.state->skip : 0);
531 return state.state->mode == GZ_READ ? state.state->past : 0;
[all …]
/freebsd-12.1/sys/cddl/contrib/opensolaris/uts/common/zmod/
H A Dinflate.c130 state->lencode = state->distcode = state->next = state->codes;
146 state->hold += value << state->bits;
357 zmemcpy(state->window, strm->next_out - state->wsize, state->wsize);
359 state->whave = state->wsize;
369 state->whave = state->wsize;
373 if (state->write == state->wsize) state->write = 0;
374 if (state->whave < state->wsize) state->whave += dist;
882 state->next = state->codes;
897 while (state->have < state->nlen + state->ndist) {
949 state->next = state->codes;
[all …]
/freebsd-12.1/sys/contrib/zlib/
H A Dinflate.c137 state->lencode = state->distcode = state->next = state->codes;
423 zmemcpy(state->window, end - state->wsize, state->wsize);
425 state->whave = state->wsize;
435 state->whave = state->wsize;
439 if (state->wnext == state->wsize) state->wnext = 0;
440 if (state->whave < state->wsize) state->whave += dist;
946 state->next = state->codes;
960 while (state->have < state->nlen + state->ndist) {
1020 state->next = state->codes;
1101 state->was = state->length;
[all …]
H A Dgzread.c110 state->size = state->want;
162 state->x.next = state->out;
246 if (gz_load(state, state->out, state->size << 1, &(state->x.have))
249 state->x.next = state->out;
312 if (gz_skip(state, state->skip) == -1)
505 if (gz_skip(state, state->skip) == -1)
516 state->x.next = state->out + (state->size << 1) - 1;
524 if (state->x.have == (state->size << 1)) {
530 if (state->x.next == state->out) {
569 if (gz_skip(state, state->skip) == -1)
[all …]
H A Dgzwrite.c59 state->size = state->want;
85 if (state->size == 0 && gz_init(state) == -1)
123 state->x.next = state->out;
199 if (gz_zero(state, state->skip) == -1)
210 state->strm.next_in = state->in;
329 if (gz_zero(state, state->skip) == -1)
407 if (gz_zero(state, state->skip) == -1) in gzvprintf()
447 memcpy(state->in, state->in + state->size, left); in gzvprintf()
501 if (gz_zero(state, state->skip) == -1)
546 memcpy(state->in, state->in + state->size, left);
[all …]
H A Dinfback.c62 strm->state = (struct internal_state FAR *)state;
378 while (state->have < state->ncode) {
385 state->next = state->codes;
399 while (state->have < state->nlen + state->ndist) {
436 if (state->have + copy > state->nlen + state->ndist) {
459 state->next = state->codes;
462 ret = inflate_table(LENS, state->lens, state->nlen, &(state->next),
471 ret = inflate_table(DISTS, state->lens + state->nlen, state->ndist,
472 &(state->next), &(state->distbits), state->work);
485 if (state->whave < state->wsize)
[all …]
H A Dgzlib.c261 state->start = LSEEK(state->fd, 0, SEEK_CUR);
262 if (state->start == -1) state->start = 0;
329 if (state->mode != GZ_READ && state->mode != GZ_WRITE)
362 if (LSEEK(state->fd, state->start, SEEK_SET) == -1)
382 if (state->mode != GZ_READ && state->mode != GZ_WRITE)
386 if (state->err != Z_OK && state->err != Z_BUF_ERROR)
401 if (state->mode == GZ_READ && state->how == COPY &&
467 if (state->mode != GZ_READ && state->mode != GZ_WRITE)
471 return state->x.pos + (state->seek ? state->skip : 0);
531 return state->mode == GZ_READ ? state->past : 0;
[all …]
/freebsd-12.1/sys/dev/bhnd/nvram/
H A Dbhnd_nvram_data_sprom_subr.c163 memset(&state->var, 0, sizeof(state->var)); in bhnd_sprom_opcode_reset()
165 state->input = state->layout->bindings; in bhnd_sprom_opcode_reset()
169 bit_set(state->revs, state->layout->rev); in bhnd_sprom_opcode_reset()
250 return (bsearch(&vid, state->idx, state->num_idx, sizeof(state->idx[0]), in bhnd_sprom_opcode_index_find()
329 opcodes = (state->input - state->layout->bindings); in bhnd_sprom_opcode_init_entry()
360 state->input = state->layout->bindings + entry->opcodes; in bhnd_sprom_opcode_seek()
405 memset(state->revs, 0x0, sizeof(state->revs)); in bhnd_sprom_opcode_set_revs()
582 memset(&state->var.bind, 0, sizeof(state->var.bind)); in bhnd_sprom_opcode_flush_bind()
669 memset(&state->var, 0, sizeof(state->var)); in bhnd_sprom_opcode_clear_var()
764 memset(&state->var, 0x0, sizeof(state->var)); in bhnd_sprom_opcode_set_var()
[all …]
/freebsd-12.1/contrib/libarchive/libarchive/
H A Darchive_write_add_filter_compress.c198 state->cur_maxcode = MAXCODE(state->code_len); in archive_compressor_compress_open()
275 state->bit_offset += state->code_len; in output_code()
277 if (state->bit_offset == state->code_len * 8) in output_code()
307 state->cur_maxcode = state->max_maxcode; in output_code()
363 if (state->hashtab[i] == state->cur_fcode) { in archive_compressor_compress_write()
364 state->cur_code = state->codetab[i]; in archive_compressor_compress_write()
378 if (state->hashtab[i] == state->cur_fcode) { in archive_compressor_compress_write()
379 state->cur_code = state->codetab[i]; in archive_compressor_compress_write()
389 if (state->first_free < state->max_maxcode) { in archive_compressor_compress_write()
391 state->hashtab[i] = state->cur_fcode; in archive_compressor_compress_write()
[all …]
H A Darchive_read_support_filter_compress.c253 state->maxcode = (1 << state->maxcode_bits); in compress_bidder_init()
258 state->stackp = state->stack; in compress_bidder_init()
293 if (state->stackp > state->stack) { in compress_filter_read()
390 *state->stackp++ = state->finbyte; in next_code()
396 *state->stackp++ = state->suffix[code]; in next_code()
399 *state->stackp++ = state->finbyte = code; in next_code()
404 state->prefix[code] = state->oldcode; in next_code()
405 state->suffix[code] = state->finbyte; in next_code()
411 if (state->bits == state->maxcode_bits) in next_code()
412 state->section_end_code = state->maxcode; in next_code()
[all …]
H A Darchive_read_support_filter_program.c165 state = (struct program_bidder *)calloc(1, sizeof (*state)); in archive_read_support_filter_program_signature()
166 if (state == NULL) in archive_read_support_filter_program_signature()
192 if (state) { in free_state()
195 free(state); in free_state()
219 if (memcmp(p, state->signature, state->signature_len) != 0) in program_bidder_bid()
255 = waitpid(state->child, &state->exit_status, 0); in child_stop()
407 state = (struct program_filter *)calloc(1, sizeof(*state)); in __archive_read_program()
415 free(state); in __archive_read_program()
434 free(state); in __archive_read_program()
446 free(state); in __archive_read_program()
[all …]
/freebsd-12.1/contrib/libpcap/missing/
H A Dsnprintf.c97 if (state->max_sz && state->sz >= state->max_sz)
100 state->sz = max(state->sz * 2, state->sz + n);
102 state->sz = min(state->sz, state->max_sz);
107 state->s = state->str + off;
108 state->theend = state->str + state->sz - 1;
434 *arg = state->s - state->str; in xyzprintf()
564 struct state state;
573 state.s = state.str;
574 state.theend = state.s + state.sz - 1;
587 len = state.s - state.str;
[all …]
/freebsd-12.1/contrib/tcpdump/missing/
H A Dsnprintf.c97 if (state->max_sz && state->sz >= state->max_sz)
100 state->sz = max(state->sz * 2, state->sz + n);
102 state->sz = min(state->sz, state->max_sz);
107 state->s = state->str + off;
108 state->theend = state->str + state->sz - 1;
434 *arg = state->s - state->str; in xyzprintf()
564 struct state state;
573 state.s = state.str;
574 state.theend = state.s + state.sz - 1;
587 len = state.s - state.str;
[all …]
/freebsd-12.1/contrib/expat/lib/
H A Dxmlrole.c94 ((state)->handler = ((state)->documentEntity \
98 #define setTopLevel(state) ((state)->handler = internalSubset) argument
547 setTopLevel(state); in entity5()
650 setTopLevel(state); in entity10()
1026 state->level = 1; in element1()
1052 state->level = 2; in element2()
1147 state->level += 1; in element6()
1177 state->level -= 1; in element7()
1184 state->level -= 1; in element7()
1191 state->level -= 1; in element7()
[all …]
/freebsd-12.1/contrib/bearssl/src/symcipher/
H A Daes_small_enc.c51 state[i] = S[state[i]]; in sub_bytes()
60 tmp = state[1]; in shift_rows()
61 state[1] = state[5]; in shift_rows()
62 state[5] = state[9]; in shift_rows()
63 state[9] = state[13]; in shift_rows()
66 tmp = state[2]; in shift_rows()
67 state[2] = state[10]; in shift_rows()
70 state[6] = state[14]; in shift_rows()
74 state[15] = state[11]; in shift_rows()
75 state[11] = state[7]; in shift_rows()
[all …]
H A Daes_small_dec.c77 state[i] = iS[state[i]]; in inv_sub_bytes()
87 state[13] = state[9]; in inv_shift_rows()
88 state[9] = state[5]; in inv_shift_rows()
89 state[5] = state[1]; in inv_shift_rows()
90 state[1] = tmp; in inv_shift_rows()
92 tmp = state[2]; in inv_shift_rows()
93 state[2] = state[10]; in inv_shift_rows()
96 state[6] = state[14]; in inv_shift_rows()
100 state[3] = state[7]; in inv_shift_rows()
101 state[7] = state[11]; in inv_shift_rows()
[all …]
/freebsd-12.1/sys/dev/evdev/
H A Duinput.c59 #define UINPUT_LOCK(state) sx_xlock(&(state)->ucs_lock) argument
60 #define UINPUT_UNLOCK(state) sx_unlock(&(state)->ucs_lock) argument
61 #define UINPUT_LOCK_ASSERT(state) sx_assert(&(state)->ucs_lock, SA_LOCKED) argument
63 ((state)->ucs_buffer_head == (state)->ucs_buffer_tail)
170 UINPUT_LOCK(state); in uinput_ev_event()
197 debugf(state, "state %p: buffer overflow", state); in uinput_enqueue_event()
267 ret = sx_sleep(state, &state->ucs_lock, in uinput_read()
274 event = &state->ucs_buffer[state->ucs_buffer_head]; in uinput_read()
275 state->ucs_buffer_head = (state->ucs_buffer_head + 1) % in uinput_read()
463 wakeup(state); in uinput_notify()
[all …]
/freebsd-12.1/sys/dev/kbdmux/
H A Dkbdmux.c199 p = (state->ks_inq_start + state->ks_inq_length) % KBDMUX_Q_SIZE; in kbdmux_kbd_putc()
212 c = state->ks_inq[state->ks_inq_start]; in kbdmux_kbd_getc()
213 state->ks_inq_start = (state->ks_inq_start + 1) % KBDMUX_Q_SIZE; in kbdmux_kbd_getc()
230 KBDMUX_LOCK(state); in kbdmux_kbd_intr()
257 if (state->ks_inq_length > 0 && !(state->ks_flags & TASK) && in kbdmux_kbd_intr_timo()
262 callout_reset(&state->ks_timo, TICKS, kbdmux_kbd_intr_timo, state); in kbdmux_kbd_intr_timo()
302 if (state->ks_inq_length > 0 && !(state->ks_flags & TASK) && in kbdmux_kbd_event()
434 state = malloc(sizeof(*state), M_KBDMUX, M_NOWAIT | M_ZERO); in kbdmux_init()
527 callout_reset(&state->ks_timo, TICKS, kbdmux_kbd_intr_timo, state); in kbdmux_init()
588 bzero(state, sizeof(*state)); in kbdmux_term()
[all …]
/freebsd-12.1/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/
H A Dzcp.c156 zcp_cleanup(state); in zcp_error_handler()
160 luaL_traceback(state, state, msg, 1); in zcp_error_handler()
262 lua_pushnil(state); in zcp_table_to_nvlist()
310 lua_typename(state, lua_type(state, -2))); in zcp_table_to_nvlist()
348 lua_pop(state, 1); in zcp_table_to_nvlist()
426 lua_typename(state, lua_type(state, index)), key); in zcp_lua_to_nvlist_impl()
1036 lua_State *state; in zcp_eval() local
1062 lua_pop(state, 1); in zcp_eval()
1152 lua_close(state); in zcp_eval()
1347 if (lua_isnumber(state, -2) && lua_tointeger(state, -2) > 0) { in zcp_parse_table_args()
[all …]
/freebsd-12.1/contrib/binutils/opcodes/
H A Darc-dis.c86 state->nullifyMode = BITS (state->words[0], 5, 6); \
167 #define add_target(x) (state->targets[state->tcnt++] = (x))
175 return (*state->coreRegName)(state->_this, val); in core_reg_name()
183 return (*state->auxRegName)(state->_this, val); in aux_reg_name()
191 return (*state->condCodeName)(state->_this, val); in cond_code_name()
210 (*state->err)(state->_this, (msg)); in mwerror()
431 strncat (state->commentBuffer, state->comm[i], in write_comments_()
562 state->_opcode = OPCODE (state->words[0]); in dsmOneArcInst()
893 state->flow = state->_opcode == op_BLC /* BL */ in dsmOneArcInst()
1007 state->_offset += fieldB, state->_ea_present = 0; in dsmOneArcInst()
[all …]
/freebsd-12.1/crypto/openssh/
H A Dpacket.c252 ssh->state = state; in ssh_alloc_session_state()
301 state = ssh->state; in ssh_packet_set_connection()
324 struct session_state *state = ssh->state; in ssh_packet_set_timeout() local
371 struct session_state *state = ssh->state; in ssh_packet_stop_discard() local
399 struct session_state *state = ssh->state; in ssh_packet_start_discard() local
433 state = ssh->state; in ssh_packet_connection_is_on_socket()
586 struct session_state *state = ssh->state; in ssh_packet_close_internal() local
833 struct session_state *state = ssh->state; in ssh_set_newkeys() local
929 struct session_state *state = ssh->state; in ssh_packet_need_rekeying() local
981 struct session_state *state = ssh->state; in ssh_packet_enable_delayed_compress() local
[all …]
H A Dsshkey-xmss.c126 if (xmss_set_params(&state->params, state->n, state->h, state->w, in sshkey_xmss_init()
179 for (i = 0; i < state->h - state->k; i++) in sshkey_xmss_init_bds_state()
180 state->treehash[i].node = &state->th_nodes[state->n*i]; in sshkey_xmss_init_bds_state()
181 xmss_set_bds_state(&state->bds, state->stack, state->stackoffset, in sshkey_xmss_init_bds_state()
182 state->stacklevels, state->auth, state->keep, state->treehash, in sshkey_xmss_init_bds_state()
241 state->h * state->n; in sshkey_xmss_siglen()
514 if (state->idx + 1 < state->idx) { in sshkey_xmss_get_state()
546 if (state->idx + reserve <= state->idx) in sshkey_xmss_forward_state()
794 xmss_set_bds_state(&state->bds, state->stack, state->stackoffset, in sshkey_xmss_deserialize_state()
795 state->stacklevels, state->auth, state->keep, state->treehash, in sshkey_xmss_deserialize_state()
[all …]
/freebsd-12.1/sys/dev/vkbd/
H A Dvkbd.c232 VKBD_LOCK(state); in vkbd_dev_open()
262 VKBD_LOCK(state); in vkbd_dev_close()
274 state->ks_inq.head = state->ks_inq.tail = state->ks_inq.cc = 0; in vkbd_dev_close()
310 VKBD_LOCK(state); in vkbd_dev_read()
370 VKBD_LOCK(state); in vkbd_dev_write()
451 VKBD_LOCK(state); in vkbd_dev_poll()
618 state = malloc(sizeof(*state), M_VKBD, M_NOWAIT | M_ZERO); in vkbd_init()
631 state->ks_inq.head = state->ks_inq.tail = state->ks_inq.cc = 0; in vkbd_init()
709 bzero(state, sizeof(*state)); in vkbd_term()
1055 &state->ks_state, &state->ks_accents); in vkbd_read_char()
[all …]

12345678910>>...133