Lines Matching refs:ms_sm

464 	if (txg != spa_syncing_txg(spa) || msp->ms_sm == NULL ||
468 sm_free_space = msp->ms_size - space_map_allocated(msp->ms_sm) -
469 space_map_alloc_delta(msp->ms_sm);
715 if (msp->ms_sm == NULL)
720 msp->ms_sm->sm_phys->smp_histogram[i];
736 if (msp->ms_sm == NULL)
742 msp->ms_sm->sm_phys->smp_histogram[i];
744 msp->ms_sm->sm_phys->smp_histogram[i];
756 if (msp->ms_sm == NULL)
762 msp->ms_sm->sm_phys->smp_histogram[i]);
764 msp->ms_sm->sm_phys->smp_histogram[i]);
767 msp->ms_sm->sm_phys->smp_histogram[i];
769 msp->ms_sm->sm_phys->smp_histogram[i];
1347 if (msp->ms_sm != NULL)
1348 error = space_map_load(msp->ms_sm, msp->ms_tree, SM_FREE);
1400 error = space_map_open(&ms->ms_sm, mos, object, ms->ms_start,
1408 ASSERT(ms->ms_sm != NULL);
1440 if (metaslab_debug_load && ms->ms_sm != NULL) {
1465 vdev_space_update(mg->mg_vd, -space_map_allocated(msp->ms_sm),
1467 space_map_close(msp->ms_sm);
1554 if (msp->ms_sm == NULL) {
1563 if (msp->ms_sm->sm_dbuf->db_size != sizeof (space_map_phys_t)) {
1579 uint8_t shift = msp->ms_sm->sm_shift;
1584 if (msp->ms_sm->sm_phys->smp_histogram[i] == 0)
1587 space = msp->ms_sm->sm_phys->smp_histogram[i] << (i + shift);
1619 space = msp->ms_size - space_map_allocated(msp->ms_sm);
1726 if (msp->ms_sm->sm_phys->smp_histogram[i] != 0) {
1728 msp->ms_sm->sm_phys->smp_histogram[i]);
1730 msp->ms_sm->sm_shift);
1755 if (space_map_allocated(msp->ms_sm) == 0) {
1772 ASSERT3U(msp->ms_sm->sm_dbuf->db_size, ==, sizeof (space_map_phys_t));
1777 if (space_map_allocated(msp->ms_sm) == msp->ms_size)
1847 ASSERT0(space_map_allocated(msp->ms_sm));
1867 (msp->ms_sm == NULL || msp->ms_sm->sm_dbuf->db_size ==
2036 space_map_t *sm = msp->ms_sm;
2066 object_size = space_map_length(msp->ms_sm);
2087 space_map_t *sm = msp->ms_sm;
2098 space_map_length(msp->ms_sm), avl_numnodes(&msp->ms_tree->rt_root),
2178 uint64_t object = space_map_object(msp->ms_sm);
2216 if (msp->ms_sm == NULL) {
2222 VERIFY0(space_map_open(&msp->ms_sm, mos, new_object,
2225 ASSERT(msp->ms_sm != NULL);
2243 space_map_write(msp->ms_sm, alloctree, SM_ALLOC, tx);
2244 space_map_write(msp->ms_sm, *freetree, SM_FREE, tx);
2254 space_map_histogram_clear(msp->ms_sm);
2255 space_map_histogram_add(msp->ms_sm, msp->ms_tree, tx);
2264 space_map_histogram_add(msp->ms_sm, *freed_tree, tx);
2274 space_map_histogram_add(msp->ms_sm,
2286 space_map_histogram_add(msp->ms_sm, *freetree, tx);
2311 if (object != space_map_object(msp->ms_sm)) {
2312 object = space_map_object(msp->ms_sm);
2374 alloc_delta = space_map_alloc_delta(msp->ms_sm);
2408 space_map_update(msp->ms_sm);
2731 (space_map_allocated(msp->ms_sm) != 0 ? 0 :