/freebsd/usr.bin/netstat/ |
H A D | nhops.c | 205 if (idx >= map->size) { in nhop_map_update() 212 if (new_size <= idx) in nhop_map_update() 213 new_size = roundup2(idx + 1, 32); in nhop_map_update() 223 strlcpy(map->ptr[idx].ifname, ifname, sizeof(map->ptr[idx].ifname)); in nhop_map_update() 224 strlcpy(map->ptr[idx].gw, gw, sizeof(map->ptr[idx].gw)); in nhop_map_update() 231 if (idx >= map->size) in nhop_get() 233 if (*map->ptr[idx].ifname == '\0') in nhop_get() 235 return &map->ptr[idx]; in nhop_get() 330 if (a->idx > b->idx) in cmp_nh_idx() 332 else if (a->idx < b->idx) in cmp_nh_idx() [all …]
|
/freebsd/contrib/processor-trace/libipt/src/ |
H A D | pt_event_queue.c | 34 static inline uint8_t pt_evq_inc(uint8_t idx) in pt_evq_inc() argument 36 idx += 1; in pt_evq_inc() 37 idx %= evq_max; in pt_evq_inc() 39 return idx; in pt_evq_inc() 69 uint8_t begin, end, gap, idx; in pt_evq_enqueue() local 78 idx = evq->end[evb]; in pt_evq_enqueue() 83 if (evq_max <= idx) in pt_evq_enqueue() 86 end = pt_evq_inc(idx); in pt_evq_enqueue() 95 return pt_event_init(&evq->queue[evb][idx]); in pt_evq_enqueue()
|
/freebsd/contrib/libbegemot/ |
H A D | rpoll.c | 493 u_int i, idx; in poll_dispatch() local 567 assert(idx < regs_alloc); in poll_dispatch() 569 if(regs[idx].fd >= 0) { in poll_dispatch() 573 if(regs[idx].pfd) { in poll_dispatch() 574 if ((regs[idx].mask & RPOLL_IN) && in poll_dispatch() 586 if ((regs[idx].mask & RPOLL_IN) && in poll_dispatch() 587 FD_ISSET(regs[idx].fd, &nrset)) in poll_dispatch() 589 if ((regs[idx].mask & RPOLL_OUT) && in poll_dispatch() 596 assert(idx < regs_alloc); in poll_dispatch() 602 regs[idx].fd, idx, mask); in poll_dispatch() [all …]
|
/freebsd/contrib/llvm-project/lldb/source/Interpreter/ |
H A D | OptionValueProperties.cpp | 58 const size_t idx = iter->second; in GetValueForKey() local 59 if (idx >= m_properties.size()) in GetValueForKey() 61 return GetPropertyAtIndex(idx, exe_ctx)->GetValue(); in GetValueForKey() 158 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyValueAtIndex() argument 167 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyAtIndexAsOptionValuePathMappings() argument 176 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyAtIndexAsOptionValueFileSpecList() argument 241 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyAtIndexAsOptionValueDictionary() argument 250 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyAtIndexAsOptionValueFileSpec() argument 261 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyAtIndexAsOptionValueSInt64() argument 272 size_t idx, const ExecutionContext *exe_ctx) const { in GetPropertyAtIndexAsOptionValueUInt64() argument [all …]
|
/freebsd/sys/dev/ixl/ |
H A D | i40e_hmc.c | 225 u32 idx) in i40e_remove_pd_bp() argument 235 sd_idx = idx / I40E_HMC_PD_CNT_IN_SD; in i40e_remove_pd_bp() 236 rel_pd_idx = idx % I40E_HMC_PD_CNT_IN_SD; in i40e_remove_pd_bp() 261 I40E_INVALIDATE_PF_HMC_PD(hw, sd_idx, idx); in i40e_remove_pd_bp() 280 u32 idx) in i40e_prep_remove_sd_bp() argument 286 sd_entry = &hmc_info->sd_table.sd_entry[idx]; in i40e_prep_remove_sd_bp() 309 u32 idx, bool is_pf) in i40e_remove_sd_bp_new() argument 317 sd_entry = &hmc_info->sd_table.sd_entry[idx]; in i40e_remove_sd_bp_new() 329 u32 idx) in i40e_prep_remove_pd_page() argument 334 sd_entry = &hmc_info->sd_table.sd_entry[idx]; in i40e_prep_remove_pd_page() [all …]
|
/freebsd/lib/libc/db/btree/ |
H A D | bt_put.c | 67 indx_t idx, nxtindex; in __bt_put() local 149 idx = t->bt_cursor.pg.index; in __bt_put() 161 idx = e->index; in __bt_put() 199 data, dflags, nbytes, idx)) != RET_SUCCESS) in __bt_put() 204 if (idx < (nxtindex = NEXTINDEX(h))) in __bt_put() 205 memmove(h->linp + idx + 1, h->linp + idx, in __bt_put() 206 (nxtindex - idx) * sizeof(indx_t)); in __bt_put() 209 h->linp[idx] = h->upper -= nbytes; in __bt_put() 221 if (idx == NEXTINDEX(h) - 1) { in __bt_put() 223 t->bt_last.index = idx; in __bt_put() [all …]
|
/freebsd/sys/dev/liquidio/base/ |
H A D | lio_device.c | 361 int idx, refcount; in lio_register_device() local 371 for (idx = (int)oct->octeon_id - 1; idx >= 0; idx--) { in lio_register_device() 372 if (octeon_device[idx] == NULL) { in lio_register_device() 573 uint32_t idx; in lio_get_dispatch() local 631 uint32_t idx; in lio_register_dispatch_fn() local 712 uint32_t idx; in lio_unregister_dispatch_fn() local 728 oct->dispatch.dlist[idx].opcode = in lio_unregister_dispatch_fn() 732 oct->dispatch.dlist[idx].arg = in lio_unregister_dispatch_fn() 737 oct->dispatch.dlist[idx].opcode = 0; in lio_unregister_dispatch_fn() 739 oct->dispatch.dlist[idx].arg = NULL; in lio_unregister_dispatch_fn() [all …]
|
H A D | lio_config.h | 119 #define LIO_GET_NUM_RX_DESCS_NIC_IF_CFG(cfg, idx) \ argument 120 ((cfg)->nic_if_cfg[idx].num_rx_descs) 121 #define LIO_GET_NUM_TX_DESCS_NIC_IF_CFG(cfg, idx) \ argument 122 ((cfg)->nic_if_cfg[idx].num_tx_descs) 123 #define LIO_GET_NUM_RX_BUF_SIZE_NIC_IF_CFG(cfg, idx) \ argument 124 ((cfg)->nic_if_cfg[idx].rx_buf_size) 131 #define LIO_SET_NUM_RX_DESCS_NIC_IF(cfg, idx, value) \ argument 132 ((cfg)->nic_if_cfg[idx].num_rx_descs = value) 133 #define LIO_SET_NUM_TX_DESCS_NIC_IF(cfg, idx, value) \ argument 134 ((cfg)->nic_if_cfg[idx].num_tx_descs = value)
|
/freebsd/sys/powerpc/ps3/ |
H A D | if_glc.c | 588 bzero(&sc->sc_rxdmadesc[idx], sizeof(sc->sc_rxdmadesc[idx])); in glc_add_rxbuf_dma() 592 ((idx + 1) % GLC_MAX_RX_PACKETS)*sizeof(sc->sc_rxdmadesc[idx]); in glc_add_rxbuf_dma() 595 rxs->rxs_desc_slot = idx; in glc_add_rxbuf_dma() 608 int i, idx, nsegs, nsegs_max; in glc_encap() local 658 idx = txs->txs_firstdesc; in glc_encap() 663 bzero(&sc->sc_txdmadesc[idx], sizeof(sc->sc_txdmadesc[idx])); in glc_encap() 671 txs->txs_lastdesc = idx; in glc_encap() 682 idx = (idx + 1) % GLC_MAX_TX_PACKETS; in glc_encap() 684 sc->next_txdma_slot = idx; in glc_encap() 687 idx = txs->txs_firstdesc - 1; in glc_encap() [all …]
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/ |
H A D | readmmap.c | 55 size_t idx = 0; in main() local 99 idx = random() % size; in main() 100 map[idx] = 1; in main() 121 if (buf[idx] != 1) { in main() 124 idx, buf[idx]); in main() 129 (void) printf("good data from read: buf[%zd]=1\n", idx); in main()
|
/freebsd/tests/sys/cddl/zfs/bin/ |
H A D | readmmap.c | 55 size_t idx = 0; in main() local 99 idx = random() % size; in main() 100 map[idx] = 1; in main() 121 if (buf[idx] != 1) { in main() 124 idx, buf[idx]); in main() 129 (void) printf("good data from read: buf[%zu]=1\n", idx); in main()
|
/freebsd/crypto/heimdal/lib/krb5/ |
H A D | get_addrs.c | 102 unsigned int num, idx; in find_all_addresses() local 140 for (ifa = ifa0, idx = 0; ifa != NULL; ifa = ifa->ifa_next) { in find_all_addresses() 153 ret = krb5_sockaddr2address(context, ifa->ifa_addr, &res->val[idx]); in find_all_addresses() 166 krb5_free_address(context, &res->val[idx]); in find_all_addresses() 173 idx++; in find_all_addresses() 180 if ((flags & LOOP_IF_NONE) != 0 && idx == 0) { in find_all_addresses() 196 ifa->ifa_addr, &res->val[idx]); in find_all_addresses() 200 krb5_address_search(context, &res->val[idx], in find_all_addresses() 202 krb5_free_address(context, &res->val[idx]); in find_all_addresses() 205 idx++; in find_all_addresses() [all …]
|
/freebsd/contrib/llvm-project/lldb/include/lldb/Core/ |
H A D | UniqueCStringMap.h | 54 bool GetValueAtIndex(uint32_t idx, T &value) const { in GetValueAtIndex() argument 55 if (idx < m_map.size()) { in GetValueAtIndex() 56 value = m_map[idx].value; in GetValueAtIndex() 62 ConstString GetCStringAtIndexUnchecked(uint32_t idx) const { in GetCStringAtIndexUnchecked() argument 63 return m_map[idx].cstring; in GetCStringAtIndexUnchecked() 68 T GetValueAtIndexUnchecked(uint32_t idx) const { return m_map[idx].value; } in GetValueAtIndexUnchecked() argument 72 const T &GetValueRefAtIndexUnchecked(uint32_t idx) const { in GetValueRefAtIndexUnchecked() argument 73 return m_map[idx].value; in GetValueRefAtIndexUnchecked() 76 ConstString GetCStringAtIndex(uint32_t idx) const { in GetCStringAtIndex() argument 77 return ((idx < m_map.size()) ? m_map[idx].cstring : ConstString()); in GetCStringAtIndex()
|
/freebsd/lib/libiconv_modules/JOHAB/ |
H A D | citrus_johab.c | 244 _csid_t * __restrict csid, _index_t * __restrict idx, wchar_t wc) in _citrus_JOHAB_stdenc_wctocs() argument 250 *idx = (_index_t)wc; in _citrus_JOHAB_stdenc_wctocs() 256 *idx = (_index_t)wc; in _citrus_JOHAB_stdenc_wctocs() 276 *idx = (_index_t)((l << 8) | t); in _citrus_JOHAB_stdenc_wctocs() 287 wchar_t * __restrict wc, _csid_t csid, _index_t idx) in _citrus_JOHAB_stdenc_cstowc() argument 294 *wc = (wchar_t)idx; in _citrus_JOHAB_stdenc_cstowc() 297 if (idx >= 0x2121 && idx <= 0x2C71) { in _citrus_JOHAB_stdenc_cstowc() 300 } else if (idx >= 0x4A21 && idx <= 0x7D7E) { in _citrus_JOHAB_stdenc_cstowc() 305 l = ((idx >> 8) & 0xFF) - n; in _citrus_JOHAB_stdenc_cstowc() 306 t = (idx & 0xFF) - 0x21; in _citrus_JOHAB_stdenc_cstowc()
|
/freebsd/sys/dev/mlxfw/ |
H A D | mlxfw_mfa2_tlv_multi.h | 61 #define mlxfw_mfa2_tlv_foreach(mfa2_file, tlv, idx, from_tlv, count) \ argument 62 for (idx = 0, tlv = from_tlv; idx < (count); \ 63 idx++, tlv = mlxfw_mfa2_tlv_next(mfa2_file, tlv)) 65 #define mlxfw_mfa2_tlv_multi_foreach(mfa2_file, tlv, idx, multi) \ argument 66 mlxfw_mfa2_tlv_foreach(mfa2_file, tlv, idx, \
|
/freebsd/contrib/ofed/opensm/opensm/ |
H A D | osm_switch.c | 533 unsigned int idx; in osm_switch_recommend_path() local 538 if (!port_paths[idx].found_sys_guid in osm_switch_recommend_path() 544 else if (!port_paths[idx].found_node_guid in osm_switch_recommend_path() 553 best_port = port_paths[idx].port_num; in osm_switch_recommend_path() 554 least_paths = port_paths[idx].path_count; in osm_switch_recommend_path() 556 && (port_paths[idx].found_sys_guid in osm_switch_recommend_path() 557 || port_paths[idx].found_node_guid) in osm_switch_recommend_path() 562 && (port_paths[idx].found_sys_guid in osm_switch_recommend_path() 563 || port_paths[idx].found_node_guid) in osm_switch_recommend_path() 567 best_port = port_paths[idx].port_num; in osm_switch_recommend_path() [all …]
|
/freebsd/tools/tools/ncpus/ |
H A D | biosmptable.c | 187 int ofs, idx; in biosmptable_search_mpfps() local 208 for (idx = 0; idx < mpfps->length * 16; idx++) in biosmptable_search_mpfps() 209 sum += *(cp + idx); in biosmptable_search_mpfps() 226 int idx, table_length; in biosmptable_check_mpcth() local 256 for (idx = 0; idx < mpcth->base_table_length; idx++) in biosmptable_check_mpcth() 257 sum += *(cp + idx); in biosmptable_check_mpcth()
|
/freebsd/contrib/llvm-project/compiler-rt/lib/tsan/benchmarks/ |
H A D | mini_bench_local.cpp | 12 void Run(int idx) { in Run() argument 14 a[i + idx * n] = i; in Run() 18 long idx = (long)arg; in Thread() local 19 printf("Thread %ld started\n", idx); in Thread() 21 Run(idx); in Thread() 22 printf("Thread %ld done\n", idx); in Thread()
|
/freebsd/lib/libc/db/recno/ |
H A D | rec_search.c | 60 indx_t idx; in __rec_search() local 78 for (idx = 0, top = NEXTINDEX(h);;) { in __rec_search() 79 r = GETRINTERNAL(h, idx); in __rec_search() 80 if (++idx == top || total + r->nrecs > recno) in __rec_search() 85 BT_PUSH(t, pg, idx - 1); in __rec_search() 90 --GETRINTERNAL(h, (idx - 1))->nrecs; in __rec_search() 94 ++GETRINTERNAL(h, (idx - 1))->nrecs; in __rec_search()
|
/freebsd/sys/net/route/ |
H A D | nhop.c | 117 free(ctl->nh_idx_head.idx, M_NHOP); in destroy_ctl() 286 uint16_t idx; in link_nhop() local 300 if (bitmask_alloc_idx(&ctl->nh_idx_head, &idx) != 0) { in link_nhop() 308 nh_priv->nh_idx = idx; in link_nhop() 318 nh_priv, idx, hash_priv(nh_priv), ctl); in link_nhop() 321 return (idx); in link_nhop() 333 int idx; in unlink_nhop() local 336 idx = 0; in unlink_nhop() 342 idx = priv_ret->nh_idx; in unlink_nhop() 345 KASSERT((idx != 0), ("bogus nhop index 0")); in unlink_nhop() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/VE/ |
H A D | VEInstrPatternsVec.td | 69 def: Pat<(s32 (extractelt v32:$vec, uimm7:$idx)), 70 (SubRegCast (LVSvi v32:$vec, (ULO7 $idx)))>; 72 def: Pat<(s32 (extractelt v32:$vec, i64:$idx)), 73 (SubRegCast (LVSvr v32:$vec, $idx))>; 80 (LSVrr_v $idx, (SuperRegCast $val), $vec)>; 85 def: Pat<(s64 (extractelt v64:$vec, uimm7:$idx)), 86 (LVSvi v64:$vec, (ULO7 $idx))>; 88 def: Pat<(s64 (extractelt v64:$vec, i64:$idx)), 89 (LVSvr v64:$vec, $idx)>; 93 (LSVir_v (ULO7 $idx), $val, $vec)>; [all …]
|
/freebsd/sys/contrib/dev/mediatek/mt76/mt7615/ |
H A D | main.c | 223 idx = MT7615_WTBL_RESERVED - mvif->mt76.idx; in mt7615_add_interface() 226 mvif->sta.wcid.idx = idx; in mt7615_add_interface() 254 int idx = msta->wcid.idx; in mt7615_remove_interface() local 663 msta->wcid.idx = idx; in mt7615_mac_sta_add() 732 msta->rates[i].idx = sta_rates->rate[i].idx; in mt7615_sta_rate_tbl_update() 921 idx = idx > HW_BSSID_MAX ? HW_BSSID_0 : idx; in mt7615_get_tsf() 922 reg = idx > 1 ? MT_LPON_TCR2(idx): MT_LPON_TCR0(idx); in mt7615_get_tsf() 949 idx = idx > HW_BSSID_MAX ? HW_BSSID_0 : idx; in mt7615_set_tsf() 950 reg = idx > 1 ? MT_LPON_TCR2(idx): MT_LPON_TCR0(idx); in mt7615_set_tsf() 975 idx = idx > HW_BSSID_MAX ? HW_BSSID_0 : idx; in mt7615_offset_tsf() [all …]
|
/freebsd/sys/contrib/openzfs/module/zfs/ |
H A D | zfs_fuid.c | 137 uint64_t idx; in zfs_fuid_table_load() local 142 &idx) == 0); in zfs_fuid_table_load() 146 domnode->f_idx = idx; in zfs_fuid_table_load() 180 searchnode.f_idx = idx; in zfs_fuid_idx_domain() 478 fuid_domain->z_domidx = idx; in zfs_fuid_node_add() 492 fuid->z_domidx = idx; in zfs_fuid_node_add() 518 uint64_t idx; in zfs_fuid_create_cred() local 555 return (FUID_ENCODE(idx, rid)); in zfs_fuid_create_cred() 580 uint64_t idx = UID_NOBODY; in zfs_fuid_create() local 650 rid, idx, id, type); in zfs_fuid_create() [all …]
|
/freebsd/sys/i386/i386/ |
H A D | bios.c | 444 size_t idx = 0; in bios_oem_strings() local 481 str, idx, tot, idx+tot, maxlen-1); in bios_oem_strings() 502 if (idx == 0) { in bios_oem_strings() 513 if ( (idx > 1) && (buffer[idx-1] == ' ') ) in bios_oem_strings() 514 idx--; in bios_oem_strings() 515 buffer[idx] = '\0'; in bios_oem_strings() 516 return (idx); in bios_oem_strings() 577 int idx, left; in pnpbios_identify() local 677 idx = 0; in pnpbios_identify() 689 idx = left; in pnpbios_identify() [all …]
|
/freebsd/tools/test/stress2/misc/ |
H A D | cluster.sh | 89 wr(int idx) 95 snprintf(file, sizeof(file), "%s/f.%s.%06d", path, uid, idx); 121 rd(int idx) 127 snprintf(file, sizeof(file), "%s/f.%s.%06d", path, uid, idx); 154 mv(int idx) 159 snprintf(file, sizeof(file), "%s/f.%s.%06d", path, uid, idx); 160 snprintf(file2, sizeof(file2), "%s/f.%s.%06d.old", path, uid, idx); 173 tr(int idx) 179 snprintf(file, sizeof(file), "%s/f.%s.%06d", path, uid, idx); 193 rm(int idx) [all …]
|