Lines Matching refs:BUCKET
138 #define TDB_HASH_TOP(hash) (FREELIST_TOP + (BUCKET(hash)+1)*sizeof(tdb_off_t))
161 #define BUCKET(hash) ((hash) % tdb->header.hash_size) macro
747 return tdb_lock(tdb, BUCKET(tdb->hash_fn(&key)), F_WRLCK); in tdb_chainlock()
755 return tdb_lock_nonblock(tdb, BUCKET(tdb->hash_fn(&key)), F_WRLCK); in tdb_chainlock_nonblock()
761 return tdb_lock(tdb, BUCKET(tdb->hash_fn(&key)), F_WRLCK | TDB_MARK_LOCK); in tdb_chainlock_mark()
767 return tdb_unlock(tdb, BUCKET(tdb->hash_fn(&key)), F_WRLCK | TDB_MARK_LOCK); in tdb_chainlock_unmark()
772 return tdb_unlock(tdb, BUCKET(tdb->hash_fn(&key)), F_WRLCK); in tdb_chainunlock()
777 return tdb_lock(tdb, BUCKET(tdb->hash_fn(&key)), F_RDLCK); in tdb_chainlock_read()
782 return tdb_unlock(tdb, BUCKET(tdb->hash_fn(&key)), F_RDLCK); in tdb_chainunlock_read()
2927 tdb->travlocks.hash = BUCKET(rec.full_hash); in tdb_nextkey()
2946 if (tdb_unlock(tdb, BUCKET(oldhash), tdb->travlocks.lock_rw) != 0) in tdb_nextkey()
3141 if (tdb_lock(tdb, BUCKET(hash), locktype) == -1) in tdb_find_lock_hash()
3144 tdb_unlock(tdb, BUCKET(hash), locktype); in tdb_find_lock_hash()
3202 tdb_unlock(tdb, BUCKET(rec.full_hash), F_RDLCK); in tdb_fetch()
3242 tdb_unlock(tdb, BUCKET(rec.full_hash), F_RDLCK); in tdb_parse_record()
3259 tdb_unlock(tdb, BUCKET(rec.full_hash), F_RDLCK); in tdb_exists_hash()
3378 if (tdb_lock(tdb, BUCKET(hash), F_WRLCK) == -1) in tdb_delete_hash()
3390 tdb_unlock(tdb, BUCKET(hash), F_WRLCK); in tdb_delete_hash()
3412 if (tdb_unlock(tdb, BUCKET(rec.full_hash), F_WRLCK) != 0) in tdb_delete_hash()
3472 if (tdb_lock(tdb, BUCKET(hash), F_WRLCK) == -1) in tdb_store()
3590 tdb_unlock(tdb, BUCKET(hash), F_WRLCK); in tdb_store()
3604 if (tdb_lock(tdb, BUCKET(hash), F_WRLCK) == -1) in tdb_append()
3631 tdb_unlock(tdb, BUCKET(hash), F_WRLCK); in tdb_append()