Data Fields
lruhash_entry Struct Reference

An entry into the hash table. More...

#include <lruhash.h>

Data Fields

lock_rw_t lock
 rwlock for access to the contents of the entry Note that it does _not_ cover the lru_ and overflow_ ptrs.
struct lruhash_entryoverflow_next
 next entry in overflow chain.
struct lruhash_entrylru_next
 next entry in lru chain.
struct lruhash_entrylru_prev
 prev entry in lru chain.
hashvalue_t hash
 hash value of the key.
void * key
 key
void * data
 data

Detailed Description

An entry into the hash table.

To change overflow_next you need to hold the bin lock. To change the lru items you need to hold the hashtable lock. This structure is designed as part of key struct. And key pointer helps to get the surrounding structure. Data should be allocated on its own.


Field Documentation

next entry in lru chain.

covered by hashlock.

Referenced by dump_rrset_lruhash(), dump_msg_lruhash(), check_table(), check_lru_table(), reclaim_space(), lru_front(), and lru_remove().

prev entry in lru chain.

covered by hashlock.

Referenced by check_table(), check_lru_table(), reclaim_space(), lru_front(), and lru_remove().


The documentation for this struct was generated from the following file: