Home
last modified time | relevance | path

Searched refs:db (Results 1 – 25 of 849) sorted by relevance

12345678910>>...34

/freebsd/sys/contrib/openzfs/module/zfs/
H A Ddbuf.c293 dmu_buf_impl_t *db = vdb; in dbuf_cons() local
294 memset(db, 0, sizeof (dmu_buf_impl_t)); in dbuf_cons()
296 mutex_init(&db->db_mtx, NULL, MUTEX_NOLOCKDEP, NULL); in dbuf_cons()
297 rw_init(&db->db_rwlock, NULL, RW_NOLOCKDEP, NULL); in dbuf_cons()
298 cv_init(&db->db_changed, NULL, CV_DEFAULT, NULL); in dbuf_cons()
299 multilist_link_init(&db->db_cache_link); in dbuf_cons()
300 zfs_refcount_create(&db->db_holds); in dbuf_cons()
309 dmu_buf_impl_t *db = vdb; in dbuf_dest() local
310 mutex_destroy(&db->db_mtx); in dbuf_dest()
311 rw_destroy(&db->db_rwlock); in dbuf_dest()
[all …]
H A Ddmu_direct.c33 make_abd_for_dbuf(dmu_buf_impl_t *db, abd_t *data, uint64_t offset, in make_abd_for_dbuf() argument
36 size_t buf_size = db->db.db_size; in make_abd_for_dbuf()
40 ASSERT(MUTEX_HELD(&db->db_mtx)); in make_abd_for_dbuf()
42 if (offset > db->db.db_offset) { in make_abd_for_dbuf()
43 size_t pre_size = offset - db->db.db_offset; in make_abd_for_dbuf()
48 buf_off = db->db.db_offset - offset; in make_abd_for_dbuf()
92 dmu_buf_impl_t *db = dr->dr_dbuf; in dmu_write_direct_done() local
96 mutex_enter(&db->db_mtx); in dmu_write_direct_done()
97 ASSERT3P(db->db_buf, ==, NULL); in dmu_write_direct_done()
99 ASSERT3P(db->db.db_data, ==, NULL); in dmu_write_direct_done()
[all …]
H A Ddnode_sync.c44 dmu_buf_impl_t *db; in dnode_increase_indirection() local
57 db = dbuf_hold_level(dn, dn->dn_phys->dn_nlevels, 0, FTAG); in dnode_increase_indirection()
58 ASSERT(db != NULL); in dnode_increase_indirection()
78 (void) dbuf_read(db, NULL, DB_RF_MUST_SUCCEED|DB_RF_HAVESTRUCT); in dnode_increase_indirection()
81 rw_enter(&db->db_rwlock, RW_WRITER); in dnode_increase_indirection()
82 ASSERT(db->db.db_data); in dnode_increase_indirection()
83 ASSERT(arc_released(db->db_buf)); in dnode_increase_indirection()
84 ASSERT3U(sizeof (blkptr_t) * nblkptr, <=, db->db.db_size); in dnode_increase_indirection()
85 memcpy(db->db.db_data, dn->dn_phys->dn_blkptr, in dnode_increase_indirection()
87 arc_buf_freeze(db->db_buf); in dnode_increase_indirection()
[all …]
H A Ddbuf_stats.c65 __dbuf_stats_hash_table_data(char *buf, size_t size, dmu_buf_impl_t *db) in __dbuf_stats_hash_table_data() argument
69 dnode_t *dn = DB_DNODE(db); in __dbuf_stats_hash_table_data()
72 if (db->db_buf) in __dbuf_stats_hash_table_data()
73 arc_buf_info(db->db_buf, &abi, zfs_dbuf_state_index); in __dbuf_stats_hash_table_data()
84 (u_longlong_t)dmu_objset_id(db->db_objset), in __dbuf_stats_hash_table_data()
85 (longlong_t)db->db.db_object, in __dbuf_stats_hash_table_data()
86 (longlong_t)db->db_level, in __dbuf_stats_hash_table_data()
87 (longlong_t)db->db_blkid, in __dbuf_stats_hash_table_data()
88 (u_longlong_t)db->db.db_offset, in __dbuf_stats_hash_table_data()
89 (u_longlong_t)db->db.db_size, in __dbuf_stats_hash_table_data()
[all …]
/freebsd/crypto/heimdal/lib/hdb/
H A Ddb.c45 DB_close(krb5_context context, HDB *db) in DB_close() argument
47 DB *d = (DB*)db->hdb_db; in DB_close()
53 DB_destroy(krb5_context context, HDB *db) in DB_destroy() argument
57 ret = hdb_clear_master_key (context, db); in DB_destroy()
58 free(db->hdb_name); in DB_destroy()
59 free(db); in DB_destroy()
64 DB_lock(krb5_context context, HDB *db, int operation) in DB_lock() argument
66 DB *d = (DB*)db->hdb_db; in DB_lock()
70 "Can't lock database: %s", db->hdb_name); in DB_lock()
77 DB_unlock(krb5_context context, HDB *db) in DB_unlock() argument
[all …]
H A Dndbm.c49 DBM *db; member
54 NDBM_destroy(krb5_context context, HDB *db) in NDBM_destroy() argument
56 hdb_clear_master_key (context, db); in NDBM_destroy()
57 free(db->hdb_name); in NDBM_destroy()
58 free(db); in NDBM_destroy()
63 NDBM_lock(krb5_context context, HDB *db, int operation) in NDBM_lock() argument
65 struct ndbm_db *d = db->hdb_db; in NDBM_lock()
70 NDBM_unlock(krb5_context context, HDB *db) in NDBM_unlock() argument
72 struct ndbm_db *d = db->hdb_db; in NDBM_unlock()
77 NDBM_seq(krb5_context context, HDB *db, in NDBM_seq() argument
[all …]
H A Ddb3.c51 DB_close(krb5_context context, HDB *db) in DB_close() argument
53 DB *d = (DB*)db->hdb_db; in DB_close()
54 DBC *dbcp = (DBC*)db->hdb_dbc; in DB_close()
57 db->hdb_dbc = 0; in DB_close()
63 DB_destroy(krb5_context context, HDB *db) in DB_destroy() argument
67 ret = hdb_clear_master_key (context, db); in DB_destroy()
68 free(db->hdb_name); in DB_destroy()
69 free(db); in DB_destroy()
74 DB_lock(krb5_context context, HDB *db, int operation) in DB_lock() argument
76 DB *d = (DB*)db->hdb_db; in DB_lock()
[all …]
H A Dhdb-sqlite.c41 sqlite3 *db; member
127 sqlite3 *db, in hdb_sqlite_prepare_stmt() argument
133 ret = sqlite3_prepare_v2(db, str, -1, statement, NULL); in hdb_sqlite_prepare_stmt()
140 ret = sqlite3_prepare_v2(db, str, -1, statement, NULL); in hdb_sqlite_prepare_stmt()
146 str, sqlite3_errmsg(db)); in hdb_sqlite_prepare_stmt()
201 hdb_sqlite_open_database(krb5_context context, HDB *db, int flags) in hdb_sqlite_open_database() argument
204 hdb_sqlite_db *hsdb = (hdb_sqlite_db*) db->hdb_db; in hdb_sqlite_open_database()
206 ret = sqlite3_open_v2(hsdb->db_file, &hsdb->db, in hdb_sqlite_open_database()
210 if (hsdb->db) { in hdb_sqlite_open_database()
214 hsdb->db_file, sqlite3_errmsg(hsdb->db)); in hdb_sqlite_open_database()
[all …]
H A Dhdb-keytab.c49 hkt_close(krb5_context context, HDB *db) in hkt_close() argument
51 hdb_keytab k = (hdb_keytab)db->hdb_db; in hkt_close()
63 hkt_destroy(krb5_context context, HDB *db) in hkt_destroy() argument
65 hdb_keytab k = (hdb_keytab)db->hdb_db; in hkt_destroy()
68 ret = hdb_clear_master_key (context, db); in hkt_destroy()
73 free(db->hdb_name); in hkt_destroy()
74 free(db); in hkt_destroy()
79 hkt_lock(krb5_context context, HDB *db, int operation) in hkt_lock() argument
85 hkt_unlock(krb5_context context, HDB *db) in hkt_unlock() argument
91 hkt_firstkey(krb5_context context, HDB *db, in hkt_firstkey() argument
[all …]
H A Dhdb-mitdb.c476 mdb_close(krb5_context context, HDB *db) in mdb_close() argument
478 DB *d = (DB*)db->hdb_db; in mdb_close()
484 mdb_destroy(krb5_context context, HDB *db) in mdb_destroy() argument
488 ret = hdb_clear_master_key (context, db); in mdb_destroy()
489 free(db->hdb_name); in mdb_destroy()
490 free(db); in mdb_destroy()
495 mdb_lock(krb5_context context, HDB *db, int operation) in mdb_lock() argument
497 DB *d = (DB*)db->hdb_db; in mdb_lock()
501 "Can't lock database: %s", db->hdb_name); in mdb_lock()
508 mdb_unlock(krb5_context context, HDB *db) in mdb_unlock() argument
[all …]
H A Dhdb-ldap.c51 LDAP_message2entry(krb5_context context, HDB * db, LDAPMessage * msg,
66 #define HDB2LDAP(db) (((struct hdbldapdb *)(db)->hdb_db)->h_lp)
67 #define HDB2MSGID(db) (((struct hdbldapdb *)(db)->hdb_db)->h_msgid)
68 #define HDBSETMSGID(db,msgid) \
69 do { ((struct hdbldapdb *)(db)->hdb_db)->h_msgid = msgid; } while(0) argument
70 #define HDB2BASE(dn) (((struct hdbldapdb *)(db)->hdb_db)->h_base)
71 #define HDB2URL(dn) (((struct hdbldapdb *)(db)->hdb_db)->h_url)
72 #define HDB2CREATE(db) (((struc
63 HDB2LDAP(db) global() argument
64 HDB2MSGID(db) global() argument
65 HDBSETMSGID(db,msgid) global() argument
131 check_ldap(krb5_context context,HDB * db,int ret) check_ldap() argument
307 LDAP_get_string_value(HDB * db,LDAPMessage * entry,const char * attribute,char ** ptr) LDAP_get_string_value() argument
333 LDAP_get_integer_value(HDB * db,LDAPMessage * entry,const char * attribute,int * ptr) LDAP_get_integer_value() argument
348 LDAP_get_generalized_time_value(HDB * db,LDAPMessage * entry,const char * attribute,KerberosTime * kt) LDAP_get_generalized_time_value() argument
383 LDAP_entry2mods(krb5_context context,HDB * db,hdb_entry_ex * ent,LDAPMessage * msg,LDAPMod *** pmods) LDAP_entry2mods() argument
741 LDAP_dn2principal(krb5_context context,HDB * db,const char * dn,krb5_principal * principal) LDAP_dn2principal() argument
833 LDAP__lookup_princ(krb5_context context,HDB * db,const char * princname,const char * userid,LDAPMessage ** msg) LDAP__lookup_princ() argument
930 LDAP_principal2message(krb5_context context,HDB * db,krb5_const_principal princ,LDAPMessage ** msg) LDAP_principal2message() argument
972 LDAP_message2entry(krb5_context context,HDB * db,LDAPMessage * msg,int flags,hdb_entry_ex * ent) LDAP_message2entry() argument
1410 LDAP_close(krb5_context context,HDB * db) LDAP_close() argument
1421 LDAP_lock(krb5_context context,HDB * db,int operation) LDAP_lock() argument
1427 LDAP_unlock(krb5_context context,HDB * db) LDAP_unlock() argument
1433 LDAP_seq(krb5_context context,HDB * db,unsigned flags,hdb_entry_ex * entry) LDAP_seq() argument
1497 LDAP_firstkey(krb5_context context,HDB * db,unsigned flags,hdb_entry_ex * entry) LDAP_firstkey() argument
1525 LDAP_nextkey(krb5_context context,HDB * db,unsigned flags,hdb_entry_ex * entry) LDAP_nextkey() argument
1532 LDAP__connect(krb5_context context,HDB * db) LDAP__connect() argument
1588 LDAP_open(krb5_context context,HDB * db,int flags,mode_t mode) LDAP_open() argument
1607 LDAP_fetch_kvno(krb5_context context,HDB * db,krb5_const_principal principal,unsigned flags,krb5_kvno kvno,hdb_entry_ex * entry) LDAP_fetch_kvno() argument
1639 LDAP_fetch(krb5_context context,HDB * db,krb5_const_principal principal,unsigned flags,hdb_entry_ex * entry) LDAP_fetch() argument
1647 LDAP_store(krb5_context context,HDB * db,unsigned flags,hdb_entry_ex * entry) LDAP_store() argument
1728 LDAP_remove(krb5_context context,HDB * db,krb5_const_principal principal) LDAP_remove() argument
1777 LDAP_destroy(krb5_context context,HDB * db) LDAP_destroy() argument
1800 hdb_ldap_common(krb5_context context,HDB ** db,const char * search_base,const char * url) hdb_ldap_common() argument
1898 hdb_ldap_create(krb5_context context,HDB ** db,const char * arg) hdb_ldap_create() argument
1904 hdb_ldapi_create(krb5_context context,HDB ** db,const char * arg) hdb_ldapi_create() argument
[all...]
/freebsd/crypto/openssl/crypto/txt_db/
H A Dtxt_db.c128 OPENSSL_STRING *TXT_DB_get_by_index(TXT_DB *db, int idx, in TXT_DB_get_by_index() argument
134 if (idx >= db->num_fields) { in TXT_DB_get_by_index()
135 db->error = DB_ERROR_INDEX_OUT_OF_RANGE; in TXT_DB_get_by_index()
138 lh = db->index[idx]; in TXT_DB_get_by_index()
140 db->error = DB_ERROR_NO_INDEX; in TXT_DB_get_by_index()
144 db->error = DB_ERROR_OK; in TXT_DB_get_by_index()
148 int TXT_DB_create_index(TXT_DB *db, int field, int (*qual) (OPENSSL_STRING *), in TXT_DB_create_index() argument
155 if (field >= db->num_fields) { in TXT_DB_create_index()
156 db->error = DB_ERROR_INDEX_OUT_OF_RANGE; in TXT_DB_create_index()
161 db->error = DB_ERROR_MALLOC; in TXT_DB_create_index()
[all …]
/freebsd/contrib/kyua/utils/sqlite/
H A Ddatabase_test.cpp49 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
50 create_test_table(raw(db)); in ATF_TEST_CASE_BODY()
51 verify_test_table(raw(db)); in ATF_TEST_CASE_BODY()
61 ::sqlite3* db; in ATF_TEST_CASE_BODY()
62 ATF_REQUIRE_EQ(SQLITE_OK, ::sqlite3_open_v2("test.db", &db, in ATF_TEST_CASE_BODY()
64 create_test_table(db); in ATF_TEST_CASE_BODY()
65 ::sqlite3_close(db); in ATF_TEST_CASE_BODY()
68 sqlite::database db = sqlite::database::open(fs::path("test.db"), in ATF_TEST_CASE_BODY() local
70 verify_test_table(raw(db)); in ATF_TEST_CASE_BODY()
88 sqlite::database db = sqlite::database::open(fs::path("test.db"), in ATF_TEST_CASE_BODY() local
[all …]
H A Dstatement_test.cpp49 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
50 sqlite::statement stmt = db.create_statement( in ATF_TEST_CASE_BODY()
52 ATF_REQUIRE_THROW(sqlite::error, db.exec("SELECT * FROM foo")); in ATF_TEST_CASE_BODY()
54 db.exec("SELECT * FROM foo"); in ATF_TEST_CASE_BODY()
61 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
62 create_test_table(raw(db)); in ATF_TEST_CASE_BODY()
63 sqlite::statement stmt = db.create_statement( in ATF_TEST_CASE_BODY()
74 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
75 sqlite::statement stmt = db.create_statement( in ATF_TEST_CASE_BODY()
85 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
[all …]
H A Dtransaction_test.cpp54 check_in_table(sqlite::database& db, const char* table_name, in check_in_table() argument
57 sqlite::statement stmt = db.create_statement( in check_in_table()
74 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
75 db.exec("CREATE TABLE t (col INTEGER PRIMARY KEY)"); in ATF_TEST_CASE_BODY()
76 db.exec("INSERT INTO t VALUES (3)"); in ATF_TEST_CASE_BODY()
78 sqlite::transaction tx = db.begin_transaction(); in ATF_TEST_CASE_BODY()
79 db.exec("INSERT INTO t VALUES (5)"); in ATF_TEST_CASE_BODY()
81 ATF_REQUIRE( check_in_table(db, "t", "col", 3)); in ATF_TEST_CASE_BODY()
82 ATF_REQUIRE(!check_in_table(db, "t", "col", 5)); in ATF_TEST_CASE_BODY()
89 sqlite::database db = sqlite::database::in_memory(); in ATF_TEST_CASE_BODY() local
[all …]
/freebsd/lib/libc/db/test/btree.tests/
H A Dmain.c118 DB *db; local
166 db = dbopen(*argv == NULL ? NULL : *argv, O_RDWR,
169 db = dbopen(*argv == NULL ? NULL : *argv, O_CREAT|O_RDWR,
172 if (db == NULL) {
176 globaldb = db;
177 user(db);
183 user(db) in user() argument
184 DB *db; in user()
235 (*commands[i].func)(db, argv);
237 if ((db->sync)(db) == RET_ERROR)
[all …]
/freebsd/crypto/heimdal/lib/roken/
H A Dndbm_wrap.c68 dbm_close (DBM *db) in dbm_close() argument
71 D(db)->close(D(db), 0); in dbm_close()
74 D(db)->close(D(db)); in dbm_close()
79 dbm_delete (DBM *db, datum dkey) in dbm_delete() argument
84 RETURN(D(db)->del(D(db), NULL, &key, 0)); in dbm_delete()
86 RETURN(D(db)->del(D(db), &key, 0)); in dbm_delete()
91 dbm_fetch (DBM *db, datum dkey) in dbm_fetch() argument
96 if(D(db)->get(D(db), in dbm_fetch()
111 dbm_get (DB *db, int flags) in dbm_get() argument
117 db->cursor(db, NULL, &cursor, 0); in dbm_get()
[all …]
/freebsd/contrib/blocklist/bin/
H A Dstate.c63 state_close(DB *db) in state_close() argument
65 if (db == NULL) in state_close()
67 if ((*db->close)(db) == -1) { in state_close()
77 DB *db; in state_open() local
83 db = dbopen(dbname, flags, perm, DB_HASH, &openinfo); in state_open()
84 if (db == NULL) { in state_open()
89 return db; in state_open()
114 state_del(DB *db, const struct conf *c) in state_del() argument
119 if (db == NULL) in state_del()
125 switch (rv = (*db->del)(db, &k, 0)) { in state_del()
[all …]
/freebsd/contrib/ncurses/ncurses/tinfo/
H A Dhashed_db.c48 DB *db; member
59 _nc_db_close(connections->db); in cleanup()
71 result = p->db; in find_connection()
80 drop_connection(DB * db) in drop_connection() argument
85 if (p->db == db) { in drop_connection()
98 make_connection(DB * db, const char *path, bool modify) in make_connection() argument
103 p->db = db; in make_connection()
183 _nc_db_close(DB * db) in _nc_db_close() argument
187 drop_connection(db); in _nc_db_close()
189 result = db->close(db, 0); in _nc_db_close()
[all …]
/freebsd/sys/contrib/openzfs/include/os/linux/zfs/sys/
H A Dtrace_dbuf.h49 (db != NULL && \
50 POINTER_IS_VALID(DB_DNODE(db)->dn_objset)) \
51 ? spa_name(DB_DNODE(db)->dn_objset->os_spa) : "NULL"
65 if (db != NULL) { \
67 __entry->ds_object = db->db_objset->os_dsl_dataset ? \
68 db->db_objset->os_dsl_dataset->ds_object : 0; \
70 __entry->db_object = db->db.db_object; \
71 __entry->db_level = db->db_level; \
72 __entry->db_blkid = db->db_blkid; \
73 __entry->db_offset = db->db.db_offset; \
[all …]
/freebsd/contrib/netbsd-tests/lib/libc/db/
H A Dt_db_hash_seq.c92 state_close(DB *db) in state_close() argument
94 if (db == NULL) in state_close()
96 if ((*db->close)(db) == -1) in state_close()
104 DB *db; in state_open() local
106 db = dbopen(dbname, flags, perm, DB_HASH, &openinfo); in state_open()
107 if (db == NULL) { in state_open()
112 return db; in state_open()
125 state_del(DB *db, const struct conf *c) in state_del() argument
130 if (db == NULL) in state_del()
136 switch (rv = (*db->del)(db, &k, 1)) { in state_del()
[all …]
/freebsd/contrib/kyua/store/
H A Dmetadata_test.cpp59 sqlite::database db = sqlite::database::in_memory(); in create_database() local
60 store::detail::initialize(db); in create_database()
61 db.exec("DELETE FROM metadata"); in create_database()
62 return db; in create_database()
77 sqlite::database db = create_database(); in ATF_TEST_CASE_BODY() local
78 db.exec("INSERT INTO metadata (schema_version, timestamp) " in ATF_TEST_CASE_BODY()
80 db.exec("INSERT INTO metadata (schema_version, timestamp) " in ATF_TEST_CASE_BODY()
83 const store::metadata metadata = store::metadata::fetch_latest(db); in ATF_TEST_CASE_BODY()
97 sqlite::database db = create_database(); in ATF_TEST_CASE_BODY() local
99 store::metadata::fetch_latest(db)); in ATF_TEST_CASE_BODY()
[all …]
/freebsd/sys/dev/mailbox/arm/
H A Darm_doorbell.c78 struct arm_doorbell *db; in arm_doorbell_lp_intr() local
87 db = &dbells[i]; in arm_doorbell_lp_intr()
90 if (db->func != NULL) in arm_doorbell_lp_intr()
91 db->func(db->arg); in arm_doorbell_lp_intr()
100 struct arm_doorbell *db; in arm_doorbell_hp_intr() local
109 db = &dbells[i]; in arm_doorbell_hp_intr()
112 if (db->func != NULL) in arm_doorbell_hp_intr()
113 db->func(db->arg); in arm_doorbell_hp_intr()
185 struct arm_doorbell *db; in arm_doorbell_ofw_get() local
252 db = &dbells[chan * db_id]; in arm_doorbell_ofw_get()
[all …]
/freebsd/lib/libc/db/hash/
H A Dndbm.c77 dbm_close(DBM *db) in dbm_close() argument
79 (void)(db->close)(db); in dbm_close()
88 dbm_fetch(DBM *db, datum key) in dbm_fetch() argument
96 status = (db->get)(db, &dbtkey, &dbtretdata, 0); in dbm_fetch()
112 dbm_firstkey(DBM *db) in dbm_firstkey() argument
118 status = (db->seq)(db, &dbtretkey, &dbtretdata, R_FIRST); in dbm_firstkey()
132 dbm_nextkey(DBM *db) in dbm_nextkey() argument
138 status = (db->seq)(db, &dbtretkey, &dbtretdata, R_NEXT); in dbm_nextkey()
152 dbm_delete(DBM *db, datum key) in dbm_delete() argument
159 status = (db->del)(db, &dbtkey, 0); in dbm_delete()
[all …]
/freebsd/crypto/openssl/apps/
H A Dsrp.c38 static int get_index(CA_DB *db, char *id, char type) in get_index() argument
45 for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++) { in get_index()
46 pp = sk_OPENSSL_PSTRING_value(db->db->data, i); in get_index()
52 for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++) { in get_index()
53 pp = sk_OPENSSL_PSTRING_value(db->db->data, i); in get_index()
64 static void print_entry(CA_DB *db, int indx, int verbose, char *s) in print_entry() argument
68 char **pp = sk_OPENSSL_PSTRING_value(db->db->data, indx); in print_entry()
76 static void print_index(CA_DB *db, int indexindex, int verbose) in print_index() argument
78 print_entry(db, indexindex, verbose, "g N entry"); in print_index()
81 static void print_user(CA_DB *db, int userindex, int verbose) in print_user() argument
[all …]

12345678910>>...34