/freebsd/sys/kern/ |
H A D | subr_hash.c | 67 hashtbl = malloc((u_long)hashsize * sizeof(*hashtbl), type, in hashinit_flags() 69 if (hashtbl != NULL) { in hashinit_flags() 71 LIST_INIT(&hashtbl[i]); in hashinit_flags() 74 return (hashtbl); in hashinit_flags() 92 hashtbl = vhashtbl; in hashdestroy() 93 for (hp = hashtbl; hp <= &hashtbl[hashmask]; hp++) in hashdestroy() 96 free(hashtbl, type); in hashdestroy() 127 hashtbl = malloc((u_long)hashsize * sizeof(*hashtbl), type, in phashinit_flags() 129 if (hashtbl == NULL) in phashinit_flags() 133 LIST_INIT(&hashtbl[i]); in phashinit_flags() [all …]
|
H A D | vfs_cache.c | 2713 struct nchashhead *hashtbl; in nchinittbl() local 2718 hashtbl = malloc(hashsize * sizeof(*hashtbl), M_VFSCACHE, M_WAITOK); in nchinittbl() 2720 CK_SLIST_INIT(&hashtbl[i]); in nchinittbl() 2722 return (hashtbl); in nchinittbl() 2726 ncfreetbl(struct nchashhead *hashtbl) in ncfreetbl() argument 2729 free(hashtbl, M_VFSCACHE); in ncfreetbl()
|
/freebsd/sys/dev/usb/net/ |
H A D | if_udav.c | 505 uint8_t *hashtbl = arg; in udav_hash_maddr() local 509 hashtbl[h / 8] |= 1 << (h % 8); in udav_hash_maddr() 519 uint8_t hashtbl[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; in udav_setmulti() local 529 memset(hashtbl, 0x00, sizeof(hashtbl)); in udav_setmulti() 530 hashtbl[7] |= 0x80; /* broadcast address */ in udav_setmulti() 531 udav_csr_write(sc, UDAV_MAR, hashtbl, sizeof(hashtbl)); in udav_setmulti() 534 if_foreach_llmaddr(ifp, udav_hash_maddr, hashtbl); in udav_setmulti() 540 udav_csr_write(sc, UDAV_MAR, hashtbl, sizeof(hashtbl)); in udav_setmulti()
|
H A D | if_cue.c | 309 uint8_t *hashtbl = arg; in cue_hash_maddr() local 313 hashtbl[h >> 3] |= 1 << (h & 0x7); in cue_hash_maddr() 324 uint8_t hashtbl[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; in cue_setmulti() local 330 hashtbl[i] = 0xff; in cue_setmulti() 332 &hashtbl, 8); in cue_setmulti() 337 if_foreach_llmaddr(ifp, cue_hash_maddr, hashtbl); in cue_setmulti() 345 hashtbl[h >> 3] |= 1 << (h & 0x7); in cue_setmulti() 348 cue_mem(sc, CUE_CMD_WRITESRAM, CUE_MCAST_TABLE_ADDR, &hashtbl, 8); in cue_setmulti()
|
H A D | if_mos.c | 401 mos_write_mcast(struct mos_softc *sc, u_char *hashtbl) in mos_write_mcast() argument 412 err = uether_do_request(&sc->sc_ue, &req, hashtbl, 1000); in mos_write_mcast() 585 uint8_t *hashtbl = arg; in mos_hash_maddr() local 589 hashtbl[h / 8] |= 1 << (h % 8); in mos_hash_maddr() 600 uint8_t hashtbl[8] = {0, 0, 0, 0, 0, 0, 0, 0}; in mos_setmulti() local 611 if_foreach_llmaddr(ifp, mos_hash_maddr, &hashtbl); in mos_setmulti() 619 mos_write_mcast(sc, (void *)&hashtbl); in mos_setmulti()
|
H A D | if_aue.c | 542 uint8_t *hashtbl = arg; in aue_hash_maddr() local 546 hashtbl[(h >> 3)] |= 1 << (h & 0x7); in aue_hash_maddr() 557 uint8_t hashtbl[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; in aue_setmulti() local 569 if_foreach_llmaddr(ifp, aue_hash_maddr, hashtbl); in aue_setmulti() 573 aue_csr_write_1(sc, AUE_MAR0 + i, hashtbl[i]); in aue_setmulti()
|
H A D | if_smsc.c | 693 uint32_t hash, *hashtbl = arg; in smsc_hash_maddr() local 696 hashtbl[hash >> 5] |= 1 << (hash & 0x1F); in smsc_hash_maddr() 716 uint32_t hashtbl[2] = { 0, 0 }; in smsc_setmulti() local 726 if (if_foreach_llmaddr(ifp, smsc_hash_maddr, &hashtbl) > 0) { in smsc_setmulti() 748 smsc_write_reg(sc, SMSC_HASHH, hashtbl[1]); in smsc_setmulti() 749 smsc_write_reg(sc, SMSC_HASHL, hashtbl[0]); in smsc_setmulti()
|
H A D | if_axge.c | 778 uint8_t *hashtbl = arg; in axge_hash_maddr() local 782 hashtbl[h / 8] |= 1 << (h % 8); in axge_hash_maddr() 793 uint8_t hashtbl[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; in axge_rxfilter() local 819 if_foreach_llmaddr(ifp, axge_hash_maddr, &hashtbl); in axge_rxfilter() 821 axge_write_mem(sc, AXGE_ACCESS_MAC, 8, AXGE_MFA, (void *)&hashtbl, 8); in axge_rxfilter()
|
H A D | if_axe.c | 483 uint8_t *hashtbl = arg; in axe_hash_maddr() local 487 hashtbl[h / 8] |= 1 << (h % 8); in axe_hash_maddr() 498 uint8_t hashtbl[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; in axe_setmulti() local 512 if_foreach_llmaddr(ifp, axe_hash_maddr, &hashtbl); in axe_setmulti() 514 axe_cmd(sc, AXE_CMD_WRITE_MCAST, 0, 0, (void *)&hashtbl); in axe_setmulti()
|
/freebsd/contrib/less/ |
H A D | ch.c | 61 struct bufnode hashtbl[BUFHASH_SIZE]; member 82 #define END_OF_HCHAIN(h) (&thisfile->hashtbl[h]) 111 for (bn = thisfile->hashtbl[h].hnext; \ 119 (bn)->hnext = thisfile->hashtbl[h].hnext; \ 121 thisfile->hashtbl[h].hnext->hprev = (bn); \ 122 thisfile->hashtbl[h].hnext = (bn); 760 thisfile->hashtbl[h].hnext = END_OF_HCHAIN(h); in init_hashtbl() 761 thisfile->hashtbl[h].hprev = END_OF_HCHAIN(h); in init_hashtbl()
|
/freebsd/contrib/libpcap/ |
H A D | optimize.c | 332 struct valnode *hashtbl[MODULUS]; member 714 memset((char *)opt_state->hashtbl, 0, sizeof opt_state->hashtbl); in init_val() 736 for (p = opt_state->hashtbl[hash]; p; p = p->next) in F() 762 p->next = opt_state->hashtbl[hash]; in F() 763 opt_state->hashtbl[hash] = p; in F()
|