Lines Matching +defs:test +defs:db
31 * The objective of this program is to provide a DMU/ZAP/SPA stress test
38 * we have a simple routine to test that functionality. These
41 * (2) We turn these simple functionality tests into a stress test by
53 * we run the entire test in a child of the main process.
56 * The parent then runs the test again, using the existing
65 * If you add a new test, please do this if applicable.
71 * To turn this into an overnight stress test, use -T to specify run time.
295 ztest_func_t *zi_func; /* test function */
980 * If the SPA supports new MAXBLOCKSIZE, test up to 1MB blocks.
1291 ztest_bt_bonus(dmu_buf_t *db)
1296 dmu_object_info_from_db(db, &doi);
1297 ASSERT3U(doi.doi_bonus_size, <=, db->db_size);
1299 bt = (void *)((char *)db->db_data + doi.doi_bonus_size - sizeof (*bt));
1423 dmu_buf_t *db;
1485 VERIFY3U(0, ==, dmu_bonus_hold(os, lr->lr_foid, FTAG, &db));
1486 bbt = ztest_bt_bonus(db);
1487 dmu_buf_will_dirty(db, tx);
1489 dmu_buf_rele(db, FTAG);
1563 dmu_buf_t *db;
1591 VERIFY3U(0, ==, dmu_bonus_hold(os, lr->lr_foid, FTAG, &db));
1593 dmu_object_info_from_db(db, &doi);
1595 bbt = ztest_bt_bonus(db);
1607 abuf = dmu_request_arcbuf(db, length);
1613 dmu_buf_rele(db, FTAG);
1662 dmu_assign_arcbuf(db, offset, abuf, tx);
1667 dmu_buf_rele(db, FTAG);
1721 dmu_buf_t *db;
1730 VERIFY3U(0, ==, dmu_bonus_hold(os, lr->lr_foid, FTAG, &db));
1737 dmu_buf_rele(db, FTAG);
1742 bbt = ztest_bt_bonus(db);
1755 lr->lr_size = (ztest_random(db->db_size / sizeof (*bbt)) + 1) *
1767 dmu_buf_will_dirty(db, tx);
1770 ASSERT3U(lr->lr_size, <=, db->db_size);
1771 VERIFY0(dmu_set_bonus(db, lr->lr_size, tx));
1772 bbt = ztest_bt_bonus(db);
1776 dmu_buf_rele(db, FTAG);
1844 dmu_buf_t *db;
1849 error = dmu_bonus_hold(os, object, FTAG, &db);
1855 crtxg = ztest_bt_bonus(db)->bt_crtxg;
1858 dmu_buf_rele(db, FTAG);
1863 dmu_object_info_from_db(db, &doi);
1864 dmu_buf_rele(db, FTAG);
1865 db = NULL;
1890 error = dmu_buf_hold(os, object, offset, zgd, &db,
1894 blkptr_t *obp = dmu_buf_get_blkptr(db);
1900 zgd->zgd_db = db;
1903 ASSERT(db->db_offset == offset);
1904 ASSERT(db->db_size == size);
1961 dmu_buf_t *db;
1970 od->od_object, FTAG, &db));
1971 dmu_object_info_from_db(db, &doi);
1972 bbt = ztest_bt_bonus(db);
1977 dmu_buf_rele(db, FTAG);
2265 * Lookup or create the objects for a test using the od template.
3556 * This test uses two objects, packobj and bigobj, that are always
3834 * This test uses two objects, packobj and bigobj, that are always
3889 * Iteration 0 test zcopy for DB_UNCACHED dbufs.
3890 * Iteration 1 test zcopy to already referenced dbufs.
3891 * Iteration 2 test zcopy to dirty dbuf in the same txg.
3892 * Iteration 3 test zcopy to dbuf dirty in previous txg.
3893 * Iteration 4 test zcopy when dbuf is no longer dirty.
3894 * Iteration 5 test zcopy when it can't be done.
3903 * that don't match bigobj blksz to test
3949 * test dmu_assign_arcbuf() for the case when there're no
4242 * Testcase to test the upgrading of a microzap to fatzap.
4473 * Commit callback test.
5023 dmu_buf_t *db;
5039 * the pool and dataset properies we need to maintain during this test.
5070 int error = dmu_buf_hold(os, object, offset, FTAG, &db,
5076 ASSERT(db->db_offset == offset);
5077 ASSERT(db->db_size == blocksize);
5078 ASSERT(ztest_pattern_match(db->db_data, db->db_size, pattern) ||
5079 ztest_pattern_match(db->db_data, db->db_size, 0ULL));
5080 dmu_buf_will_fill(db, tx);
5081 ztest_pattern_set(db->db_data, db->db_size, pattern);
5082 dmu_buf_rele(db, FTAG);
5091 VERIFY0(dmu_buf_hold(os, object, 0, FTAG, &db,
5093 blk = *((dmu_buf_impl_t *)db)->db_blkptr;
5094 dmu_buf_rele(db, FTAG);
5408 fatal(0, "aborting test after %llu seconds because "
5422 ztest_execute(int test, ztest_info_t *zi, uint64_t id)
5425 ztest_shared_callstate_t *zc = ZTEST_GET_SHARED_CALLSTATE(test);
5917 * Then test spa_freeze() functionality.
6324 * It's possible that we killed a child during a rename test,