Lines Matching defs:txg

832 vdev_metaslab_init(vdev_t *vd, uint64_t txg)
842 ASSERT(txg == 0 || spa_config_held(spa, SCL_ALLOC, RW_WRITER));
876 if (txg == 0) {
884 error = metaslab_init(vd->vdev_mg, m, object, txg,
890 if (txg == 0)
901 if (txg == 0)
1370 uint64_t txg = spa_last_synced_txg(spa) != 0 ?
1373 if ((label = vdev_label_read_config(vd, txg)) == NULL) {
1565 vdev_create(vdev_t *vd, uint64_t txg, boolean_t isreplacing)
1585 (error = vdev_label_init(vd, txg, isreplacing ?
1605 vdev_dirty(vdev_t *vd, int flags, void *arg, uint64_t txg)
1613 (void) txg_list_add(&vd->vdev_ms_list, arg, txg);
1616 (void) txg_list_add(&vd->vdev_dtl_list, arg, txg);
1618 (void) txg_list_add(&vd->vdev_spa->spa_vdev_txg_list, vd, txg);
1622 vdev_dirty_leaves(vdev_t *vd, int flags, uint64_t txg)
1625 vdev_dirty_leaves(vd->vdev_child[c], flags, txg);
1628 vdev_dirty(vd->vdev_top, flags, vd, txg);
1670 vdev_dtl_dirty(vdev_t *vd, vdev_dtl_type_t t, uint64_t txg, uint64_t size)
1679 if (!range_tree_contains(rt, txg, size))
1680 range_tree_add(rt, txg, size);
1685 vdev_dtl_contains(vdev_t *vd, vdev_dtl_type_t t, uint64_t txg, uint64_t size)
1695 dirty = range_tree_contains(rt, txg, size);
1715 * Returns the lowest txg in the DTL range.
1731 * Returns the highest txg in the DTL.
1769 * value to the highest txg value that exists in all DTLs. If this
1787 vdev_dtl_reassess(vdev_t *vd, uint64_t txg, uint64_t scrub_txg, int scrub_done)
1796 vdev_dtl_reassess(vd->vdev_child[c], txg,
1828 * that each txg in that range has refcnt -1 or 0.
1867 if (txg != 0)
1868 vdev_dirty(vd->vdev_top, VDD_DTL, vd, txg);
1938 vdev_dtl_sync(vdev_t *vd, uint64_t txg)
1951 tx = dmu_tx_create_assigned(spa->spa_dsl_pool, txg);
1998 zfs_dbgmsg("txg %llu, spa %s, DTL old object %llu, "
1999 "new object %llu", txg, spa_name(spa), object,
2046 * Determine if resilver is needed, and if so the txg range.
2154 vdev_remove(vdev_t *vd, uint64_t txg)
2160 tx = dmu_tx_create_assigned(spa_get_dsl(spa), txg);
2206 vdev_sync_done(vdev_t *vd, uint64_t txg)
2209 boolean_t reassess = !txg_list_empty(&vd->vdev_ms_list, TXG_CLEAN(txg));
2213 while (msp = txg_list_remove(&vd->vdev_ms_list, TXG_CLEAN(txg)))
2214 metaslab_sync_done(msp, txg);
2221 vdev_sync(vdev_t *vd, uint64_t txg)
2232 tx = dmu_tx_create_assigned(spa->spa_dsl_pool, txg);
2244 vdev_remove(vd, txg);
2246 while ((msp = txg_list_remove(&vd->vdev_ms_list, txg)) != NULL) {
2247 metaslab_sync(msp, txg);
2248 (void) txg_list_add(&vd->vdev_ms_list, msp, TXG_CLEAN(txg));
2251 while ((lvd = txg_list_remove(&vd->vdev_dtl_list, txg)) != NULL)
2252 vdev_dtl_sync(lvd, txg);
2254 (void) txg_list_add(&spa->spa_vdev_txg_list, vd, TXG_CLEAN(txg));
2722 uint64_t txg = zio->io_txg;
2813 if (type == ZIO_TYPE_WRITE && txg != 0 &&
2820 * made by zil_claim() during spa_load() in the first txg.
2822 * txg as the block was born. In the scrub-induced repair
2833 uint64_t commit_txg = txg;
2837 vdev_dtl_dirty(vd, DTL_SCRUB, txg, 1);
2844 if (vdev_dtl_contains(vd, DTL_MISSING, txg, 1))
2847 vdev_dtl_dirty(pvd, DTL_PARTIAL, txg, 1);
2851 vdev_dtl_dirty(vd, DTL_MISSING, txg, 1);
3309 vdev_expand(vdev_t *vd, uint64_t txg)
3315 VERIFY(vdev_metaslab_init(vd, txg) == 0);