/src/sys/sys/ |
hash.h | 1 /* $NetBSD: hash.h,v 1.8 2014/09/05 05:46:15 matt Exp $ */ 38 #include <machine/hash.h> 41 #ifndef __HAVE_HASH32_BUF /* not overridden by MD hash */ 47 * hash32_buf(const void *bf, size_t len, uint32_t hash) 48 * return a 32 bit hash of the binary buffer buf (size len), 49 * seeded with an initial hash value of hash (usually HASH32_BUF_INIT). 52 hash32_buf(const void *bf, size_t len, uint32_t hash) 57 hash = hash * 257 + *s++ [all...] |
hash.h | 1 /* $NetBSD: hash.h,v 1.8 2014/09/05 05:46:15 matt Exp $ */ 38 #include <machine/hash.h> 41 #ifndef __HAVE_HASH32_BUF /* not overridden by MD hash */ 47 * hash32_buf(const void *bf, size_t len, uint32_t hash) 48 * return a 32 bit hash of the binary buffer buf (size len), 49 * seeded with an initial hash value of hash (usually HASH32_BUF_INIT). 52 hash32_buf(const void *bf, size_t len, uint32_t hash) 57 hash = hash * 257 + *s++ [all...] |
/src/lib/libintl/ |
strhash.c | 40 * string hash function by P.J.Weinberger. 48 uint32_t hash = 0, tmp; local in function:__intl_string_hash 51 hash <<= 4; 52 hash += *p; 53 tmp = hash & 0xF0000000; 55 hash ^= tmp; 56 hash ^= tmp >> 24; 59 return hash;
|
strhash.c | 40 * string hash function by P.J.Weinberger. 48 uint32_t hash = 0, tmp; local in function:__intl_string_hash 51 hash <<= 4; 52 hash += *p; 53 tmp = hash & 0xF0000000; 55 hash ^= tmp; 56 hash ^= tmp >> 24; 59 return hash;
|
/src/tests/lib/libcrypt/ |
t_crypt.c | 73 const char *hash; member in struct:__anondf4c2ba30108 143 for (size_t i = 0; tests[i].hash; i++) { 144 char *hash = crypt(tests[i].pw, tests[i].hash); local in function:ATF_TC_BODY 145 if (!hash) { 149 if (strcmp(hash, "*0") == 0 && strlen(tests[i].hash) < 13) 151 if (strcmp(hash, tests[i].hash)) 153 i, hash, tests[i].hash) [all...] |
t_crypt.c | 73 const char *hash; member in struct:__anondf4c2ba30108 143 for (size_t i = 0; tests[i].hash; i++) { 144 char *hash = crypt(tests[i].pw, tests[i].hash); local in function:ATF_TC_BODY 145 if (!hash) { 149 if (strcmp(hash, "*0") == 0 && strlen(tests[i].hash) < 13) 151 if (strcmp(hash, tests[i].hash)) 153 i, hash, tests[i].hash) [all...] |
/src/lib/libc/citrus/ |
citrus_db_hash.c | 57 uint32_t hash = 0, tmp; local in function:_citrus_db_hash_std 61 hash <<= 4; 62 hash += _bcs_tolower(*p); 63 tmp = hash & 0xF0000000; 65 hash ^= tmp; 66 hash ^= tmp >> 24; 70 return hash;
|
citrus_db_hash.c | 57 uint32_t hash = 0, tmp; local in function:_citrus_db_hash_std 61 hash <<= 4; 62 hash += _bcs_tolower(*p); 63 tmp = hash & 0xF0000000; 65 hash ^= tmp; 66 hash ^= tmp >> 24; 70 return hash;
|
/src/sys/external/bsd/drm2/dist/drm/vboxvideo/ |
vbox_hgsmi.c | 16 /* One-at-a-Time Hash from http://www.burtleburtle.net/bob/hash/doobs.html */ 17 static u32 hgsmi_hash_process(u32 hash, const u8 *data, int size) 20 hash += *data++; 21 hash += (hash << 10); 22 hash ^= (hash >> 6); 25 return hash; 28 static u32 hgsmi_hash_end(u32 hash) [all...] |
vbox_hgsmi.c | 16 /* One-at-a-Time Hash from http://www.burtleburtle.net/bob/hash/doobs.html */ 17 static u32 hgsmi_hash_process(u32 hash, const u8 *data, int size) 20 hash += *data++; 21 hash += (hash << 10); 22 hash ^= (hash >> 6); 25 return hash; 28 static u32 hgsmi_hash_end(u32 hash) [all...] |
/src/sys/net/agr/ |
if_agrether_hash.c | 34 #include <sys/hash.h> 48 #define HASH(p, l, h) hash32_buf((p), (l), (h)) 76 uint32_t hash = HASH32_BUF_INIT; local in function:agrether_hashmbuf 83 return hash; 86 hash = HASH(&eh->ether_dhost, sizeof(eh->ether_dhost), hash); 87 hash = HASH(&eh->ether_shost, sizeof(eh->ether_shost), hash); [all...] |
if_agrether_hash.c | 34 #include <sys/hash.h> 48 #define HASH(p, l, h) hash32_buf((p), (l), (h)) 76 uint32_t hash = HASH32_BUF_INIT; local in function:agrether_hashmbuf 83 return hash; 86 hash = HASH(&eh->ether_dhost, sizeof(eh->ether_dhost), hash); 87 hash = HASH(&eh->ether_shost, sizeof(eh->ether_shost), hash); [all...] |
/src/usr.bin/cksum/ |
cksum.c | 112 const struct hash { struct 148 static int hash_digest_file(char *, const struct hash *, int); 162 const struct hash *hash; local in function:main 177 for (hash = hashes; hash->hashname != NULL; hash++) 178 if (strcmp(progname, hash->progname) == 0) 181 if (hash->hashname == NULL) { 182 hash = NULL [all...] |
cksum.c | 112 const struct hash { struct 148 static int hash_digest_file(char *, const struct hash *, int); 162 const struct hash *hash; local in function:main 177 for (hash = hashes; hash->hashname != NULL; hash++) 178 if (strcmp(progname, hash->progname) == 0) 181 if (hash->hashname == NULL) { 182 hash = NULL [all...] |
/src/sys/ufs/ext2fs/ |
ext2fs_hash.c | 176 ext2fs_half_md4(uint32_t hash[4], uint32_t data[8]) 178 uint32_t a = hash[0], b = hash[1], c = hash[2], d = hash[3]; 210 hash[0] += a; 211 hash[1] += b; 212 hash[2] += c; 213 hash[3] += d; 220 ext2fs_tea(uint32_t hash[4], uint32_t data[8] 244 uint32_t hash[4]; local in function:ext2fs_htree_hash [all...] |
ext2fs_hash.c | 176 ext2fs_half_md4(uint32_t hash[4], uint32_t data[8]) 178 uint32_t a = hash[0], b = hash[1], c = hash[2], d = hash[3]; 210 hash[0] += a; 211 hash[1] += b; 212 hash[2] += c; 213 hash[3] += d; 220 ext2fs_tea(uint32_t hash[4], uint32_t data[8] 244 uint32_t hash[4]; local in function:ext2fs_htree_hash [all...] |
/src/sys/external/bsd/drm/dist/bsd-core/ |
drm_auth.c | 49 int hash = drm_hash_magic(magic); local in function:drm_find_file 53 for (pt = dev->magiclist[hash].head; pt; pt = pt->next) { 63 * Inserts the given magic number into the hash table of used magic number 69 int hash; local in function:drm_add_magic 76 hash = drm_hash_magic(magic); 84 if (dev->magiclist[hash].tail) { 85 dev->magiclist[hash].tail->next = entry; 86 dev->magiclist[hash].tail = entry; 88 dev->magiclist[hash].head = entry; 89 dev->magiclist[hash].tail = entry 103 int hash; local in function:drm_remove_magic [all...] |
drm_auth.c | 49 int hash = drm_hash_magic(magic); local in function:drm_find_file 53 for (pt = dev->magiclist[hash].head; pt; pt = pt->next) { 63 * Inserts the given magic number into the hash table of used magic number 69 int hash; local in function:drm_add_magic 76 hash = drm_hash_magic(magic); 84 if (dev->magiclist[hash].tail) { 85 dev->magiclist[hash].tail->next = entry; 86 dev->magiclist[hash].tail = entry; 88 dev->magiclist[hash].head = entry; 89 dev->magiclist[hash].tail = entry 103 int hash; local in function:drm_remove_magic [all...] |
/src/sys/external/bsd/gnu-efi/dist/gnuefi/ |
elf_x86_64_fbsd_efi.lds | 11 /* .hash and/or .gnu.hash MUST come first! */ 12 .hash : { *(.hash) } 13 .gnu.hash : { *(.gnu.hash) }
|
elf_x86_64_fbsd_efi.lds | 11 /* .hash and/or .gnu.hash MUST come first! */ 12 .hash : { *(.hash) } 13 .gnu.hash : { *(.gnu.hash) }
|
/src/sys/coda/ |
coda_namecache.c | 64 * hash table. 99 int coda_nc_hashsize = CODA_NC_HASHSIZE; /* size of the primary hash */ 102 struct coda_hash *coda_nc_hash; /* hash table of cfscache pointers */ 117 kauth_cred_t cred, int hash); 122 * Initialize the cache, the LRU structure and the Hash structure(s) 140 printf("CODA NAME CACHE: CACHE %d, HASH TBL %d\n", CODA_NC_CACHESIZE, CODA_NC_HASHSIZE); 167 kauth_cred_t cred, int hash) 170 * hash to find the appropriate bucket, look through the chain 177 myprintf(("coda_nc_find(dcp %p, name %s, len %d, cred %p, hash %d\n", 178 dcp, name, namelen, cred, hash));) 220 int hash; local in function:coda_nc_enter 291 int hash; local in function:coda_nc_lookup 472 int hash; local in function:coda_nc_zapfile 515 int hash; local in function:coda_nc_purge_user 611 int hash; local in function:print_coda_nc [all...] |
coda_namecache.c | 64 * hash table. 99 int coda_nc_hashsize = CODA_NC_HASHSIZE; /* size of the primary hash */ 102 struct coda_hash *coda_nc_hash; /* hash table of cfscache pointers */ 117 kauth_cred_t cred, int hash); 122 * Initialize the cache, the LRU structure and the Hash structure(s) 140 printf("CODA NAME CACHE: CACHE %d, HASH TBL %d\n", CODA_NC_CACHESIZE, CODA_NC_HASHSIZE); 167 kauth_cred_t cred, int hash) 170 * hash to find the appropriate bucket, look through the chain 177 myprintf(("coda_nc_find(dcp %p, name %s, len %d, cred %p, hash %d\n", 178 dcp, name, namelen, cred, hash));) 220 int hash; local in function:coda_nc_enter 291 int hash; local in function:coda_nc_lookup 472 int hash; local in function:coda_nc_zapfile 515 int hash; local in function:coda_nc_purge_user 611 int hash; local in function:print_coda_nc [all...] |
/src/usr.bin/make/unit-tests/ |
varmod-hash.mk | 1 # $NetBSD: varmod-hash.mk,v 1.6 2024/07/20 11:05:12 rillig Exp $ 3 # Tests for the :hash variable modifier, which computes a 32-bit hash from 53 .for hash input in ${VECTORS} 54 . if ${input:S,^""$,,:hash} != ${hash} 55 . warning Expected ${hash} for ${input}, but was ${input:hash}. 63 @echo ${12345:L:hash} # ok 65 @echo ${12345:L:hash=SHA-256} # :hash does not accept '= [all...] |
varmod-hash.mk | 1 # $NetBSD: varmod-hash.mk,v 1.6 2024/07/20 11:05:12 rillig Exp $ 3 # Tests for the :hash variable modifier, which computes a 32-bit hash from 53 .for hash input in ${VECTORS} 54 . if ${input:S,^""$,,:hash} != ${hash} 55 . warning Expected ${hash} for ${input}, but was ${input:hash}. 63 @echo ${12345:L:hash} # ok 65 @echo ${12345:L:hash=SHA-256} # :hash does not accept '= [all...] |
/src/sys/external/bsd/drm2/include/linux/ |
hashtable.h | 37 #include <linux/hash.h> 44 __hash_init(struct hlist_head *hash, unsigned n) 48 INIT_HLIST_HEAD(&hash[n]); 52 __hash_empty(struct hlist_head *hash, unsigned n) 56 if (!hlist_empty(&hash[n]))
|