/nscd/ |
A D | mem.c | 158 he_data = &he[db->head->nentries]; in gc() 168 assert (cnt < db->head->nentries); in gc() 215 db->head->first_free = 0; in gc() 425 (size_t) (db->head->first_free in gc() 461 > db->head->first_free) in gc() 471 > db->head->first_free) in gc() 487 msync (db->head, db->data + db->head->first_free - (char *) db->head, in gc() 529 if (__glibc_unlikely (db->head->first_free + len > db->head->data_size)) in mempool_alloc() 537 + db->head->data_size); in mempool_alloc() 572 ++db->head->addfailed; in mempool_alloc() [all …]
|
A D | cache.c | 103 ++table->head->neghit; in cache_search() 106 ++table->head->poshit; in cache_search() 189 ++table->head->negmiss; in cache_add() 191 ++table->head->posmiss; in cache_add() 205 msync ((void *) table->head, in cache_add() 206 (char *) &table->head->array[hash] - (char *) table->head in cache_add() 450 ++table->head->wrlockdelayed; in prune_cache() 478 runp->dellist = head; in prune_cache() 479 head = runp; in prune_cache() 508 msync (table->head, in prune_cache() [all …]
|
A D | nscd-client.h | 246 memset (head, 0, sizeof (*head)); in datahead_init_common() 248 head->allocsize = allocsize; in datahead_init_common() 249 head->recsize = recsize; in datahead_init_common() 250 head->usable = true; in datahead_init_common() 252 head->ttl = ttl; in datahead_init_common() 255 return head->timeout = time (NULL) + ttl; in datahead_init_common() 264 head->notfound = false; in datahead_init_pos() 265 head->nreloads = nreloads; in datahead_init_pos() 278 head->notfound = true; in datahead_init_neg() 352 const struct database_pers_head *head; member [all …]
|
A D | nscd_helper.c | 340 struct database_pers_head *head = mapping; in __nscd_get_mapping() local 343 || __builtin_expect (head->header_size != sizeof (*head), 0) in __nscd_get_mapping() 346 || __builtin_expect (head->module == 0, 0) in __nscd_get_mapping() 350 && (head->timestamp + MAPPING_TIMEOUT in __nscd_get_mapping() 358 size_t size = (sizeof (*head) + roundup (head->module * sizeof (ref_t), in __nscd_get_mapping() 360 + head->data_size); in __nscd_get_mapping() 371 newp->head = mapping; in __nscd_get_mapping() 375 newp->datasize = head->data_size; in __nscd_get_mapping() 416 || (cur->head->nscd_certainly_running == 0 in __nscd_get_map_ref() 418 || cur->head->data_size > cur->datasize) in __nscd_get_map_ref() [all …]
|
A D | connections.c | 364 if (memcmp (head, readhead, sizeof (*head)) != 0) in verify_persistent_db() 369 || head->header_size != sizeof (*head) in verify_persistent_db() 376 || (size_t) head->data_size > INT32_MAX - head->module * sizeof (ref_t) in verify_persistent_db() 378 || head->first_free > head->data_size in verify_persistent_db() 388 const char *data = (char *) &head->array[roundup (head->module, in verify_persistent_db() 523 else if (head.module == 0 && head.data_size == 0) in nscd_init() 530 else if (head.header_size != (int) sizeof (head)) in nscd_init() 568 &dbs[cnt].head->array[roundup (dbs[cnt].head->module, in nscd_init() 718 if ((TEMP_FAILURE_RETRY (write (fd, &head, sizeof (head))) in nscd_init() 719 != sizeof (head)) in nscd_init() [all …]
|
A D | nscd_stat.c | 133 if (dbs[cnt].head != NULL) in send_stats() 135 data.dbs[cnt].module = dbs[cnt].head->module; in send_stats() 136 data.dbs[cnt].poshit = dbs[cnt].head->poshit; in send_stats() 137 data.dbs[cnt].neghit = dbs[cnt].head->neghit; in send_stats() 138 data.dbs[cnt].posmiss = dbs[cnt].head->posmiss; in send_stats() 139 data.dbs[cnt].negmiss = dbs[cnt].head->negmiss; in send_stats() 140 data.dbs[cnt].nentries = dbs[cnt].head->nentries; in send_stats() 141 data.dbs[cnt].maxnentries = dbs[cnt].head->maxnentries; in send_stats() 142 data.dbs[cnt].datasize = dbs[cnt].head->data_size; in send_stats() 143 data.dbs[cnt].dataused = dbs[cnt].head->first_free; in send_stats() [all …]
|
A D | netgroupcache.c | 63 struct datahead head; member 93 timeout = datahead_init_neg (&dataset->head, in do_notfound() 378 if (dataset->head.allocsize == dh->allocsize in addgetnetgrentX() 379 && dataset->head.recsize == dh->recsize in addgetnetgrentX() 386 dh->timeout = dataset->head.timeout; in addgetnetgrentX() 387 dh->ttl = dataset->head.ttl; in addgetnetgrentX() 483 timeout = result->head.timeout; in addinnetgrX() 499 struct datahead head; in addinnetgrX() member 518 dataset->head.notfound = result->head.notfound; in addinnetgrX() 519 dataset->head.timeout = timeout; in addinnetgrX() [all …]
|
A D | pwdcache.c | 88 struct datahead head; in cache_addpw() member 134 timeout = datahead_init_neg (&dataset->head, in cache_addpw() 156 &dataset->head, true, db, owner, he == NULL); in cache_addpw() 219 timeout = datahead_init_pos (&dataset->head, total + n, in cache_addpw() 257 if (dataset->head.allocsize == dh->allocsize in cache_addpw() 258 && dataset->head.recsize == dh->recsize in cache_addpw() 265 dh->timeout = dataset->head.timeout; in cache_addpw() 295 if (writeall (fd, &dataset->resp, dataset->head.recsize) in cache_addpw() 296 != dataset->head.recsize) in cache_addpw() 334 &dataset->head, true, db, owner, he == NULL) < 0) in cache_addpw() [all …]
|
A D | initgrcache.c | 66 struct datahead head; in addinitgroupsX() member 211 timeout = datahead_init_neg (&dataset->head, in addinitgroupsX() 233 &dataset->head, true, db, uid, he == NULL); in addinitgroupsX() 270 timeout = datahead_init_pos (&dataset->head, total + req->key_len, in addinitgroupsX() 315 dh->timeout = dataset->head.timeout; in addinitgroupsX() 345 if (writeall (fd, &dataset->resp, dataset->head.recsize) in addinitgroupsX() 346 != dataset->head.recsize) in addinitgroupsX() 365 (void) cache_add (INITGROUPS, cp, req->key_len, &dataset->head, true, in addinitgroupsX()
|
A D | grpcache.c | 82 struct datahead head; in cache_addgr() member 127 timeout = datahead_init_neg (&dataset->head, in cache_addgr() 149 &dataset->head, true, db, owner, he == NULL); in cache_addgr() 236 timeout = datahead_init_pos (&dataset->head, total + n, in cache_addgr() 281 dh->timeout = dataset->head.timeout; in cache_addgr() 317 if (writeall (fd, &dataset->resp, dataset->head.recsize) in cache_addgr() 318 != dataset->head.recsize) in cache_addgr() 345 if (cache_add (GETGRBYGID, cp, key_offset, &dataset->head, true, in cache_addgr() 355 &dataset->head, true, db, owner, he == NULL) < 0) in cache_addgr() 365 &dataset->head, first, db, owner, in cache_addgr() [all …]
|
A D | servicescache.c | 76 struct datahead head; in cache_addserv() member 122 timeout = datahead_init_neg (&dataset->head, in cache_addserv() 144 &dataset->head, true, db, owner, he == NULL); in cache_addserv() 205 timeout = datahead_init_pos (&dataset->head, total + req->key_len, in cache_addserv() 248 dh->timeout = dataset->head.timeout; in cache_addserv() 280 if (writeall (fd, &dataset->resp, dataset->head.recsize) in cache_addserv() 281 != dataset->head.recsize) in cache_addserv() 300 &dataset->head, true, db, owner, he == NULL); in cache_addserv()
|
A D | hstcache.c | 104 struct datahead head; in cache_addhst() member 152 timeout = datahead_init_neg (&dataset->head, in cache_addhst() 175 &dataset->head, true, db, owner, he == NULL); in cache_addhst() 253 timeout = datahead_init_pos (&dataset->head, total + req->key_len, in cache_addhst() 296 assert ((char *) &dataset->resp + dataset->head.recsize == cp); in cache_addhst() 313 dh->ttl = dataset->head.ttl; in cache_addhst() 314 dh->timeout = dataset->head.timeout; in cache_addhst() 352 if (writeall (fd, &dataset->resp, dataset->head.recsize) in cache_addhst() 353 != dataset->head.recsize) in cache_addhst() 392 &dataset->head, true, db, owner, he == NULL); in cache_addhst()
|
A D | nscd_gethst_r.c | 114 && map->head->nscd_certainly_running == 0 in __nscd_get_nl_timestamp() 115 && map->head->timestamp + MAPPING_TIMEOUT < time_now ())) in __nscd_get_nl_timestamp() 121 retval = map->head->extra_data[NSCD_HST_IDX_CONF_TIMESTAMP]; in __nscd_get_nl_timestamp() 182 if (mapped->head->gc_cycle != gc_cycle) in nscd_gethst_r() 369 if (addr_list != NULL && mapped->head->gc_cycle != gc_cycle) in nscd_gethst_r() 378 if (addr_list != NULL && mapped->head->gc_cycle != gc_cycle) in nscd_gethst_r() 411 if (mapped->head->gc_cycle != gc_cycle) in nscd_gethst_r()
|
A D | aicache.c | 60 struct datahead head; in addhstaiX() member 362 timeout = datahead_init_pos (&dataset->head, total + req->key_len, in addhstaiX() 397 dh->timeout = dataset->head.timeout; in addhstaiX() 398 dh->ttl = dataset->head.ttl; in addhstaiX() 428 writeall (fd, &dataset->resp, dataset->head.recsize); in addhstaiX() 477 timeout = datahead_init_neg (&dataset->head, in addhstaiX() 504 (void) cache_add (req->type, key_copy, req->key_len, &dataset->head, in addhstaiX()
|
A D | nscd_getgr_r.c | 119 if (mapped->head->gc_cycle != gc_cycle) in nscd_getgr_r() 241 if (gr_name != NULL && mapped->head->gc_cycle != gc_cycle) in nscd_getgr_r() 249 if (gr_name != NULL && mapped->head->gc_cycle != gc_cycle) in nscd_getgr_r() 288 retval = mapped->head->gc_cycle != gc_cycle ? -2 : -1; in nscd_getgr_r()
|
A D | nscd_getserv_r.c | 133 if (mapped->head->gc_cycle != gc_cycle) in nscd_getserv_r() 296 if (aliases_list != NULL && mapped->head->gc_cycle != gc_cycle) in nscd_getserv_r() 306 if (aliases_list != NULL && mapped->head->gc_cycle != gc_cycle) in nscd_getserv_r() 339 if (mapped->head->gc_cycle != gc_cycle) in nscd_getserv_r()
|
A D | nscd_getai.c | 84 if (mapped->head->gc_cycle != gc_cycle) in __nscd_getai() 160 if (mapped->head->gc_cycle != gc_cycle) in __nscd_getai()
|
A D | nscd_getpw_r.c | 111 if (mapped->head->gc_cycle != gc_cycle) in nscd_getpw_r() 201 retval = mapped->head->gc_cycle != gc_cycle ? -2 : -1; in nscd_getpw_r()
|
A D | nscd_netgroup.c | 73 if (mapped->head->gc_cycle != gc_cycle) in __nscd_setnetgrent() 226 if (mapped->head->gc_cycle != gc_cycle) in __nscd_innetgr()
|
A D | nscd.c | 572 if (!dbs[cnt].enabled || dbs[cnt].head == NULL) in termination_handler() 576 dbs[cnt].head->timestamp = 0; in termination_handler() 580 msync (dbs[cnt].head, dbs[cnt].memsize, MS_ASYNC); in termination_handler()
|
A D | nscd_initgroups.c | 66 if (mapped->head->gc_cycle != gc_cycle) in __nscd_getgrouplist()
|
A D | nscd.h | 153 struct database_pers_head *head; member
|